1 /* Copyright (c) 2000-2003, jMock.org. See bundled LICENSE.txt */
2 package org.jmock.stub;
3
4 import org.jmock.dynamic.Invocation;
5
6 public class ThrowStub
7 extends CallStub {
8 private Throwable throwable;
9
10 public ThrowStub(Throwable throwable) {
11 this.throwable = throwable;
12 }
13
14 public Object invoke(Invocation invocation) throws Throwable {
15 throw throwable;
16 }
17
18 public String getDescription() {
19 return "throws <" + throwable + ">";
20 }
21 }
This page was automatically generated by Maven