1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36 package org.jomc.ri.model;
37
38 import org.jomc.model.Module;
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62 @javax.annotation.Generated( value = "org.jomc.tools.SourceFileProcessor 1.7", comments = "See http://www.jomc.org/jomc/1.7/jomc-tools-1.7" )
63
64
65 public class RuntimeModule extends Module implements RuntimeModelObject
66 {
67
68
69
70
71
72
73
74
75
76 public RuntimeModule( final Module module )
77 {
78 super( module );
79
80 if ( this.getAuthors() != null )
81 {
82 this.setAuthors( RuntimeModelObjects.getInstance().copyOf( this.getAuthors() ) );
83 }
84 if ( this.getDocumentation() != null )
85 {
86 this.setDocumentation( RuntimeModelObjects.getInstance().copyOf( this.getDocumentation() ) );
87 }
88 if ( this.getImplementations() != null )
89 {
90 this.setImplementations( RuntimeModelObjects.getInstance().copyOf( this.getImplementations() ) );
91 }
92 if ( this.getMessages() != null )
93 {
94 this.setMessages( RuntimeModelObjects.getInstance().copyOf( this.getMessages() ) );
95 }
96 if ( this.getProperties() != null )
97 {
98 this.setProperties( RuntimeModelObjects.getInstance().copyOf( this.getProperties() ) );
99 }
100 if ( this.getSpecifications() != null )
101 {
102 this.setSpecifications( RuntimeModelObjects.getInstance().copyOf( this.getSpecifications() ) );
103 }
104 }
105
106
107
108 public void gc()
109 {
110 this.gcOrClear( true, false );
111 }
112
113 public void clear()
114 {
115 this.gcOrClear( false, true );
116 }
117
118 private void gcOrClear( final boolean gc, final boolean clear )
119 {
120 if ( this.getAuthors() instanceof RuntimeModelObject )
121 {
122 if ( gc )
123 {
124 ( (RuntimeModelObject) this.getAuthors() ).gc();
125 }
126 if ( clear )
127 {
128 ( (RuntimeModelObject) this.getAuthors() ).clear();
129 }
130 }
131 if ( this.getDocumentation() instanceof RuntimeModelObject )
132 {
133 if ( gc )
134 {
135 ( (RuntimeModelObject) this.getDocumentation() ).gc();
136 }
137 if ( clear )
138 {
139 ( (RuntimeModelObject) this.getDocumentation() ).clear();
140 }
141 }
142 if ( this.getImplementations() instanceof RuntimeModelObject )
143 {
144 if ( gc )
145 {
146 ( (RuntimeModelObject) this.getImplementations() ).gc();
147 }
148 if ( clear )
149 {
150 ( (RuntimeModelObject) this.getImplementations() ).clear();
151 }
152 }
153 if ( this.getMessages() instanceof RuntimeModelObject )
154 {
155 if ( gc )
156 {
157 ( (RuntimeModelObject) this.getMessages() ).gc();
158 }
159 if ( clear )
160 {
161 ( (RuntimeModelObject) this.getMessages() ).clear();
162 }
163 }
164 if ( this.getProperties() instanceof RuntimeModelObject )
165 {
166 if ( gc )
167 {
168 ( (RuntimeModelObject) this.getProperties() ).gc();
169 }
170 if ( clear )
171 {
172 ( (RuntimeModelObject) this.getProperties() ).clear();
173 }
174 }
175 if ( this.getSpecifications() instanceof RuntimeModelObject )
176 {
177 if ( gc )
178 {
179 ( (RuntimeModelObject) this.getSpecifications() ).gc();
180 }
181 if ( clear )
182 {
183 ( (RuntimeModelObject) this.getSpecifications() ).clear();
184 }
185 }
186 }
187
188
189
190
191
192 @javax.annotation.Generated( value = "org.jomc.tools.SourceFileProcessor 1.7", comments = "See http://www.jomc.org/jomc/1.7/jomc-tools-1.7" )
193 public RuntimeModule()
194 {
195
196 super();
197
198 }
199
200
201
202
203
204
205
206
207 }