KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tc > aspectwerkz > transform > inlining > deployer > ChangeSet


1 /*
2  * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
3  */

4 package com.tc.aspectwerkz.transform.inlining.deployer;
5
6 import java.util.Set JavaDoc;
7 import java.util.HashSet JavaDoc;
8
9 import com.tc.aspectwerkz.transform.inlining.compiler.CompilationInfo;
10 import com.tc.aspectwerkz.transform.inlining.compiler.MatchingJoinPointInfo;
11
12 /**
13  * Represents a change set of changes to be made to the class graph.
14  *
15  * @author <a HREF="mailto:jboner@codehaus.org">Jonas BonŽr </a>
16  */

17 public final class ChangeSet {
18   private final Set JavaDoc m_set = new HashSet JavaDoc();
19
20   /**
21    * Adds a change set element.
22    *
23    * @param element
24    */

25   public void addElement(final Element element) {
26     m_set.add(element);
27   }
28
29   /**
30    * Returns all elements in the change set.
31    *
32    * @return all elements in the change set
33    */

34   public Set JavaDoc getElements() {
35     return m_set;
36   }
37
38   /**
39    * Represents a change to be made to the class graph.
40    *
41    * @author <a HREF="mailto:jboner@codehaus.org">Jonas BonŽr </a>
42    */

43   public static class Element {
44     private final CompilationInfo m_compilationInfo;
45     private final MatchingJoinPointInfo m_joinPointInfo;
46
47     public Element(final CompilationInfo compilationInfo, final MatchingJoinPointInfo joinPointInfo) {
48       m_compilationInfo = compilationInfo;
49       m_joinPointInfo = joinPointInfo;
50     }
51
52     public CompilationInfo getCompilationInfo() {
53       return m_compilationInfo;
54     }
55
56     public MatchingJoinPointInfo getJoinPointInfo() {
57       return m_joinPointInfo;
58     }
59   }
60 }
Popular Tags