1 package org.sourceforge.jemm.weaver.analysis;
2
3 import javassist.CtClass;
4
5 import org.sourceforge.jemm.weaver.transformation.Transformation;
6 import org.sourceforge.jemm.weaver.transformation.TransformationException;
7
8
9
10
11
12
13
14
15
16 public class TransformationChain implements Transformation {
17 Transformation[] transforms;
18
19
20
21
22
23
24
25 public TransformationChain(Transformation[] transforms) {
26 this.transforms = transforms;
27 }
28
29
30
31
32
33
34 public Transformation[] getTransforms() {
35 return transforms.clone();
36 }
37
38
39
40
41 @Override
42 public String[] dependentTransforms() {
43 return new String[0];
44 }
45
46
47
48
49 @Override
50 public String getTransformationName() {
51 return "chain";
52 }
53
54
55
56
57 @Override
58 public void transform(CtClass clazz) throws TransformationException {
59 for(Transformation t : transforms) {
60 t.transform(clazz);
61 }
62 }
63
64 }