KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > spoon > support > reflect > code > CtTryImpl


1 package spoon.support.reflect.code;
2
3
4
5 import java.util.ArrayList JavaDoc;
6 import java.util.List JavaDoc;
7
8 import spoon.reflect.code.CtBlock;
9 import spoon.reflect.code.CtCatch;
10 import spoon.reflect.code.CtCodeElement;
11 import spoon.reflect.code.CtTry;
12 import spoon.reflect.declaration.CtSimpleType;
13 import spoon.reflect.visitor.CtVisitor;
14
15 public class CtTryImpl extends CtStatementImpl implements CtTry {
16     private static final long serialVersionUID = 1L;
17     List JavaDoc<CtCatch> catchers=new ArrayList JavaDoc<CtCatch>();
18     
19     public List JavaDoc<CtCatch> getCatchers() {
20         return catchers;
21     }
22
23     public void setCatchers(List JavaDoc<CtCatch> catchers) {
24         this.catchers=catchers;
25     }
26
27     public void accept(CtVisitor visitor) {
28         visitor.visitCtTry(this);
29     }
30
31     CtBlock finalizer;
32
33     public CtBlock getFinalizer() {
34         return finalizer;
35     }
36
37     public void setFinalizer(CtBlock finalizer) {
38         this.finalizer = finalizer;
39     }
40     
41     CtBlock body;
42
43     public CtBlock getBody() {
44         return body;
45     }
46
47     public void setBody(CtBlock body) {
48         this.body = body;
49     }
50
51     public Void JavaDoc S() {
52         return null;
53     }
54     
55     public CtCodeElement getSubstitution(CtSimpleType targetType) {
56         return getFactory().Core().clone(this);
57     }
58     
59 }
60
Popular Tags