View Javadoc
1   
2   
3   
4   
5   
6   
7   
8   
9   
10  
11  
12  
13  
14  
15  
16  
17  package ca.uhn.fhir.model.dstu.resource;
18  
19  /*
20   * #%L
21   * HAPI FHIR - Core Library
22   * %%
23   * Copyright (C) 2014 University Health Network
24   * %%
25   * Licensed under the Apache License, Version 2.0 (the "License");
26   * you may not use this file except in compliance with the License.
27   * You may obtain a copy of the License at
28   * 
29   *      http://www.apache.org/licenses/LICENSE-2.0
30   * 
31   * Unless required by applicable law or agreed to in writing, software
32   * distributed under the License is distributed on an "AS IS" BASIS,
33   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
34   * See the License for the specific language governing permissions and
35   * limitations under the License.
36   * #L%
37   */
38  
39  
40  import java.util.Date;
41  import java.util.List;
42  
43  import ca.uhn.fhir.model.api.BaseIdentifiableElement;
44  import ca.uhn.fhir.model.api.BaseResource;
45  import ca.uhn.fhir.model.api.IElement;
46  import ca.uhn.fhir.model.api.IResource;
47  import ca.uhn.fhir.model.api.IResourceBlock;
48  import ca.uhn.fhir.model.api.Include;
49  import ca.uhn.fhir.model.api.TemporalPrecisionEnum;
50  import ca.uhn.fhir.model.api.annotation.Block;
51  import ca.uhn.fhir.model.api.annotation.Child;
52  import ca.uhn.fhir.model.api.annotation.Description;
53  import ca.uhn.fhir.model.api.annotation.ResourceDef;
54  import ca.uhn.fhir.model.api.annotation.SearchParamDefinition;
55  import ca.uhn.fhir.model.dstu.composite.CodeableConceptDt;
56  import ca.uhn.fhir.model.dstu.composite.CodingDt;
57  import ca.uhn.fhir.model.dstu.composite.ContactDt;
58  import ca.uhn.fhir.model.dstu.composite.ResourceReferenceDt;
59  import ca.uhn.fhir.model.dstu.valueset.ConformanceEventModeEnum;
60  import ca.uhn.fhir.model.dstu.valueset.ConformanceStatementStatusEnum;
61  import ca.uhn.fhir.model.dstu.valueset.ContactUseEnum;
62  import ca.uhn.fhir.model.dstu.valueset.DocumentModeEnum;
63  import ca.uhn.fhir.model.dstu.valueset.MessageSignificanceCategoryEnum;
64  import ca.uhn.fhir.model.dstu.valueset.ResourceTypeEnum;
65  import ca.uhn.fhir.model.dstu.valueset.RestfulConformanceModeEnum;
66  import ca.uhn.fhir.model.dstu.valueset.RestfulOperationSystemEnum;
67  import ca.uhn.fhir.model.dstu.valueset.RestfulOperationTypeEnum;
68  import ca.uhn.fhir.model.dstu.valueset.RestfulSecurityServiceEnum;
69  import ca.uhn.fhir.model.dstu.valueset.SearchParamTypeEnum;
70  import ca.uhn.fhir.model.primitive.Base64BinaryDt;
71  import ca.uhn.fhir.model.primitive.BooleanDt;
72  import ca.uhn.fhir.model.primitive.BoundCodeDt;
73  import ca.uhn.fhir.model.primitive.BoundCodeableConceptDt;
74  import ca.uhn.fhir.model.primitive.CodeDt;
75  import ca.uhn.fhir.model.primitive.DateTimeDt;
76  import ca.uhn.fhir.model.primitive.IdDt;
77  import ca.uhn.fhir.model.primitive.IntegerDt;
78  import ca.uhn.fhir.model.primitive.StringDt;
79  import ca.uhn.fhir.model.primitive.UriDt;
80  import ca.uhn.fhir.rest.gclient.DateClientParam;
81  import ca.uhn.fhir.rest.gclient.ReferenceClientParam;
82  import ca.uhn.fhir.rest.gclient.StringClientParam;
83  import ca.uhn.fhir.rest.gclient.TokenClientParam;
84  
85  
86  /**
87   * HAPI/FHIR <b>Conformance</b> Resource
88   * (A conformance statement)
89   *
90   * <p>
91   * <b>Definition:</b>
92   * A conformance statement is a set of requirements for a desired implementation or a description of how a target application fulfills those requirements in a particular implementation
93   * </p> 
94   *
95   * <p>
96   * <b>Requirements:</b>
97   * 
98   * </p> 
99   *
100  * <p>
101  * <b>Profile Definition:</b>
102  * <a href="http://hl7.org/fhir/profiles/Conformance">http://hl7.org/fhir/profiles/Conformance</a> 
103  * </p>
104  *
105  */
106 @ResourceDef(name="Conformance", profile="http://hl7.org/fhir/profiles/Conformance", id="conformance")
107 public class Conformance extends BaseResource implements IResource {
108 
109 	/**
110 	 * Search parameter constant for <b>identifier</b>
111 	 * <p>
112 	 * Description: <b>The identifier of the conformance statement</b><br/>
113 	 * Type: <b>token</b><br/>
114 	 * Path: <b>Conformance.identifier</b><br/>
115 	 * </p>
116 	 */
117 	@SearchParamDefinition(name="identifier", path="Conformance.identifier", description="The identifier of the conformance statement", type="token"  )
118 	public static final String SP_IDENTIFIER = "identifier";
119 
120 	/**
121 	 * <b>Fluent Client</b> search parameter constant for <b>identifier</b>
122 	 * <p>
123 	 * Description: <b>The identifier of the conformance statement</b><br/>
124 	 * Type: <b>token</b><br/>
125 	 * Path: <b>Conformance.identifier</b><br/>
126 	 * </p>
127 	 */
128 	public static final TokenClientParam IDENTIFIER = new TokenClientParam(SP_IDENTIFIER);
129 
130 	/**
131 	 * Search parameter constant for <b>version</b>
132 	 * <p>
133 	 * Description: <b>The version identifier of the conformance statement</b><br/>
134 	 * Type: <b>token</b><br/>
135 	 * Path: <b>Conformance.version</b><br/>
136 	 * </p>
137 	 */
138 	@SearchParamDefinition(name="version", path="Conformance.version", description="The version identifier of the conformance statement", type="token"  )
139 	public static final String SP_VERSION = "version";
140 
141 	/**
142 	 * <b>Fluent Client</b> search parameter constant for <b>version</b>
143 	 * <p>
144 	 * Description: <b>The version identifier of the conformance statement</b><br/>
145 	 * Type: <b>token</b><br/>
146 	 * Path: <b>Conformance.version</b><br/>
147 	 * </p>
148 	 */
149 	public static final TokenClientParam VERSION = new TokenClientParam(SP_VERSION);
150 
151 	/**
152 	 * Search parameter constant for <b>name</b>
153 	 * <p>
154 	 * Description: <b>Name of the conformance statement</b><br/>
155 	 * Type: <b>string</b><br/>
156 	 * Path: <b>Conformance.name</b><br/>
157 	 * </p>
158 	 */
159 	@SearchParamDefinition(name="name", path="Conformance.name", description="Name of the conformance statement", type="string"  )
160 	public static final String SP_NAME = "name";
161 
162 	/**
163 	 * <b>Fluent Client</b> search parameter constant for <b>name</b>
164 	 * <p>
165 	 * Description: <b>Name of the conformance statement</b><br/>
166 	 * Type: <b>string</b><br/>
167 	 * Path: <b>Conformance.name</b><br/>
168 	 * </p>
169 	 */
170 	public static final StringClientParam NAME = new StringClientParam(SP_NAME);
171 
172 	/**
173 	 * Search parameter constant for <b>publisher</b>
174 	 * <p>
175 	 * Description: <b>Name of the publisher of the conformance statement</b><br/>
176 	 * Type: <b>string</b><br/>
177 	 * Path: <b>Conformance.publisher</b><br/>
178 	 * </p>
179 	 */
180 	@SearchParamDefinition(name="publisher", path="Conformance.publisher", description="Name of the publisher of the conformance statement", type="string"  )
181 	public static final String SP_PUBLISHER = "publisher";
182 
183 	/**
184 	 * <b>Fluent Client</b> search parameter constant for <b>publisher</b>
185 	 * <p>
186 	 * Description: <b>Name of the publisher of the conformance statement</b><br/>
187 	 * Type: <b>string</b><br/>
188 	 * Path: <b>Conformance.publisher</b><br/>
189 	 * </p>
190 	 */
191 	public static final StringClientParam PUBLISHER = new StringClientParam(SP_PUBLISHER);
192 
193 	/**
194 	 * Search parameter constant for <b>description</b>
195 	 * <p>
196 	 * Description: <b>Text search in the description of the conformance statement</b><br/>
197 	 * Type: <b>string</b><br/>
198 	 * Path: <b>Conformance.description</b><br/>
199 	 * </p>
200 	 */
201 	@SearchParamDefinition(name="description", path="Conformance.description", description="Text search in the description of the conformance statement", type="string"  )
202 	public static final String SP_DESCRIPTION = "description";
203 
204 	/**
205 	 * <b>Fluent Client</b> search parameter constant for <b>description</b>
206 	 * <p>
207 	 * Description: <b>Text search in the description of the conformance statement</b><br/>
208 	 * Type: <b>string</b><br/>
209 	 * Path: <b>Conformance.description</b><br/>
210 	 * </p>
211 	 */
212 	public static final StringClientParam DESCRIPTION = new StringClientParam(SP_DESCRIPTION);
213 
214 	/**
215 	 * Search parameter constant for <b>status</b>
216 	 * <p>
217 	 * Description: <b>The current status of the conformance statement</b><br/>
218 	 * Type: <b>token</b><br/>
219 	 * Path: <b>Conformance.status</b><br/>
220 	 * </p>
221 	 */
222 	@SearchParamDefinition(name="status", path="Conformance.status", description="The current status of the conformance statement", type="token"  )
223 	public static final String SP_STATUS = "status";
224 
225 	/**
226 	 * <b>Fluent Client</b> search parameter constant for <b>status</b>
227 	 * <p>
228 	 * Description: <b>The current status of the conformance statement</b><br/>
229 	 * Type: <b>token</b><br/>
230 	 * Path: <b>Conformance.status</b><br/>
231 	 * </p>
232 	 */
233 	public static final TokenClientParam STATUS = new TokenClientParam(SP_STATUS);
234 
235 	/**
236 	 * Search parameter constant for <b>date</b>
237 	 * <p>
238 	 * Description: <b>The conformance statement publication date</b><br/>
239 	 * Type: <b>date</b><br/>
240 	 * Path: <b>Conformance.date</b><br/>
241 	 * </p>
242 	 */
243 	@SearchParamDefinition(name="date", path="Conformance.date", description="The conformance statement publication date", type="date"  )
244 	public static final String SP_DATE = "date";
245 
246 	/**
247 	 * <b>Fluent Client</b> search parameter constant for <b>date</b>
248 	 * <p>
249 	 * Description: <b>The conformance statement publication date</b><br/>
250 	 * Type: <b>date</b><br/>
251 	 * Path: <b>Conformance.date</b><br/>
252 	 * </p>
253 	 */
254 	public static final DateClientParam DATE = new DateClientParam(SP_DATE);
255 
256 	/**
257 	 * Search parameter constant for <b>software</b>
258 	 * <p>
259 	 * Description: <b>Part of a the name of a software application</b><br/>
260 	 * Type: <b>string</b><br/>
261 	 * Path: <b>Conformance.software.name</b><br/>
262 	 * </p>
263 	 */
264 	@SearchParamDefinition(name="software", path="Conformance.software.name", description="Part of a the name of a software application", type="string"  )
265 	public static final String SP_SOFTWARE = "software";
266 
267 	/**
268 	 * <b>Fluent Client</b> search parameter constant for <b>software</b>
269 	 * <p>
270 	 * Description: <b>Part of a the name of a software application</b><br/>
271 	 * Type: <b>string</b><br/>
272 	 * Path: <b>Conformance.software.name</b><br/>
273 	 * </p>
274 	 */
275 	public static final StringClientParam SOFTWARE = new StringClientParam(SP_SOFTWARE);
276 
277 	/**
278 	 * Search parameter constant for <b>fhirversion</b>
279 	 * <p>
280 	 * Description: <b>The version of FHIR</b><br/>
281 	 * Type: <b>token</b><br/>
282 	 * Path: <b>Conformance.version</b><br/>
283 	 * </p>
284 	 */
285 	@SearchParamDefinition(name="fhirversion", path="Conformance.version", description="The version of FHIR", type="token"  )
286 	public static final String SP_FHIRVERSION = "fhirversion";
287 
288 	/**
289 	 * <b>Fluent Client</b> search parameter constant for <b>fhirversion</b>
290 	 * <p>
291 	 * Description: <b>The version of FHIR</b><br/>
292 	 * Type: <b>token</b><br/>
293 	 * Path: <b>Conformance.version</b><br/>
294 	 * </p>
295 	 */
296 	public static final TokenClientParam FHIRVERSION = new TokenClientParam(SP_FHIRVERSION);
297 
298 	/**
299 	 * Search parameter constant for <b>resource</b>
300 	 * <p>
301 	 * Description: <b>Name of a resource mentioned in a conformance statement</b><br/>
302 	 * Type: <b>token</b><br/>
303 	 * Path: <b>Conformance.rest.resource.type</b><br/>
304 	 * </p>
305 	 */
306 	@SearchParamDefinition(name="resource", path="Conformance.rest.resource.type", description="Name of a resource mentioned in a conformance statement", type="token"  )
307 	public static final String SP_RESOURCE = "resource";
308 
309 	/**
310 	 * <b>Fluent Client</b> search parameter constant for <b>resource</b>
311 	 * <p>
312 	 * Description: <b>Name of a resource mentioned in a conformance statement</b><br/>
313 	 * Type: <b>token</b><br/>
314 	 * Path: <b>Conformance.rest.resource.type</b><br/>
315 	 * </p>
316 	 */
317 	public static final TokenClientParam RESOURCE = new TokenClientParam(SP_RESOURCE);
318 
319 	/**
320 	 * Search parameter constant for <b>event</b>
321 	 * <p>
322 	 * Description: <b>Event code in a conformance statement</b><br/>
323 	 * Type: <b>token</b><br/>
324 	 * Path: <b>Conformance.messaging.event.code</b><br/>
325 	 * </p>
326 	 */
327 	@SearchParamDefinition(name="event", path="Conformance.messaging.event.code", description="Event code in a conformance statement", type="token"  )
328 	public static final String SP_EVENT = "event";
329 
330 	/**
331 	 * <b>Fluent Client</b> search parameter constant for <b>event</b>
332 	 * <p>
333 	 * Description: <b>Event code in a conformance statement</b><br/>
334 	 * Type: <b>token</b><br/>
335 	 * Path: <b>Conformance.messaging.event.code</b><br/>
336 	 * </p>
337 	 */
338 	public static final TokenClientParam EVENT = new TokenClientParam(SP_EVENT);
339 
340 	/**
341 	 * Search parameter constant for <b>mode</b>
342 	 * <p>
343 	 * Description: <b>Mode - restful (server/client) or messaging (sender/receiver)</b><br/>
344 	 * Type: <b>token</b><br/>
345 	 * Path: <b>Conformance.rest.mode</b><br/>
346 	 * </p>
347 	 */
348 	@SearchParamDefinition(name="mode", path="Conformance.rest.mode", description="Mode - restful (server/client) or messaging (sender/receiver)", type="token"  )
349 	public static final String SP_MODE = "mode";
350 
351 	/**
352 	 * <b>Fluent Client</b> search parameter constant for <b>mode</b>
353 	 * <p>
354 	 * Description: <b>Mode - restful (server/client) or messaging (sender/receiver)</b><br/>
355 	 * Type: <b>token</b><br/>
356 	 * Path: <b>Conformance.rest.mode</b><br/>
357 	 * </p>
358 	 */
359 	public static final TokenClientParam MODE = new TokenClientParam(SP_MODE);
360 
361 	/**
362 	 * Search parameter constant for <b>profile</b>
363 	 * <p>
364 	 * Description: <b>A profile id invoked in a conformance statement</b><br/>
365 	 * Type: <b>reference</b><br/>
366 	 * Path: <b>Conformance.rest.resource.profile</b><br/>
367 	 * </p>
368 	 */
369 	@SearchParamDefinition(name="profile", path="Conformance.rest.resource.profile", description="A profile id invoked in a conformance statement", type="reference"  )
370 	public static final String SP_PROFILE = "profile";
371 
372 	/**
373 	 * <b>Fluent Client</b> search parameter constant for <b>profile</b>
374 	 * <p>
375 	 * Description: <b>A profile id invoked in a conformance statement</b><br/>
376 	 * Type: <b>reference</b><br/>
377 	 * Path: <b>Conformance.rest.resource.profile</b><br/>
378 	 * </p>
379 	 */
380 	public static final ReferenceClientParam PROFILE = new ReferenceClientParam(SP_PROFILE);
381 
382 	/**
383 	 * Constant for fluent queries to be used to add include statements. Specifies
384 	 * the path value of "<b>Conformance.rest.resource.profile</b>".
385 	 */
386 	public static final Include INCLUDE_REST_RESOURCE_PROFILE = new Include("Conformance.rest.resource.profile");
387 
388 	/**
389 	 * Search parameter constant for <b>format</b>
390 	 * <p>
391 	 * Description: <b></b><br/>
392 	 * Type: <b>token</b><br/>
393 	 * Path: <b>Conformance.format</b><br/>
394 	 * </p>
395 	 */
396 	@SearchParamDefinition(name="format", path="Conformance.format", description="", type="token"  )
397 	public static final String SP_FORMAT = "format";
398 
399 	/**
400 	 * <b>Fluent Client</b> search parameter constant for <b>format</b>
401 	 * <p>
402 	 * Description: <b></b><br/>
403 	 * Type: <b>token</b><br/>
404 	 * Path: <b>Conformance.format</b><br/>
405 	 * </p>
406 	 */
407 	public static final TokenClientParam FORMAT = new TokenClientParam(SP_FORMAT);
408 
409 	/**
410 	 * Search parameter constant for <b>security</b>
411 	 * <p>
412 	 * Description: <b></b><br/>
413 	 * Type: <b>token</b><br/>
414 	 * Path: <b>Conformance.rest.security</b><br/>
415 	 * </p>
416 	 */
417 	@SearchParamDefinition(name="security", path="Conformance.rest.security", description="", type="token"  )
418 	public static final String SP_SECURITY = "security";
419 
420 	/**
421 	 * <b>Fluent Client</b> search parameter constant for <b>security</b>
422 	 * <p>
423 	 * Description: <b></b><br/>
424 	 * Type: <b>token</b><br/>
425 	 * Path: <b>Conformance.rest.security</b><br/>
426 	 * </p>
427 	 */
428 	public static final TokenClientParam SECURITY = new TokenClientParam(SP_SECURITY);
429 
430 	/**
431 	 * Search parameter constant for <b>supported-profile</b>
432 	 * <p>
433 	 * Description: <b></b><br/>
434 	 * Type: <b>reference</b><br/>
435 	 * Path: <b>Conformance.profile</b><br/>
436 	 * </p>
437 	 */
438 	@SearchParamDefinition(name="supported-profile", path="Conformance.profile", description="", type="reference"  )
439 	public static final String SP_SUPPORTED_PROFILE = "supported-profile";
440 
441 	/**
442 	 * <b>Fluent Client</b> search parameter constant for <b>supported-profile</b>
443 	 * <p>
444 	 * Description: <b></b><br/>
445 	 * Type: <b>reference</b><br/>
446 	 * Path: <b>Conformance.profile</b><br/>
447 	 * </p>
448 	 */
449 	public static final ReferenceClientParam SUPPORTED_PROFILE = new ReferenceClientParam(SP_SUPPORTED_PROFILE);
450 
451 	/**
452 	 * Constant for fluent queries to be used to add include statements. Specifies
453 	 * the path value of "<b>Conformance.profile</b>".
454 	 */
455 	public static final Include INCLUDE_PROFILE = new Include("Conformance.profile");
456 
457 
458 	@Child(name="identifier", type=StringDt.class, order=0, min=0, max=1)	
459 	@Description(
460 		shortDefinition="Logical id to reference this statement",
461 		formalDefinition="The identifier that is used to identify this conformance statement when it is referenced in a specification, model, design or an instance (should be globally unique OID, UUID, or URI)"
462 	)
463 	private StringDt myIdentifier;
464 	
465 	@Child(name="version", type=StringDt.class, order=1, min=0, max=1)	
466 	@Description(
467 		shortDefinition="Logical id for this version of the statement",
468 		formalDefinition="The identifier that is used to identify this version of the conformance statement when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the profile author manually and the value should be a timestamp"
469 	)
470 	private StringDt myVersion;
471 	
472 	@Child(name="name", type=StringDt.class, order=2, min=0, max=1)	
473 	@Description(
474 		shortDefinition="Informal name for this conformance statement",
475 		formalDefinition="A free text natural language name identifying the conformance statement"
476 	)
477 	private StringDt myName;
478 	
479 	@Child(name="publisher", type=StringDt.class, order=3, min=1, max=1)	
480 	@Description(
481 		shortDefinition="Publishing Organization",
482 		formalDefinition="Name of Organization publishing this conformance statement"
483 	)
484 	private StringDt myPublisher;
485 	
486 	@Child(name="telecom", type=ContactDt.class, order=4, min=0, max=Child.MAX_UNLIMITED)	
487 	@Description(
488 		shortDefinition="Contacts for Organization",
489 		formalDefinition="Contacts for Organization relevant to this conformance statement.  The contacts may be a website, email, phone numbers, etc."
490 	)
491 	private java.util.List<ContactDt> myTelecom;
492 	
493 	@Child(name="description", type=StringDt.class, order=5, min=0, max=1)	
494 	@Description(
495 		shortDefinition="Human description of the conformance statement",
496 		formalDefinition="A free text natural language description of the conformance statement and its use. Typically, this is used when the profile describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP"
497 	)
498 	private StringDt myDescription;
499 	
500 	@Child(name="status", type=CodeDt.class, order=6, min=0, max=1)	
501 	@Description(
502 		shortDefinition="draft | active | retired",
503 		formalDefinition="The status of this conformance statement"
504 	)
505 	private BoundCodeDt<ConformanceStatementStatusEnum> myStatus;
506 	
507 	@Child(name="experimental", type=BooleanDt.class, order=7, min=0, max=1)	
508 	@Description(
509 		shortDefinition="If for testing purposes, not real usage",
510 		formalDefinition="A flag to indicate that this conformance statement is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage"
511 	)
512 	private BooleanDt myExperimental;
513 	
514 	@Child(name="date", type=DateTimeDt.class, order=8, min=1, max=1)	
515 	@Description(
516 		shortDefinition="Publication Date",
517 		formalDefinition="The date when the conformance statement was published"
518 	)
519 	private DateTimeDt myDate;
520 	
521 	@Child(name="software", order=9, min=0, max=1)	
522 	@Description(
523 		shortDefinition="Software that is covered by this conformance statement",
524 		formalDefinition="Software that is covered by this conformance statement.  It is used when the profile describes the capabilities of a particular software version, independent of an installation."
525 	)
526 	private Software mySoftware;
527 	
528 	@Child(name="implementation", order=10, min=0, max=1)	
529 	@Description(
530 		shortDefinition="If this describes a specific instance",
531 		formalDefinition="Identifies a specific implementation instance that is described by the conformance statement - i.e. a particular installation, rather than the capabilities of a software program"
532 	)
533 	private Implementation myImplementation;
534 	
535 	@Child(name="fhirVersion", type=IdDt.class, order=11, min=1, max=1)	
536 	@Description(
537 		shortDefinition="FHIR Version",
538 		formalDefinition="The version of the FHIR specification on which this conformance statement is based"
539 	)
540 	private IdDt myFhirVersion;
541 	
542 	@Child(name="acceptUnknown", type=BooleanDt.class, order=12, min=1, max=1)	
543 	@Description(
544 		shortDefinition="True if application accepts unknown elements",
545 		formalDefinition="A flag that indicates whether the application accepts unknown elements as part of a resource."
546 	)
547 	private BooleanDt myAcceptUnknown;
548 	
549 	@Child(name="format", type=CodeDt.class, order=13, min=1, max=Child.MAX_UNLIMITED)	
550 	@Description(
551 		shortDefinition="formats supported (xml | json | mime type)",
552 		formalDefinition="A list of the formats supported by this implementation"
553 	)
554 	private java.util.List<CodeDt> myFormat;
555 	
556 	@Child(name="profile", order=14, min=0, max=Child.MAX_UNLIMITED, type={
557 		ca.uhn.fhir.model.dstu.resource.Profile.class	})
558 	@Description(
559 		shortDefinition="Profiles supported by the system",
560 		formalDefinition="A list of profiles supported by the system. For a server, \"supported by the system\" means the system hosts/produces a set of recourses, conformant to a particular profile, and allows its clients to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile."
561 	)
562 	private java.util.List<ResourceReferenceDt> myProfile;
563 	
564 	@Child(name="rest", order=15, min=0, max=Child.MAX_UNLIMITED)	
565 	@Description(
566 		shortDefinition="If the endpoint is a RESTful one",
567 		formalDefinition="A definition of the restful capabilities of the solution, if any"
568 	)
569 	private java.util.List<Rest> myRest;
570 	
571 	@Child(name="messaging", order=16, min=0, max=Child.MAX_UNLIMITED)	
572 	@Description(
573 		shortDefinition="If messaging is supported",
574 		formalDefinition="A description of the messaging capabilities of the solution"
575 	)
576 	private java.util.List<Messaging> myMessaging;
577 	
578 	@Child(name="document", order=17, min=0, max=Child.MAX_UNLIMITED)	
579 	@Description(
580 		shortDefinition="Document definition",
581 		formalDefinition="A document definition"
582 	)
583 	private java.util.List<Document> myDocument;
584 	
585 
586 	@Override
587 	public boolean isEmpty() {
588 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myIdentifier,  myVersion,  myName,  myPublisher,  myTelecom,  myDescription,  myStatus,  myExperimental,  myDate,  mySoftware,  myImplementation,  myFhirVersion,  myAcceptUnknown,  myFormat,  myProfile,  myRest,  myMessaging,  myDocument);
589 	}
590 	
591 	@Override
592 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
593 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myIdentifier, myVersion, myName, myPublisher, myTelecom, myDescription, myStatus, myExperimental, myDate, mySoftware, myImplementation, myFhirVersion, myAcceptUnknown, myFormat, myProfile, myRest, myMessaging, myDocument);
594 	}
595 
596 	/**
597 	 * Gets the value(s) for <b>identifier</b> (Logical id to reference this statement).
598 	 * creating it if it does
599 	 * not exist. Will not return <code>null</code>.
600 	 *
601      * <p>
602      * <b>Definition:</b>
603      * The identifier that is used to identify this conformance statement when it is referenced in a specification, model, design or an instance (should be globally unique OID, UUID, or URI)
604      * </p> 
605 	 */
606 	public StringDt getIdentifier() {  
607 		if (myIdentifier == null) {
608 			myIdentifier = new StringDt();
609 		}
610 		return myIdentifier;
611 	}
612 
613 	/**
614 	 * Sets the value(s) for <b>identifier</b> (Logical id to reference this statement)
615 	 *
616      * <p>
617      * <b>Definition:</b>
618      * The identifier that is used to identify this conformance statement when it is referenced in a specification, model, design or an instance (should be globally unique OID, UUID, or URI)
619      * </p> 
620 	 */
621 	public Conformance setIdentifier(StringDt theValue) {
622 		myIdentifier = theValue;
623 		return this;
624 	}
625 
626  	/**
627 	 * Sets the value for <b>identifier</b> (Logical id to reference this statement)
628 	 *
629      * <p>
630      * <b>Definition:</b>
631      * The identifier that is used to identify this conformance statement when it is referenced in a specification, model, design or an instance (should be globally unique OID, UUID, or URI)
632      * </p> 
633 	 */
634 	public Conformance setIdentifier( String theString) {
635 		myIdentifier = new StringDt(theString); 
636 		return this; 
637 	}
638 
639  
640 	/**
641 	 * Gets the value(s) for <b>version</b> (Logical id for this version of the statement).
642 	 * creating it if it does
643 	 * not exist. Will not return <code>null</code>.
644 	 *
645      * <p>
646      * <b>Definition:</b>
647      * The identifier that is used to identify this version of the conformance statement when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the profile author manually and the value should be a timestamp
648      * </p> 
649 	 */
650 	public StringDt getVersion() {  
651 		if (myVersion == null) {
652 			myVersion = new StringDt();
653 		}
654 		return myVersion;
655 	}
656 
657 	/**
658 	 * Sets the value(s) for <b>version</b> (Logical id for this version of the statement)
659 	 *
660      * <p>
661      * <b>Definition:</b>
662      * The identifier that is used to identify this version of the conformance statement when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the profile author manually and the value should be a timestamp
663      * </p> 
664 	 */
665 	public Conformance setVersion(StringDt theValue) {
666 		myVersion = theValue;
667 		return this;
668 	}
669 
670  	/**
671 	 * Sets the value for <b>version</b> (Logical id for this version of the statement)
672 	 *
673      * <p>
674      * <b>Definition:</b>
675      * The identifier that is used to identify this version of the conformance statement when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the profile author manually and the value should be a timestamp
676      * </p> 
677 	 */
678 	public Conformance setVersion( String theString) {
679 		myVersion = new StringDt(theString); 
680 		return this; 
681 	}
682 
683  
684 	/**
685 	 * Gets the value(s) for <b>name</b> (Informal name for this conformance statement).
686 	 * creating it if it does
687 	 * not exist. Will not return <code>null</code>.
688 	 *
689      * <p>
690      * <b>Definition:</b>
691      * A free text natural language name identifying the conformance statement
692      * </p> 
693 	 */
694 	public StringDt getName() {  
695 		if (myName == null) {
696 			myName = new StringDt();
697 		}
698 		return myName;
699 	}
700 
701 	/**
702 	 * Sets the value(s) for <b>name</b> (Informal name for this conformance statement)
703 	 *
704      * <p>
705      * <b>Definition:</b>
706      * A free text natural language name identifying the conformance statement
707      * </p> 
708 	 */
709 	public Conformance setName(StringDt theValue) {
710 		myName = theValue;
711 		return this;
712 	}
713 
714  	/**
715 	 * Sets the value for <b>name</b> (Informal name for this conformance statement)
716 	 *
717      * <p>
718      * <b>Definition:</b>
719      * A free text natural language name identifying the conformance statement
720      * </p> 
721 	 */
722 	public Conformance setName( String theString) {
723 		myName = new StringDt(theString); 
724 		return this; 
725 	}
726 
727  
728 	/**
729 	 * Gets the value(s) for <b>publisher</b> (Publishing Organization).
730 	 * creating it if it does
731 	 * not exist. Will not return <code>null</code>.
732 	 *
733      * <p>
734      * <b>Definition:</b>
735      * Name of Organization publishing this conformance statement
736      * </p> 
737 	 */
738 	public StringDt getPublisher() {  
739 		if (myPublisher == null) {
740 			myPublisher = new StringDt();
741 		}
742 		return myPublisher;
743 	}
744 
745 	/**
746 	 * Sets the value(s) for <b>publisher</b> (Publishing Organization)
747 	 *
748      * <p>
749      * <b>Definition:</b>
750      * Name of Organization publishing this conformance statement
751      * </p> 
752 	 */
753 	public Conformance setPublisher(StringDt theValue) {
754 		myPublisher = theValue;
755 		return this;
756 	}
757 
758  	/**
759 	 * Sets the value for <b>publisher</b> (Publishing Organization)
760 	 *
761      * <p>
762      * <b>Definition:</b>
763      * Name of Organization publishing this conformance statement
764      * </p> 
765 	 */
766 	public Conformance setPublisher( String theString) {
767 		myPublisher = new StringDt(theString); 
768 		return this; 
769 	}
770 
771  
772 	/**
773 	 * Gets the value(s) for <b>telecom</b> (Contacts for Organization).
774 	 * creating it if it does
775 	 * not exist. Will not return <code>null</code>.
776 	 *
777      * <p>
778      * <b>Definition:</b>
779      * Contacts for Organization relevant to this conformance statement.  The contacts may be a website, email, phone numbers, etc.
780      * </p> 
781 	 */
782 	public java.util.List<ContactDt> getTelecom() {  
783 		if (myTelecom == null) {
784 			myTelecom = new java.util.ArrayList<ContactDt>();
785 		}
786 		return myTelecom;
787 	}
788 
789 	/**
790 	 * Sets the value(s) for <b>telecom</b> (Contacts for Organization)
791 	 *
792      * <p>
793      * <b>Definition:</b>
794      * Contacts for Organization relevant to this conformance statement.  The contacts may be a website, email, phone numbers, etc.
795      * </p> 
796 	 */
797 	public Conformance setTelecom(java.util.List<ContactDt> theValue) {
798 		myTelecom = theValue;
799 		return this;
800 	}
801 
802 	/**
803 	 * Adds and returns a new value for <b>telecom</b> (Contacts for Organization)
804 	 *
805      * <p>
806      * <b>Definition:</b>
807      * Contacts for Organization relevant to this conformance statement.  The contacts may be a website, email, phone numbers, etc.
808      * </p> 
809 	 */
810 	public ContactDt addTelecom() {
811 		ContactDt newType = new ContactDt();
812 		getTelecom().add(newType);
813 		return newType; 
814 	}
815 
816 	/**
817 	 * Gets the first repetition for <b>telecom</b> (Contacts for Organization),
818 	 * creating it if it does not already exist.
819 	 *
820      * <p>
821      * <b>Definition:</b>
822      * Contacts for Organization relevant to this conformance statement.  The contacts may be a website, email, phone numbers, etc.
823      * </p> 
824 	 */
825 	public ContactDt getTelecomFirstRep() {
826 		if (getTelecom().isEmpty()) {
827 			return addTelecom();
828 		}
829 		return getTelecom().get(0); 
830 	}
831  	/**
832 	 * Adds a new value for <b>telecom</b> (Contacts for Organization)
833 	 *
834      * <p>
835      * <b>Definition:</b>
836      * Contacts for Organization relevant to this conformance statement.  The contacts may be a website, email, phone numbers, etc.
837      * </p> 
838      *
839      * @return Returns a reference to this object, to allow for simple chaining.
840 	 */
841 	public Conformance addTelecom( ContactUseEnum theContactUse,  String theValue) {
842 		if (myTelecom == null) {
843 			myTelecom = new java.util.ArrayList<ContactDt>();
844 		}
845 		myTelecom.add(new ContactDt(theContactUse, theValue));
846 		return this; 
847 	}
848 
849 	/**
850 	 * Adds a new value for <b>telecom</b> (Contacts for Organization)
851 	 *
852      * <p>
853      * <b>Definition:</b>
854      * Contacts for Organization relevant to this conformance statement.  The contacts may be a website, email, phone numbers, etc.
855      * </p> 
856      *
857      * @return Returns a reference to this object, to allow for simple chaining.
858 	 */
859 	public Conformance addTelecom( String theValue) {
860 		if (myTelecom == null) {
861 			myTelecom = new java.util.ArrayList<ContactDt>();
862 		}
863 		myTelecom.add(new ContactDt(theValue));
864 		return this; 
865 	}
866 
867  
868 	/**
869 	 * Gets the value(s) for <b>description</b> (Human description of the conformance statement).
870 	 * creating it if it does
871 	 * not exist. Will not return <code>null</code>.
872 	 *
873      * <p>
874      * <b>Definition:</b>
875      * A free text natural language description of the conformance statement and its use. Typically, this is used when the profile describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP
876      * </p> 
877 	 */
878 	public StringDt getDescription() {  
879 		if (myDescription == null) {
880 			myDescription = new StringDt();
881 		}
882 		return myDescription;
883 	}
884 
885 	/**
886 	 * Sets the value(s) for <b>description</b> (Human description of the conformance statement)
887 	 *
888      * <p>
889      * <b>Definition:</b>
890      * A free text natural language description of the conformance statement and its use. Typically, this is used when the profile describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP
891      * </p> 
892 	 */
893 	public Conformance setDescription(StringDt theValue) {
894 		myDescription = theValue;
895 		return this;
896 	}
897 
898  	/**
899 	 * Sets the value for <b>description</b> (Human description of the conformance statement)
900 	 *
901      * <p>
902      * <b>Definition:</b>
903      * A free text natural language description of the conformance statement and its use. Typically, this is used when the profile describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP
904      * </p> 
905 	 */
906 	public Conformance setDescription( String theString) {
907 		myDescription = new StringDt(theString); 
908 		return this; 
909 	}
910 
911  
912 	/**
913 	 * Gets the value(s) for <b>status</b> (draft | active | retired).
914 	 * creating it if it does
915 	 * not exist. Will not return <code>null</code>.
916 	 *
917      * <p>
918      * <b>Definition:</b>
919      * The status of this conformance statement
920      * </p> 
921 	 */
922 	public BoundCodeDt<ConformanceStatementStatusEnum> getStatus() {  
923 		if (myStatus == null) {
924 			myStatus = new BoundCodeDt<ConformanceStatementStatusEnum>(ConformanceStatementStatusEnum.VALUESET_BINDER);
925 		}
926 		return myStatus;
927 	}
928 
929 	/**
930 	 * Sets the value(s) for <b>status</b> (draft | active | retired)
931 	 *
932      * <p>
933      * <b>Definition:</b>
934      * The status of this conformance statement
935      * </p> 
936 	 */
937 	public Conformance setStatus(BoundCodeDt<ConformanceStatementStatusEnum> theValue) {
938 		myStatus = theValue;
939 		return this;
940 	}
941 
942 	/**
943 	 * Sets the value(s) for <b>status</b> (draft | active | retired)
944 	 *
945      * <p>
946      * <b>Definition:</b>
947      * The status of this conformance statement
948      * </p> 
949 	 */
950 	public Conformance setStatus(ConformanceStatementStatusEnum theValue) {
951 		getStatus().setValueAsEnum(theValue);
952 		return this;
953 	}
954 
955   
956 	/**
957 	 * Gets the value(s) for <b>experimental</b> (If for testing purposes, not real usage).
958 	 * creating it if it does
959 	 * not exist. Will not return <code>null</code>.
960 	 *
961      * <p>
962      * <b>Definition:</b>
963      * A flag to indicate that this conformance statement is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage
964      * </p> 
965 	 */
966 	public BooleanDt getExperimental() {  
967 		if (myExperimental == null) {
968 			myExperimental = new BooleanDt();
969 		}
970 		return myExperimental;
971 	}
972 
973 	/**
974 	 * Sets the value(s) for <b>experimental</b> (If for testing purposes, not real usage)
975 	 *
976      * <p>
977      * <b>Definition:</b>
978      * A flag to indicate that this conformance statement is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage
979      * </p> 
980 	 */
981 	public Conformance setExperimental(BooleanDt theValue) {
982 		myExperimental = theValue;
983 		return this;
984 	}
985 
986  	/**
987 	 * Sets the value for <b>experimental</b> (If for testing purposes, not real usage)
988 	 *
989      * <p>
990      * <b>Definition:</b>
991      * A flag to indicate that this conformance statement is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage
992      * </p> 
993 	 */
994 	public Conformance setExperimental( boolean theBoolean) {
995 		myExperimental = new BooleanDt(theBoolean); 
996 		return this; 
997 	}
998 
999  
1000 	/**
1001 	 * Gets the value(s) for <b>date</b> (Publication Date).
1002 	 * creating it if it does
1003 	 * not exist. Will not return <code>null</code>.
1004 	 *
1005      * <p>
1006      * <b>Definition:</b>
1007      * The date when the conformance statement was published
1008      * </p> 
1009 	 */
1010 	public DateTimeDt getDate() {  
1011 		if (myDate == null) {
1012 			myDate = new DateTimeDt();
1013 		}
1014 		return myDate;
1015 	}
1016 
1017 	/**
1018 	 * Sets the value(s) for <b>date</b> (Publication Date)
1019 	 *
1020      * <p>
1021      * <b>Definition:</b>
1022      * The date when the conformance statement was published
1023      * </p> 
1024 	 */
1025 	public Conformance setDate(DateTimeDt theValue) {
1026 		myDate = theValue;
1027 		return this;
1028 	}
1029 
1030  	/**
1031 	 * Sets the value for <b>date</b> (Publication Date)
1032 	 *
1033      * <p>
1034      * <b>Definition:</b>
1035      * The date when the conformance statement was published
1036      * </p> 
1037 	 */
1038 	public Conformance setDateWithSecondsPrecision( Date theDate) {
1039 		myDate = new DateTimeDt(theDate); 
1040 		return this; 
1041 	}
1042 
1043 	/**
1044 	 * Sets the value for <b>date</b> (Publication Date)
1045 	 *
1046      * <p>
1047      * <b>Definition:</b>
1048      * The date when the conformance statement was published
1049      * </p> 
1050 	 */
1051 	public Conformance setDate( Date theDate,  TemporalPrecisionEnum thePrecision) {
1052 		myDate = new DateTimeDt(theDate, thePrecision); 
1053 		return this; 
1054 	}
1055 
1056  
1057 	/**
1058 	 * Gets the value(s) for <b>software</b> (Software that is covered by this conformance statement).
1059 	 * creating it if it does
1060 	 * not exist. Will not return <code>null</code>.
1061 	 *
1062      * <p>
1063      * <b>Definition:</b>
1064      * Software that is covered by this conformance statement.  It is used when the profile describes the capabilities of a particular software version, independent of an installation.
1065      * </p> 
1066 	 */
1067 	public Software getSoftware() {  
1068 		if (mySoftware == null) {
1069 			mySoftware = new Software();
1070 		}
1071 		return mySoftware;
1072 	}
1073 
1074 	/**
1075 	 * Sets the value(s) for <b>software</b> (Software that is covered by this conformance statement)
1076 	 *
1077      * <p>
1078      * <b>Definition:</b>
1079      * Software that is covered by this conformance statement.  It is used when the profile describes the capabilities of a particular software version, independent of an installation.
1080      * </p> 
1081 	 */
1082 	public Conformance setSoftware(Software theValue) {
1083 		mySoftware = theValue;
1084 		return this;
1085 	}
1086 
1087   
1088 	/**
1089 	 * Gets the value(s) for <b>implementation</b> (If this describes a specific instance).
1090 	 * creating it if it does
1091 	 * not exist. Will not return <code>null</code>.
1092 	 *
1093      * <p>
1094      * <b>Definition:</b>
1095      * Identifies a specific implementation instance that is described by the conformance statement - i.e. a particular installation, rather than the capabilities of a software program
1096      * </p> 
1097 	 */
1098 	public Implementation getImplementation() {  
1099 		if (myImplementation == null) {
1100 			myImplementation = new Implementation();
1101 		}
1102 		return myImplementation;
1103 	}
1104 
1105 	/**
1106 	 * Sets the value(s) for <b>implementation</b> (If this describes a specific instance)
1107 	 *
1108      * <p>
1109      * <b>Definition:</b>
1110      * Identifies a specific implementation instance that is described by the conformance statement - i.e. a particular installation, rather than the capabilities of a software program
1111      * </p> 
1112 	 */
1113 	public Conformance setImplementation(Implementation theValue) {
1114 		myImplementation = theValue;
1115 		return this;
1116 	}
1117 
1118   
1119 	/**
1120 	 * Gets the value(s) for <b>fhirVersion</b> (FHIR Version).
1121 	 * creating it if it does
1122 	 * not exist. Will not return <code>null</code>.
1123 	 *
1124      * <p>
1125      * <b>Definition:</b>
1126      * The version of the FHIR specification on which this conformance statement is based
1127      * </p> 
1128 	 */
1129 	public IdDt getFhirVersion() {  
1130 		if (myFhirVersion == null) {
1131 			myFhirVersion = new IdDt();
1132 		}
1133 		return myFhirVersion;
1134 	}
1135 
1136 	/**
1137 	 * Sets the value(s) for <b>fhirVersion</b> (FHIR Version)
1138 	 *
1139      * <p>
1140      * <b>Definition:</b>
1141      * The version of the FHIR specification on which this conformance statement is based
1142      * </p> 
1143 	 */
1144 	public Conformance setFhirVersion(IdDt theValue) {
1145 		myFhirVersion = theValue;
1146 		return this;
1147 	}
1148 
1149  	/**
1150 	 * Sets the value for <b>fhirVersion</b> (FHIR Version)
1151 	 *
1152      * <p>
1153      * <b>Definition:</b>
1154      * The version of the FHIR specification on which this conformance statement is based
1155      * </p> 
1156 	 */
1157 	public Conformance setFhirVersion( String theId) {
1158 		myFhirVersion = new IdDt(theId); 
1159 		return this; 
1160 	}
1161 
1162  
1163 	/**
1164 	 * Gets the value(s) for <b>acceptUnknown</b> (True if application accepts unknown elements).
1165 	 * creating it if it does
1166 	 * not exist. Will not return <code>null</code>.
1167 	 *
1168      * <p>
1169      * <b>Definition:</b>
1170      * A flag that indicates whether the application accepts unknown elements as part of a resource.
1171      * </p> 
1172 	 */
1173 	public BooleanDt getAcceptUnknown() {  
1174 		if (myAcceptUnknown == null) {
1175 			myAcceptUnknown = new BooleanDt();
1176 		}
1177 		return myAcceptUnknown;
1178 	}
1179 
1180 	/**
1181 	 * Sets the value(s) for <b>acceptUnknown</b> (True if application accepts unknown elements)
1182 	 *
1183      * <p>
1184      * <b>Definition:</b>
1185      * A flag that indicates whether the application accepts unknown elements as part of a resource.
1186      * </p> 
1187 	 */
1188 	public Conformance setAcceptUnknown(BooleanDt theValue) {
1189 		myAcceptUnknown = theValue;
1190 		return this;
1191 	}
1192 
1193  	/**
1194 	 * Sets the value for <b>acceptUnknown</b> (True if application accepts unknown elements)
1195 	 *
1196      * <p>
1197      * <b>Definition:</b>
1198      * A flag that indicates whether the application accepts unknown elements as part of a resource.
1199      * </p> 
1200 	 */
1201 	public Conformance setAcceptUnknown( boolean theBoolean) {
1202 		myAcceptUnknown = new BooleanDt(theBoolean); 
1203 		return this; 
1204 	}
1205 
1206  
1207 	/**
1208 	 * Gets the value(s) for <b>format</b> (formats supported (xml | json | mime type)).
1209 	 * creating it if it does
1210 	 * not exist. Will not return <code>null</code>.
1211 	 *
1212      * <p>
1213      * <b>Definition:</b>
1214      * A list of the formats supported by this implementation
1215      * </p> 
1216 	 */
1217 	public java.util.List<CodeDt> getFormat() {  
1218 		if (myFormat == null) {
1219 			myFormat = new java.util.ArrayList<CodeDt>();
1220 		}
1221 		return myFormat;
1222 	}
1223 
1224 	/**
1225 	 * Sets the value(s) for <b>format</b> (formats supported (xml | json | mime type))
1226 	 *
1227      * <p>
1228      * <b>Definition:</b>
1229      * A list of the formats supported by this implementation
1230      * </p> 
1231 	 */
1232 	public Conformance setFormat(java.util.List<CodeDt> theValue) {
1233 		myFormat = theValue;
1234 		return this;
1235 	}
1236 
1237 	/**
1238 	 * Adds and returns a new value for <b>format</b> (formats supported (xml | json | mime type))
1239 	 *
1240      * <p>
1241      * <b>Definition:</b>
1242      * A list of the formats supported by this implementation
1243      * </p> 
1244 	 */
1245 	public CodeDt addFormat() {
1246 		CodeDt newType = new CodeDt();
1247 		getFormat().add(newType);
1248 		return newType; 
1249 	}
1250 
1251 	/**
1252 	 * Gets the first repetition for <b>format</b> (formats supported (xml | json | mime type)),
1253 	 * creating it if it does not already exist.
1254 	 *
1255      * <p>
1256      * <b>Definition:</b>
1257      * A list of the formats supported by this implementation
1258      * </p> 
1259 	 */
1260 	public CodeDt getFormatFirstRep() {
1261 		if (getFormat().isEmpty()) {
1262 			return addFormat();
1263 		}
1264 		return getFormat().get(0); 
1265 	}
1266  	/**
1267 	 * Adds a new value for <b>format</b> (formats supported (xml | json | mime type))
1268 	 *
1269      * <p>
1270      * <b>Definition:</b>
1271      * A list of the formats supported by this implementation
1272      * </p> 
1273      *
1274      * @return Returns a reference to this object, to allow for simple chaining.
1275 	 */
1276 	public Conformance addFormat( String theCode) {
1277 		if (myFormat == null) {
1278 			myFormat = new java.util.ArrayList<CodeDt>();
1279 		}
1280 		myFormat.add(new CodeDt(theCode));
1281 		return this; 
1282 	}
1283 
1284  
1285 	/**
1286 	 * Gets the value(s) for <b>profile</b> (Profiles supported by the system).
1287 	 * creating it if it does
1288 	 * not exist. Will not return <code>null</code>.
1289 	 *
1290      * <p>
1291      * <b>Definition:</b>
1292      * A list of profiles supported by the system. For a server, \"supported by the system\" means the system hosts/produces a set of recourses, conformant to a particular profile, and allows its clients to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile.
1293      * </p> 
1294 	 */
1295 	public java.util.List<ResourceReferenceDt> getProfile() {  
1296 		if (myProfile == null) {
1297 			myProfile = new java.util.ArrayList<ResourceReferenceDt>();
1298 		}
1299 		return myProfile;
1300 	}
1301 
1302 	/**
1303 	 * Sets the value(s) for <b>profile</b> (Profiles supported by the system)
1304 	 *
1305      * <p>
1306      * <b>Definition:</b>
1307      * A list of profiles supported by the system. For a server, \"supported by the system\" means the system hosts/produces a set of recourses, conformant to a particular profile, and allows its clients to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile.
1308      * </p> 
1309 	 */
1310 	public Conformance setProfile(java.util.List<ResourceReferenceDt> theValue) {
1311 		myProfile = theValue;
1312 		return this;
1313 	}
1314 
1315 	/**
1316 	 * Adds and returns a new value for <b>profile</b> (Profiles supported by the system)
1317 	 *
1318      * <p>
1319      * <b>Definition:</b>
1320      * A list of profiles supported by the system. For a server, \"supported by the system\" means the system hosts/produces a set of recourses, conformant to a particular profile, and allows its clients to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile.
1321      * </p> 
1322 	 */
1323 	public ResourceReferenceDt addProfile() {
1324 		ResourceReferenceDt newType = new ResourceReferenceDt();
1325 		getProfile().add(newType);
1326 		return newType; 
1327 	}
1328   
1329 	/**
1330 	 * Gets the value(s) for <b>rest</b> (If the endpoint is a RESTful one).
1331 	 * creating it if it does
1332 	 * not exist. Will not return <code>null</code>.
1333 	 *
1334      * <p>
1335      * <b>Definition:</b>
1336      * A definition of the restful capabilities of the solution, if any
1337      * </p> 
1338 	 */
1339 	public java.util.List<Rest> getRest() {  
1340 		if (myRest == null) {
1341 			myRest = new java.util.ArrayList<Rest>();
1342 		}
1343 		return myRest;
1344 	}
1345 
1346 	/**
1347 	 * Sets the value(s) for <b>rest</b> (If the endpoint is a RESTful one)
1348 	 *
1349      * <p>
1350      * <b>Definition:</b>
1351      * A definition of the restful capabilities of the solution, if any
1352      * </p> 
1353 	 */
1354 	public Conformance setRest(java.util.List<Rest> theValue) {
1355 		myRest = theValue;
1356 		return this;
1357 	}
1358 
1359 	/**
1360 	 * Adds and returns a new value for <b>rest</b> (If the endpoint is a RESTful one)
1361 	 *
1362      * <p>
1363      * <b>Definition:</b>
1364      * A definition of the restful capabilities of the solution, if any
1365      * </p> 
1366 	 */
1367 	public Rest addRest() {
1368 		Rest newType = new Rest();
1369 		getRest().add(newType);
1370 		return newType; 
1371 	}
1372 
1373 	/**
1374 	 * Gets the first repetition for <b>rest</b> (If the endpoint is a RESTful one),
1375 	 * creating it if it does not already exist.
1376 	 *
1377      * <p>
1378      * <b>Definition:</b>
1379      * A definition of the restful capabilities of the solution, if any
1380      * </p> 
1381 	 */
1382 	public Rest getRestFirstRep() {
1383 		if (getRest().isEmpty()) {
1384 			return addRest();
1385 		}
1386 		return getRest().get(0); 
1387 	}
1388   
1389 	/**
1390 	 * Gets the value(s) for <b>messaging</b> (If messaging is supported).
1391 	 * creating it if it does
1392 	 * not exist. Will not return <code>null</code>.
1393 	 *
1394      * <p>
1395      * <b>Definition:</b>
1396      * A description of the messaging capabilities of the solution
1397      * </p> 
1398 	 */
1399 	public java.util.List<Messaging> getMessaging() {  
1400 		if (myMessaging == null) {
1401 			myMessaging = new java.util.ArrayList<Messaging>();
1402 		}
1403 		return myMessaging;
1404 	}
1405 
1406 	/**
1407 	 * Sets the value(s) for <b>messaging</b> (If messaging is supported)
1408 	 *
1409      * <p>
1410      * <b>Definition:</b>
1411      * A description of the messaging capabilities of the solution
1412      * </p> 
1413 	 */
1414 	public Conformance setMessaging(java.util.List<Messaging> theValue) {
1415 		myMessaging = theValue;
1416 		return this;
1417 	}
1418 
1419 	/**
1420 	 * Adds and returns a new value for <b>messaging</b> (If messaging is supported)
1421 	 *
1422      * <p>
1423      * <b>Definition:</b>
1424      * A description of the messaging capabilities of the solution
1425      * </p> 
1426 	 */
1427 	public Messaging addMessaging() {
1428 		Messaging newType = new Messaging();
1429 		getMessaging().add(newType);
1430 		return newType; 
1431 	}
1432 
1433 	/**
1434 	 * Gets the first repetition for <b>messaging</b> (If messaging is supported),
1435 	 * creating it if it does not already exist.
1436 	 *
1437      * <p>
1438      * <b>Definition:</b>
1439      * A description of the messaging capabilities of the solution
1440      * </p> 
1441 	 */
1442 	public Messaging getMessagingFirstRep() {
1443 		if (getMessaging().isEmpty()) {
1444 			return addMessaging();
1445 		}
1446 		return getMessaging().get(0); 
1447 	}
1448   
1449 	/**
1450 	 * Gets the value(s) for <b>document</b> (Document definition).
1451 	 * creating it if it does
1452 	 * not exist. Will not return <code>null</code>.
1453 	 *
1454      * <p>
1455      * <b>Definition:</b>
1456      * A document definition
1457      * </p> 
1458 	 */
1459 	public java.util.List<Document> getDocument() {  
1460 		if (myDocument == null) {
1461 			myDocument = new java.util.ArrayList<Document>();
1462 		}
1463 		return myDocument;
1464 	}
1465 
1466 	/**
1467 	 * Sets the value(s) for <b>document</b> (Document definition)
1468 	 *
1469      * <p>
1470      * <b>Definition:</b>
1471      * A document definition
1472      * </p> 
1473 	 */
1474 	public Conformance setDocument(java.util.List<Document> theValue) {
1475 		myDocument = theValue;
1476 		return this;
1477 	}
1478 
1479 	/**
1480 	 * Adds and returns a new value for <b>document</b> (Document definition)
1481 	 *
1482      * <p>
1483      * <b>Definition:</b>
1484      * A document definition
1485      * </p> 
1486 	 */
1487 	public Document addDocument() {
1488 		Document newType = new Document();
1489 		getDocument().add(newType);
1490 		return newType; 
1491 	}
1492 
1493 	/**
1494 	 * Gets the first repetition for <b>document</b> (Document definition),
1495 	 * creating it if it does not already exist.
1496 	 *
1497      * <p>
1498      * <b>Definition:</b>
1499      * A document definition
1500      * </p> 
1501 	 */
1502 	public Document getDocumentFirstRep() {
1503 		if (getDocument().isEmpty()) {
1504 			return addDocument();
1505 		}
1506 		return getDocument().get(0); 
1507 	}
1508   
1509 	/**
1510 	 * Block class for child element: <b>Conformance.software</b> (Software that is covered by this conformance statement)
1511 	 *
1512      * <p>
1513      * <b>Definition:</b>
1514      * Software that is covered by this conformance statement.  It is used when the profile describes the capabilities of a particular software version, independent of an installation.
1515      * </p> 
1516 	 */
1517 	@Block()	
1518 	public static class Software extends BaseIdentifiableElement implements IResourceBlock {
1519 	
1520 	@Child(name="name", type=StringDt.class, order=0, min=1, max=1)	
1521 	@Description(
1522 		shortDefinition="A name the software is known by",
1523 		formalDefinition="Name software is known by"
1524 	)
1525 	private StringDt myName;
1526 	
1527 	@Child(name="version", type=StringDt.class, order=1, min=0, max=1)	
1528 	@Description(
1529 		shortDefinition="Version covered by this statement",
1530 		formalDefinition="The version identifier for the software covered by this statement"
1531 	)
1532 	private StringDt myVersion;
1533 	
1534 	@Child(name="releaseDate", type=DateTimeDt.class, order=2, min=0, max=1)	
1535 	@Description(
1536 		shortDefinition="Date this version released",
1537 		formalDefinition="Date this version of the software released"
1538 	)
1539 	private DateTimeDt myReleaseDate;
1540 	
1541 
1542 	@Override
1543 	public boolean isEmpty() {
1544 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myName,  myVersion,  myReleaseDate);
1545 	}
1546 	
1547 	@Override
1548 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
1549 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myName, myVersion, myReleaseDate);
1550 	}
1551 
1552 	/**
1553 	 * Gets the value(s) for <b>name</b> (A name the software is known by).
1554 	 * creating it if it does
1555 	 * not exist. Will not return <code>null</code>.
1556 	 *
1557      * <p>
1558      * <b>Definition:</b>
1559      * Name software is known by
1560      * </p> 
1561 	 */
1562 	public StringDt getName() {  
1563 		if (myName == null) {
1564 			myName = new StringDt();
1565 		}
1566 		return myName;
1567 	}
1568 
1569 	/**
1570 	 * Sets the value(s) for <b>name</b> (A name the software is known by)
1571 	 *
1572      * <p>
1573      * <b>Definition:</b>
1574      * Name software is known by
1575      * </p> 
1576 	 */
1577 	public Software setName(StringDt theValue) {
1578 		myName = theValue;
1579 		return this;
1580 	}
1581 
1582  	/**
1583 	 * Sets the value for <b>name</b> (A name the software is known by)
1584 	 *
1585      * <p>
1586      * <b>Definition:</b>
1587      * Name software is known by
1588      * </p> 
1589 	 */
1590 	public Software setName( String theString) {
1591 		myName = new StringDt(theString); 
1592 		return this; 
1593 	}
1594 
1595  
1596 	/**
1597 	 * Gets the value(s) for <b>version</b> (Version covered by this statement).
1598 	 * creating it if it does
1599 	 * not exist. Will not return <code>null</code>.
1600 	 *
1601      * <p>
1602      * <b>Definition:</b>
1603      * The version identifier for the software covered by this statement
1604      * </p> 
1605 	 */
1606 	public StringDt getVersion() {  
1607 		if (myVersion == null) {
1608 			myVersion = new StringDt();
1609 		}
1610 		return myVersion;
1611 	}
1612 
1613 	/**
1614 	 * Sets the value(s) for <b>version</b> (Version covered by this statement)
1615 	 *
1616      * <p>
1617      * <b>Definition:</b>
1618      * The version identifier for the software covered by this statement
1619      * </p> 
1620 	 */
1621 	public Software setVersion(StringDt theValue) {
1622 		myVersion = theValue;
1623 		return this;
1624 	}
1625 
1626  	/**
1627 	 * Sets the value for <b>version</b> (Version covered by this statement)
1628 	 *
1629      * <p>
1630      * <b>Definition:</b>
1631      * The version identifier for the software covered by this statement
1632      * </p> 
1633 	 */
1634 	public Software setVersion( String theString) {
1635 		myVersion = new StringDt(theString); 
1636 		return this; 
1637 	}
1638 
1639  
1640 	/**
1641 	 * Gets the value(s) for <b>releaseDate</b> (Date this version released).
1642 	 * creating it if it does
1643 	 * not exist. Will not return <code>null</code>.
1644 	 *
1645      * <p>
1646      * <b>Definition:</b>
1647      * Date this version of the software released
1648      * </p> 
1649 	 */
1650 	public DateTimeDt getReleaseDate() {  
1651 		if (myReleaseDate == null) {
1652 			myReleaseDate = new DateTimeDt();
1653 		}
1654 		return myReleaseDate;
1655 	}
1656 
1657 	/**
1658 	 * Sets the value(s) for <b>releaseDate</b> (Date this version released)
1659 	 *
1660      * <p>
1661      * <b>Definition:</b>
1662      * Date this version of the software released
1663      * </p> 
1664 	 */
1665 	public Software setReleaseDate(DateTimeDt theValue) {
1666 		myReleaseDate = theValue;
1667 		return this;
1668 	}
1669 
1670  	/**
1671 	 * Sets the value for <b>releaseDate</b> (Date this version released)
1672 	 *
1673      * <p>
1674      * <b>Definition:</b>
1675      * Date this version of the software released
1676      * </p> 
1677 	 */
1678 	public Software setReleaseDateWithSecondsPrecision( Date theDate) {
1679 		myReleaseDate = new DateTimeDt(theDate); 
1680 		return this; 
1681 	}
1682 
1683 	/**
1684 	 * Sets the value for <b>releaseDate</b> (Date this version released)
1685 	 *
1686      * <p>
1687      * <b>Definition:</b>
1688      * Date this version of the software released
1689      * </p> 
1690 	 */
1691 	public Software setReleaseDate( Date theDate,  TemporalPrecisionEnum thePrecision) {
1692 		myReleaseDate = new DateTimeDt(theDate, thePrecision); 
1693 		return this; 
1694 	}
1695 
1696  
1697 
1698 	}
1699 
1700 
1701 	/**
1702 	 * Block class for child element: <b>Conformance.implementation</b> (If this describes a specific instance)
1703 	 *
1704      * <p>
1705      * <b>Definition:</b>
1706      * Identifies a specific implementation instance that is described by the conformance statement - i.e. a particular installation, rather than the capabilities of a software program
1707      * </p> 
1708 	 */
1709 	@Block()	
1710 	public static class Implementation extends BaseIdentifiableElement implements IResourceBlock {
1711 	
1712 	@Child(name="description", type=StringDt.class, order=0, min=1, max=1)	
1713 	@Description(
1714 		shortDefinition="Describes this specific instance",
1715 		formalDefinition="Information about the specific installation that this conformance statement relates to"
1716 	)
1717 	private StringDt myDescription;
1718 	
1719 	@Child(name="url", type=UriDt.class, order=1, min=0, max=1)	
1720 	@Description(
1721 		shortDefinition="Base URL for the installation",
1722 		formalDefinition="A base URL for the implementation.  This forms the base for REST interfaces as well as the mailbox and document interfaces."
1723 	)
1724 	private UriDt myUrl;
1725 	
1726 
1727 	@Override
1728 	public boolean isEmpty() {
1729 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myDescription,  myUrl);
1730 	}
1731 	
1732 	@Override
1733 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
1734 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myDescription, myUrl);
1735 	}
1736 
1737 	/**
1738 	 * Gets the value(s) for <b>description</b> (Describes this specific instance).
1739 	 * creating it if it does
1740 	 * not exist. Will not return <code>null</code>.
1741 	 *
1742      * <p>
1743      * <b>Definition:</b>
1744      * Information about the specific installation that this conformance statement relates to
1745      * </p> 
1746 	 */
1747 	public StringDt getDescription() {  
1748 		if (myDescription == null) {
1749 			myDescription = new StringDt();
1750 		}
1751 		return myDescription;
1752 	}
1753 
1754 	/**
1755 	 * Sets the value(s) for <b>description</b> (Describes this specific instance)
1756 	 *
1757      * <p>
1758      * <b>Definition:</b>
1759      * Information about the specific installation that this conformance statement relates to
1760      * </p> 
1761 	 */
1762 	public Implementation setDescription(StringDt theValue) {
1763 		myDescription = theValue;
1764 		return this;
1765 	}
1766 
1767  	/**
1768 	 * Sets the value for <b>description</b> (Describes this specific instance)
1769 	 *
1770      * <p>
1771      * <b>Definition:</b>
1772      * Information about the specific installation that this conformance statement relates to
1773      * </p> 
1774 	 */
1775 	public Implementation setDescription( String theString) {
1776 		myDescription = new StringDt(theString); 
1777 		return this; 
1778 	}
1779 
1780  
1781 	/**
1782 	 * Gets the value(s) for <b>url</b> (Base URL for the installation).
1783 	 * creating it if it does
1784 	 * not exist. Will not return <code>null</code>.
1785 	 *
1786      * <p>
1787      * <b>Definition:</b>
1788      * A base URL for the implementation.  This forms the base for REST interfaces as well as the mailbox and document interfaces.
1789      * </p> 
1790 	 */
1791 	public UriDt getUrl() {  
1792 		if (myUrl == null) {
1793 			myUrl = new UriDt();
1794 		}
1795 		return myUrl;
1796 	}
1797 
1798 	/**
1799 	 * Sets the value(s) for <b>url</b> (Base URL for the installation)
1800 	 *
1801      * <p>
1802      * <b>Definition:</b>
1803      * A base URL for the implementation.  This forms the base for REST interfaces as well as the mailbox and document interfaces.
1804      * </p> 
1805 	 */
1806 	public Implementation setUrl(UriDt theValue) {
1807 		myUrl = theValue;
1808 		return this;
1809 	}
1810 
1811  	/**
1812 	 * Sets the value for <b>url</b> (Base URL for the installation)
1813 	 *
1814      * <p>
1815      * <b>Definition:</b>
1816      * A base URL for the implementation.  This forms the base for REST interfaces as well as the mailbox and document interfaces.
1817      * </p> 
1818 	 */
1819 	public Implementation setUrl( String theUri) {
1820 		myUrl = new UriDt(theUri); 
1821 		return this; 
1822 	}
1823 
1824  
1825 
1826 	}
1827 
1828 
1829 	/**
1830 	 * Block class for child element: <b>Conformance.rest</b> (If the endpoint is a RESTful one)
1831 	 *
1832      * <p>
1833      * <b>Definition:</b>
1834      * A definition of the restful capabilities of the solution, if any
1835      * </p> 
1836 	 */
1837 	@Block()	
1838 	public static class Rest extends BaseIdentifiableElement implements IResourceBlock {
1839 	
1840 	@Child(name="mode", type=CodeDt.class, order=0, min=1, max=1)	
1841 	@Description(
1842 		shortDefinition="client | server",
1843 		formalDefinition="Identifies whether this portion of the statement is describing ability to initiate or receive restful operations"
1844 	)
1845 	private BoundCodeDt<RestfulConformanceModeEnum> myMode;
1846 	
1847 	@Child(name="documentation", type=StringDt.class, order=1, min=0, max=1)	
1848 	@Description(
1849 		shortDefinition="General description of implementation",
1850 		formalDefinition="Information about the system's restful capabilities that apply across all applications, such as security"
1851 	)
1852 	private StringDt myDocumentation;
1853 	
1854 	@Child(name="security", order=2, min=0, max=1)	
1855 	@Description(
1856 		shortDefinition="Information about security of implementation",
1857 		formalDefinition="Information about security of implementation"
1858 	)
1859 	private RestSecurity mySecurity;
1860 	
1861 	@Child(name="resource", order=3, min=1, max=Child.MAX_UNLIMITED)	
1862 	@Description(
1863 		shortDefinition="Resource served on the REST interface",
1864 		formalDefinition="A specification of the restful capabilities of the solution for a specific resource type"
1865 	)
1866 	private java.util.List<RestResource> myResource;
1867 	
1868 	@Child(name="operation", order=4, min=0, max=Child.MAX_UNLIMITED)	
1869 	@Description(
1870 		shortDefinition="What operations are supported?",
1871 		formalDefinition="A specification of restful operations supported by the system"
1872 	)
1873 	private java.util.List<RestOperation> myOperation;
1874 	
1875 	@Child(name="query", order=5, min=0, max=Child.MAX_UNLIMITED)	
1876 	@Description(
1877 		shortDefinition="Definition of a named query",
1878 		formalDefinition="Definition of a named query and its parameters and their meaning"
1879 	)
1880 	private java.util.List<RestQuery> myQuery;
1881 	
1882 	@Child(name="documentMailbox", type=UriDt.class, order=6, min=0, max=Child.MAX_UNLIMITED)	
1883 	@Description(
1884 		shortDefinition="How documents are accepted in /Mailbox",
1885 		formalDefinition="A list of profiles that this server implements for accepting documents in the mailbox. If this list is empty, then documents are not accepted. The base specification has the profile identifier \"http://hl7.org/fhir/documents/mailbox\". Other specifications can declare their own identifier for this purpose"
1886 	)
1887 	private java.util.List<UriDt> myDocumentMailbox;
1888 	
1889 
1890 	@Override
1891 	public boolean isEmpty() {
1892 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myMode,  myDocumentation,  mySecurity,  myResource,  myOperation,  myQuery,  myDocumentMailbox);
1893 	}
1894 	
1895 	@Override
1896 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
1897 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myMode, myDocumentation, mySecurity, myResource, myOperation, myQuery, myDocumentMailbox);
1898 	}
1899 
1900 	/**
1901 	 * Gets the value(s) for <b>mode</b> (client | server).
1902 	 * creating it if it does
1903 	 * not exist. Will not return <code>null</code>.
1904 	 *
1905      * <p>
1906      * <b>Definition:</b>
1907      * Identifies whether this portion of the statement is describing ability to initiate or receive restful operations
1908      * </p> 
1909 	 */
1910 	public BoundCodeDt<RestfulConformanceModeEnum> getMode() {  
1911 		if (myMode == null) {
1912 			myMode = new BoundCodeDt<RestfulConformanceModeEnum>(RestfulConformanceModeEnum.VALUESET_BINDER);
1913 		}
1914 		return myMode;
1915 	}
1916 
1917 	/**
1918 	 * Sets the value(s) for <b>mode</b> (client | server)
1919 	 *
1920      * <p>
1921      * <b>Definition:</b>
1922      * Identifies whether this portion of the statement is describing ability to initiate or receive restful operations
1923      * </p> 
1924 	 */
1925 	public Rest setMode(BoundCodeDt<RestfulConformanceModeEnum> theValue) {
1926 		myMode = theValue;
1927 		return this;
1928 	}
1929 
1930 	/**
1931 	 * Sets the value(s) for <b>mode</b> (client | server)
1932 	 *
1933      * <p>
1934      * <b>Definition:</b>
1935      * Identifies whether this portion of the statement is describing ability to initiate or receive restful operations
1936      * </p> 
1937 	 */
1938 	public Rest setMode(RestfulConformanceModeEnum theValue) {
1939 		getMode().setValueAsEnum(theValue);
1940 		return this;
1941 	}
1942 
1943   
1944 	/**
1945 	 * Gets the value(s) for <b>documentation</b> (General description of implementation).
1946 	 * creating it if it does
1947 	 * not exist. Will not return <code>null</code>.
1948 	 *
1949      * <p>
1950      * <b>Definition:</b>
1951      * Information about the system's restful capabilities that apply across all applications, such as security
1952      * </p> 
1953 	 */
1954 	public StringDt getDocumentation() {  
1955 		if (myDocumentation == null) {
1956 			myDocumentation = new StringDt();
1957 		}
1958 		return myDocumentation;
1959 	}
1960 
1961 	/**
1962 	 * Sets the value(s) for <b>documentation</b> (General description of implementation)
1963 	 *
1964      * <p>
1965      * <b>Definition:</b>
1966      * Information about the system's restful capabilities that apply across all applications, such as security
1967      * </p> 
1968 	 */
1969 	public Rest setDocumentation(StringDt theValue) {
1970 		myDocumentation = theValue;
1971 		return this;
1972 	}
1973 
1974  	/**
1975 	 * Sets the value for <b>documentation</b> (General description of implementation)
1976 	 *
1977      * <p>
1978      * <b>Definition:</b>
1979      * Information about the system's restful capabilities that apply across all applications, such as security
1980      * </p> 
1981 	 */
1982 	public Rest setDocumentation( String theString) {
1983 		myDocumentation = new StringDt(theString); 
1984 		return this; 
1985 	}
1986 
1987  
1988 	/**
1989 	 * Gets the value(s) for <b>security</b> (Information about security of implementation).
1990 	 * creating it if it does
1991 	 * not exist. Will not return <code>null</code>.
1992 	 *
1993      * <p>
1994      * <b>Definition:</b>
1995      * Information about security of implementation
1996      * </p> 
1997 	 */
1998 	public RestSecurity getSecurity() {  
1999 		if (mySecurity == null) {
2000 			mySecurity = new RestSecurity();
2001 		}
2002 		return mySecurity;
2003 	}
2004 
2005 	/**
2006 	 * Sets the value(s) for <b>security</b> (Information about security of implementation)
2007 	 *
2008      * <p>
2009      * <b>Definition:</b>
2010      * Information about security of implementation
2011      * </p> 
2012 	 */
2013 	public Rest setSecurity(RestSecurity theValue) {
2014 		mySecurity = theValue;
2015 		return this;
2016 	}
2017 
2018   
2019 	/**
2020 	 * Gets the value(s) for <b>resource</b> (Resource served on the REST interface).
2021 	 * creating it if it does
2022 	 * not exist. Will not return <code>null</code>.
2023 	 *
2024      * <p>
2025      * <b>Definition:</b>
2026      * A specification of the restful capabilities of the solution for a specific resource type
2027      * </p> 
2028 	 */
2029 	public java.util.List<RestResource> getResource() {  
2030 		if (myResource == null) {
2031 			myResource = new java.util.ArrayList<RestResource>();
2032 		}
2033 		return myResource;
2034 	}
2035 
2036 	/**
2037 	 * Sets the value(s) for <b>resource</b> (Resource served on the REST interface)
2038 	 *
2039      * <p>
2040      * <b>Definition:</b>
2041      * A specification of the restful capabilities of the solution for a specific resource type
2042      * </p> 
2043 	 */
2044 	public Rest setResource(java.util.List<RestResource> theValue) {
2045 		myResource = theValue;
2046 		return this;
2047 	}
2048 
2049 	/**
2050 	 * Adds and returns a new value for <b>resource</b> (Resource served on the REST interface)
2051 	 *
2052      * <p>
2053      * <b>Definition:</b>
2054      * A specification of the restful capabilities of the solution for a specific resource type
2055      * </p> 
2056 	 */
2057 	public RestResource addResource() {
2058 		RestResource newType = new RestResource();
2059 		getResource().add(newType);
2060 		return newType; 
2061 	}
2062 
2063 	/**
2064 	 * Gets the first repetition for <b>resource</b> (Resource served on the REST interface),
2065 	 * creating it if it does not already exist.
2066 	 *
2067      * <p>
2068      * <b>Definition:</b>
2069      * A specification of the restful capabilities of the solution for a specific resource type
2070      * </p> 
2071 	 */
2072 	public RestResource getResourceFirstRep() {
2073 		if (getResource().isEmpty()) {
2074 			return addResource();
2075 		}
2076 		return getResource().get(0); 
2077 	}
2078   
2079 	/**
2080 	 * Gets the value(s) for <b>operation</b> (What operations are supported?).
2081 	 * creating it if it does
2082 	 * not exist. Will not return <code>null</code>.
2083 	 *
2084      * <p>
2085      * <b>Definition:</b>
2086      * A specification of restful operations supported by the system
2087      * </p> 
2088 	 */
2089 	public java.util.List<RestOperation> getOperation() {  
2090 		if (myOperation == null) {
2091 			myOperation = new java.util.ArrayList<RestOperation>();
2092 		}
2093 		return myOperation;
2094 	}
2095 
2096 	/**
2097 	 * Sets the value(s) for <b>operation</b> (What operations are supported?)
2098 	 *
2099      * <p>
2100      * <b>Definition:</b>
2101      * A specification of restful operations supported by the system
2102      * </p> 
2103 	 */
2104 	public Rest setOperation(java.util.List<RestOperation> theValue) {
2105 		myOperation = theValue;
2106 		return this;
2107 	}
2108 
2109 	/**
2110 	 * Adds and returns a new value for <b>operation</b> (What operations are supported?)
2111 	 *
2112      * <p>
2113      * <b>Definition:</b>
2114      * A specification of restful operations supported by the system
2115      * </p> 
2116 	 */
2117 	public RestOperation addOperation() {
2118 		RestOperation newType = new RestOperation();
2119 		getOperation().add(newType);
2120 		return newType; 
2121 	}
2122 
2123 	/**
2124 	 * Gets the first repetition for <b>operation</b> (What operations are supported?),
2125 	 * creating it if it does not already exist.
2126 	 *
2127      * <p>
2128      * <b>Definition:</b>
2129      * A specification of restful operations supported by the system
2130      * </p> 
2131 	 */
2132 	public RestOperation getOperationFirstRep() {
2133 		if (getOperation().isEmpty()) {
2134 			return addOperation();
2135 		}
2136 		return getOperation().get(0); 
2137 	}
2138   
2139 	/**
2140 	 * Gets the value(s) for <b>query</b> (Definition of a named query).
2141 	 * creating it if it does
2142 	 * not exist. Will not return <code>null</code>.
2143 	 *
2144      * <p>
2145      * <b>Definition:</b>
2146      * Definition of a named query and its parameters and their meaning
2147      * </p> 
2148 	 */
2149 	public java.util.List<RestQuery> getQuery() {  
2150 		if (myQuery == null) {
2151 			myQuery = new java.util.ArrayList<RestQuery>();
2152 		}
2153 		return myQuery;
2154 	}
2155 
2156 	/**
2157 	 * Sets the value(s) for <b>query</b> (Definition of a named query)
2158 	 *
2159      * <p>
2160      * <b>Definition:</b>
2161      * Definition of a named query and its parameters and their meaning
2162      * </p> 
2163 	 */
2164 	public Rest setQuery(java.util.List<RestQuery> theValue) {
2165 		myQuery = theValue;
2166 		return this;
2167 	}
2168 
2169 	/**
2170 	 * Adds and returns a new value for <b>query</b> (Definition of a named query)
2171 	 *
2172      * <p>
2173      * <b>Definition:</b>
2174      * Definition of a named query and its parameters and their meaning
2175      * </p> 
2176 	 */
2177 	public RestQuery addQuery() {
2178 		RestQuery newType = new RestQuery();
2179 		getQuery().add(newType);
2180 		return newType; 
2181 	}
2182 
2183 	/**
2184 	 * Gets the first repetition for <b>query</b> (Definition of a named query),
2185 	 * creating it if it does not already exist.
2186 	 *
2187      * <p>
2188      * <b>Definition:</b>
2189      * Definition of a named query and its parameters and their meaning
2190      * </p> 
2191 	 */
2192 	public RestQuery getQueryFirstRep() {
2193 		if (getQuery().isEmpty()) {
2194 			return addQuery();
2195 		}
2196 		return getQuery().get(0); 
2197 	}
2198   
2199 	/**
2200 	 * Gets the value(s) for <b>documentMailbox</b> (How documents are accepted in /Mailbox).
2201 	 * creating it if it does
2202 	 * not exist. Will not return <code>null</code>.
2203 	 *
2204      * <p>
2205      * <b>Definition:</b>
2206      * A list of profiles that this server implements for accepting documents in the mailbox. If this list is empty, then documents are not accepted. The base specification has the profile identifier \"http://hl7.org/fhir/documents/mailbox\". Other specifications can declare their own identifier for this purpose
2207      * </p> 
2208 	 */
2209 	public java.util.List<UriDt> getDocumentMailbox() {  
2210 		if (myDocumentMailbox == null) {
2211 			myDocumentMailbox = new java.util.ArrayList<UriDt>();
2212 		}
2213 		return myDocumentMailbox;
2214 	}
2215 
2216 	/**
2217 	 * Sets the value(s) for <b>documentMailbox</b> (How documents are accepted in /Mailbox)
2218 	 *
2219      * <p>
2220      * <b>Definition:</b>
2221      * A list of profiles that this server implements for accepting documents in the mailbox. If this list is empty, then documents are not accepted. The base specification has the profile identifier \"http://hl7.org/fhir/documents/mailbox\". Other specifications can declare their own identifier for this purpose
2222      * </p> 
2223 	 */
2224 	public Rest setDocumentMailbox(java.util.List<UriDt> theValue) {
2225 		myDocumentMailbox = theValue;
2226 		return this;
2227 	}
2228 
2229 	/**
2230 	 * Adds and returns a new value for <b>documentMailbox</b> (How documents are accepted in /Mailbox)
2231 	 *
2232      * <p>
2233      * <b>Definition:</b>
2234      * A list of profiles that this server implements for accepting documents in the mailbox. If this list is empty, then documents are not accepted. The base specification has the profile identifier \"http://hl7.org/fhir/documents/mailbox\". Other specifications can declare their own identifier for this purpose
2235      * </p> 
2236 	 */
2237 	public UriDt addDocumentMailbox() {
2238 		UriDt newType = new UriDt();
2239 		getDocumentMailbox().add(newType);
2240 		return newType; 
2241 	}
2242 
2243 	/**
2244 	 * Gets the first repetition for <b>documentMailbox</b> (How documents are accepted in /Mailbox),
2245 	 * creating it if it does not already exist.
2246 	 *
2247      * <p>
2248      * <b>Definition:</b>
2249      * A list of profiles that this server implements for accepting documents in the mailbox. If this list is empty, then documents are not accepted. The base specification has the profile identifier \"http://hl7.org/fhir/documents/mailbox\". Other specifications can declare their own identifier for this purpose
2250      * </p> 
2251 	 */
2252 	public UriDt getDocumentMailboxFirstRep() {
2253 		if (getDocumentMailbox().isEmpty()) {
2254 			return addDocumentMailbox();
2255 		}
2256 		return getDocumentMailbox().get(0); 
2257 	}
2258  	/**
2259 	 * Adds a new value for <b>documentMailbox</b> (How documents are accepted in /Mailbox)
2260 	 *
2261      * <p>
2262      * <b>Definition:</b>
2263      * A list of profiles that this server implements for accepting documents in the mailbox. If this list is empty, then documents are not accepted. The base specification has the profile identifier \"http://hl7.org/fhir/documents/mailbox\". Other specifications can declare their own identifier for this purpose
2264      * </p> 
2265      *
2266      * @return Returns a reference to this object, to allow for simple chaining.
2267 	 */
2268 	public Rest addDocumentMailbox( String theUri) {
2269 		if (myDocumentMailbox == null) {
2270 			myDocumentMailbox = new java.util.ArrayList<UriDt>();
2271 		}
2272 		myDocumentMailbox.add(new UriDt(theUri));
2273 		return this; 
2274 	}
2275 
2276  
2277 
2278 	}
2279 
2280 	/**
2281 	 * Block class for child element: <b>Conformance.rest.security</b> (Information about security of implementation)
2282 	 *
2283      * <p>
2284      * <b>Definition:</b>
2285      * Information about security of implementation
2286      * </p> 
2287 	 */
2288 	@Block()	
2289 	public static class RestSecurity extends BaseIdentifiableElement implements IResourceBlock {
2290 	
2291 	@Child(name="cors", type=BooleanDt.class, order=0, min=0, max=1)	
2292 	@Description(
2293 		shortDefinition="Adds CORS Headers (http://enable-cors.org/)",
2294 		formalDefinition="Server adds CORS headers when responding to requests - this enables javascript applications to yuse the server"
2295 	)
2296 	private BooleanDt myCors;
2297 	
2298 	@Child(name="service", type=CodeableConceptDt.class, order=1, min=0, max=Child.MAX_UNLIMITED)	
2299 	@Description(
2300 		shortDefinition="OAuth | OAuth2 | NTLM | Basic | Kerberos",
2301 		formalDefinition="Types of security services are supported/required by the system"
2302 	)
2303 	private java.util.List<BoundCodeableConceptDt<RestfulSecurityServiceEnum>> myService;
2304 	
2305 	@Child(name="description", type=StringDt.class, order=2, min=0, max=1)	
2306 	@Description(
2307 		shortDefinition="General description of how security works",
2308 		formalDefinition="General description of how security works"
2309 	)
2310 	private StringDt myDescription;
2311 	
2312 	@Child(name="certificate", order=3, min=0, max=Child.MAX_UNLIMITED)	
2313 	@Description(
2314 		shortDefinition="Certificates associated with security profiles",
2315 		formalDefinition="Certificates associated with security profiles"
2316 	)
2317 	private java.util.List<RestSecurityCertificate> myCertificate;
2318 	
2319 
2320 	@Override
2321 	public boolean isEmpty() {
2322 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myCors,  myService,  myDescription,  myCertificate);
2323 	}
2324 	
2325 	@Override
2326 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
2327 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myCors, myService, myDescription, myCertificate);
2328 	}
2329 
2330 	/**
2331 	 * Gets the value(s) for <b>cors</b> (Adds CORS Headers (http://enable-cors.org/)).
2332 	 * creating it if it does
2333 	 * not exist. Will not return <code>null</code>.
2334 	 *
2335      * <p>
2336      * <b>Definition:</b>
2337      * Server adds CORS headers when responding to requests - this enables javascript applications to yuse the server
2338      * </p> 
2339 	 */
2340 	public BooleanDt getCors() {  
2341 		if (myCors == null) {
2342 			myCors = new BooleanDt();
2343 		}
2344 		return myCors;
2345 	}
2346 
2347 	/**
2348 	 * Sets the value(s) for <b>cors</b> (Adds CORS Headers (http://enable-cors.org/))
2349 	 *
2350      * <p>
2351      * <b>Definition:</b>
2352      * Server adds CORS headers when responding to requests - this enables javascript applications to yuse the server
2353      * </p> 
2354 	 */
2355 	public RestSecurity setCors(BooleanDt theValue) {
2356 		myCors = theValue;
2357 		return this;
2358 	}
2359 
2360  	/**
2361 	 * Sets the value for <b>cors</b> (Adds CORS Headers (http://enable-cors.org/))
2362 	 *
2363      * <p>
2364      * <b>Definition:</b>
2365      * Server adds CORS headers when responding to requests - this enables javascript applications to yuse the server
2366      * </p> 
2367 	 */
2368 	public RestSecurity setCors( boolean theBoolean) {
2369 		myCors = new BooleanDt(theBoolean); 
2370 		return this; 
2371 	}
2372 
2373  
2374 	/**
2375 	 * Gets the value(s) for <b>service</b> (OAuth | OAuth2 | NTLM | Basic | Kerberos).
2376 	 * creating it if it does
2377 	 * not exist. Will not return <code>null</code>.
2378 	 *
2379      * <p>
2380      * <b>Definition:</b>
2381      * Types of security services are supported/required by the system
2382      * </p> 
2383 	 */
2384 	public java.util.List<BoundCodeableConceptDt<RestfulSecurityServiceEnum>> getService() {  
2385 		if (myService == null) {
2386 			myService = new java.util.ArrayList<BoundCodeableConceptDt<RestfulSecurityServiceEnum>>();
2387 		}
2388 		return myService;
2389 	}
2390 
2391 	/**
2392 	 * Sets the value(s) for <b>service</b> (OAuth | OAuth2 | NTLM | Basic | Kerberos)
2393 	 *
2394      * <p>
2395      * <b>Definition:</b>
2396      * Types of security services are supported/required by the system
2397      * </p> 
2398 	 */
2399 	public RestSecurity setService(java.util.List<BoundCodeableConceptDt<RestfulSecurityServiceEnum>> theValue) {
2400 		myService = theValue;
2401 		return this;
2402 	}
2403 
2404 	/**
2405 	 * Add a value for <b>service</b> (OAuth | OAuth2 | NTLM | Basic | Kerberos) using an enumerated type. This
2406 	 * is intended as a convenience method for situations where the FHIR defined ValueSets are mandatory
2407 	 * or contain the desirable codes. If you wish to use codes other than those which are built-in, 
2408 	 * you may also use the {@link #addType()} method.
2409 	 *
2410      * <p>
2411      * <b>Definition:</b>
2412      * Types of security services are supported/required by the system
2413      * </p> 
2414 	 */
2415 	public BoundCodeableConceptDt<RestfulSecurityServiceEnum> addService(RestfulSecurityServiceEnum theValue) {
2416 		BoundCodeableConceptDt<RestfulSecurityServiceEnum> retVal = new BoundCodeableConceptDt<RestfulSecurityServiceEnum>(RestfulSecurityServiceEnum.VALUESET_BINDER, theValue);
2417 		getService().add(retVal);
2418 		return retVal;
2419 	}
2420 
2421 	/**
2422 	 * Gets the first repetition for <b>service</b> (OAuth | OAuth2 | NTLM | Basic | Kerberos),
2423 	 * creating it if it does not already exist.
2424 	 *
2425      * <p>
2426      * <b>Definition:</b>
2427      * Types of security services are supported/required by the system
2428      * </p> 
2429 	 */
2430 	public BoundCodeableConceptDt<RestfulSecurityServiceEnum> getServiceFirstRep() {
2431 		if (getService().size() == 0) {
2432 			addService();
2433 		}
2434 		return getService().get(0);
2435 	}
2436 
2437 	/**
2438 	 * Add a value for <b>service</b> (OAuth | OAuth2 | NTLM | Basic | Kerberos)
2439 	 *
2440      * <p>
2441      * <b>Definition:</b>
2442      * Types of security services are supported/required by the system
2443      * </p> 
2444 	 */
2445 	public BoundCodeableConceptDt<RestfulSecurityServiceEnum> addService() {
2446 		BoundCodeableConceptDt<RestfulSecurityServiceEnum> retVal = new BoundCodeableConceptDt<RestfulSecurityServiceEnum>(RestfulSecurityServiceEnum.VALUESET_BINDER);
2447 		getService().add(retVal);
2448 		return retVal;
2449 	}
2450 
2451 	/**
2452 	 * Sets the value(s), and clears any existing value(s) for <b>service</b> (OAuth | OAuth2 | NTLM | Basic | Kerberos)
2453 	 *
2454      * <p>
2455      * <b>Definition:</b>
2456      * Types of security services are supported/required by the system
2457      * </p> 
2458 	 */
2459 	public RestSecurity setService(RestfulSecurityServiceEnum theValue) {
2460 		getService().clear();
2461 		addService(theValue);
2462 		return this;
2463 	}
2464 
2465   
2466 	/**
2467 	 * Gets the value(s) for <b>description</b> (General description of how security works).
2468 	 * creating it if it does
2469 	 * not exist. Will not return <code>null</code>.
2470 	 *
2471      * <p>
2472      * <b>Definition:</b>
2473      * General description of how security works
2474      * </p> 
2475 	 */
2476 	public StringDt getDescription() {  
2477 		if (myDescription == null) {
2478 			myDescription = new StringDt();
2479 		}
2480 		return myDescription;
2481 	}
2482 
2483 	/**
2484 	 * Sets the value(s) for <b>description</b> (General description of how security works)
2485 	 *
2486      * <p>
2487      * <b>Definition:</b>
2488      * General description of how security works
2489      * </p> 
2490 	 */
2491 	public RestSecurity setDescription(StringDt theValue) {
2492 		myDescription = theValue;
2493 		return this;
2494 	}
2495 
2496  	/**
2497 	 * Sets the value for <b>description</b> (General description of how security works)
2498 	 *
2499      * <p>
2500      * <b>Definition:</b>
2501      * General description of how security works
2502      * </p> 
2503 	 */
2504 	public RestSecurity setDescription( String theString) {
2505 		myDescription = new StringDt(theString); 
2506 		return this; 
2507 	}
2508 
2509  
2510 	/**
2511 	 * Gets the value(s) for <b>certificate</b> (Certificates associated with security profiles).
2512 	 * creating it if it does
2513 	 * not exist. Will not return <code>null</code>.
2514 	 *
2515      * <p>
2516      * <b>Definition:</b>
2517      * Certificates associated with security profiles
2518      * </p> 
2519 	 */
2520 	public java.util.List<RestSecurityCertificate> getCertificate() {  
2521 		if (myCertificate == null) {
2522 			myCertificate = new java.util.ArrayList<RestSecurityCertificate>();
2523 		}
2524 		return myCertificate;
2525 	}
2526 
2527 	/**
2528 	 * Sets the value(s) for <b>certificate</b> (Certificates associated with security profiles)
2529 	 *
2530      * <p>
2531      * <b>Definition:</b>
2532      * Certificates associated with security profiles
2533      * </p> 
2534 	 */
2535 	public RestSecurity setCertificate(java.util.List<RestSecurityCertificate> theValue) {
2536 		myCertificate = theValue;
2537 		return this;
2538 	}
2539 
2540 	/**
2541 	 * Adds and returns a new value for <b>certificate</b> (Certificates associated with security profiles)
2542 	 *
2543      * <p>
2544      * <b>Definition:</b>
2545      * Certificates associated with security profiles
2546      * </p> 
2547 	 */
2548 	public RestSecurityCertificate addCertificate() {
2549 		RestSecurityCertificate newType = new RestSecurityCertificate();
2550 		getCertificate().add(newType);
2551 		return newType; 
2552 	}
2553 
2554 	/**
2555 	 * Gets the first repetition for <b>certificate</b> (Certificates associated with security profiles),
2556 	 * creating it if it does not already exist.
2557 	 *
2558      * <p>
2559      * <b>Definition:</b>
2560      * Certificates associated with security profiles
2561      * </p> 
2562 	 */
2563 	public RestSecurityCertificate getCertificateFirstRep() {
2564 		if (getCertificate().isEmpty()) {
2565 			return addCertificate();
2566 		}
2567 		return getCertificate().get(0); 
2568 	}
2569   
2570 
2571 	}
2572 
2573 	/**
2574 	 * Block class for child element: <b>Conformance.rest.security.certificate</b> (Certificates associated with security profiles)
2575 	 *
2576      * <p>
2577      * <b>Definition:</b>
2578      * Certificates associated with security profiles
2579      * </p> 
2580 	 */
2581 	@Block()	
2582 	public static class RestSecurityCertificate extends BaseIdentifiableElement implements IResourceBlock {
2583 	
2584 	@Child(name="type", type=CodeDt.class, order=0, min=0, max=1)	
2585 	@Description(
2586 		shortDefinition="Mime type for certificate",
2587 		formalDefinition="Mime type for certificate"
2588 	)
2589 	private CodeDt myType;
2590 	
2591 	@Child(name="blob", type=Base64BinaryDt.class, order=1, min=0, max=1)	
2592 	@Description(
2593 		shortDefinition="Actual certificate",
2594 		formalDefinition="Actual certificate"
2595 	)
2596 	private Base64BinaryDt myBlob;
2597 	
2598 
2599 	@Override
2600 	public boolean isEmpty() {
2601 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myType,  myBlob);
2602 	}
2603 	
2604 	@Override
2605 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
2606 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myType, myBlob);
2607 	}
2608 
2609 	/**
2610 	 * Gets the value(s) for <b>type</b> (Mime type for certificate).
2611 	 * creating it if it does
2612 	 * not exist. Will not return <code>null</code>.
2613 	 *
2614      * <p>
2615      * <b>Definition:</b>
2616      * Mime type for certificate
2617      * </p> 
2618 	 */
2619 	public CodeDt getType() {  
2620 		if (myType == null) {
2621 			myType = new CodeDt();
2622 		}
2623 		return myType;
2624 	}
2625 
2626 	/**
2627 	 * Sets the value(s) for <b>type</b> (Mime type for certificate)
2628 	 *
2629      * <p>
2630      * <b>Definition:</b>
2631      * Mime type for certificate
2632      * </p> 
2633 	 */
2634 	public RestSecurityCertificate setType(CodeDt theValue) {
2635 		myType = theValue;
2636 		return this;
2637 	}
2638 
2639  	/**
2640 	 * Sets the value for <b>type</b> (Mime type for certificate)
2641 	 *
2642      * <p>
2643      * <b>Definition:</b>
2644      * Mime type for certificate
2645      * </p> 
2646 	 */
2647 	public RestSecurityCertificate setType( String theCode) {
2648 		myType = new CodeDt(theCode); 
2649 		return this; 
2650 	}
2651 
2652  
2653 	/**
2654 	 * Gets the value(s) for <b>blob</b> (Actual certificate).
2655 	 * creating it if it does
2656 	 * not exist. Will not return <code>null</code>.
2657 	 *
2658      * <p>
2659      * <b>Definition:</b>
2660      * Actual certificate
2661      * </p> 
2662 	 */
2663 	public Base64BinaryDt getBlob() {  
2664 		if (myBlob == null) {
2665 			myBlob = new Base64BinaryDt();
2666 		}
2667 		return myBlob;
2668 	}
2669 
2670 	/**
2671 	 * Sets the value(s) for <b>blob</b> (Actual certificate)
2672 	 *
2673      * <p>
2674      * <b>Definition:</b>
2675      * Actual certificate
2676      * </p> 
2677 	 */
2678 	public RestSecurityCertificate setBlob(Base64BinaryDt theValue) {
2679 		myBlob = theValue;
2680 		return this;
2681 	}
2682 
2683  	/**
2684 	 * Sets the value for <b>blob</b> (Actual certificate)
2685 	 *
2686      * <p>
2687      * <b>Definition:</b>
2688      * Actual certificate
2689      * </p> 
2690 	 */
2691 	public RestSecurityCertificate setBlob( byte[] theBytes) {
2692 		myBlob = new Base64BinaryDt(theBytes); 
2693 		return this; 
2694 	}
2695 
2696  
2697 
2698 	}
2699 
2700 
2701 
2702 	/**
2703 	 * Block class for child element: <b>Conformance.rest.resource</b> (Resource served on the REST interface)
2704 	 *
2705      * <p>
2706      * <b>Definition:</b>
2707      * A specification of the restful capabilities of the solution for a specific resource type
2708      * </p> 
2709 	 */
2710 	@Block()	
2711 	public static class RestResource extends BaseIdentifiableElement implements IResourceBlock {
2712 	
2713 	@Child(name="type", type=CodeDt.class, order=0, min=1, max=1)	
2714 	@Description(
2715 		shortDefinition="A resource type that is supported",
2716 		formalDefinition="A type of resource exposed via the restful interface"
2717 	)
2718 	private BoundCodeDt<ResourceTypeEnum> myType;
2719 	
2720 	@Child(name="profile", order=1, min=0, max=1, type={
2721 		ca.uhn.fhir.model.dstu.resource.Profile.class	})
2722 	@Description(
2723 		shortDefinition="What structural features are supported",
2724 		formalDefinition="A specification of the profile that describes the solution's support for the resource, including any constraints on cardinality, bindings, lengths or other limitations"
2725 	)
2726 	private ResourceReferenceDt myProfile;
2727 	
2728 	@Child(name="operation", order=2, min=1, max=Child.MAX_UNLIMITED)	
2729 	@Description(
2730 		shortDefinition="What operations are supported?",
2731 		formalDefinition="Identifies a restful operation supported by the solution"
2732 	)
2733 	private java.util.List<RestResourceOperation> myOperation;
2734 	
2735 	@Child(name="readHistory", type=BooleanDt.class, order=3, min=0, max=1)	
2736 	@Description(
2737 		shortDefinition="Whether vRead can return past versions",
2738 		formalDefinition="A flag for whether the server is able to return past versions as part of the vRead operation"
2739 	)
2740 	private BooleanDt myReadHistory;
2741 	
2742 	@Child(name="updateCreate", type=BooleanDt.class, order=4, min=0, max=1)	
2743 	@Description(
2744 		shortDefinition="If allows/uses update to a new location",
2745 		formalDefinition="A flag to indicate that the server allows the client to create new identities on the server. If the update operation is used (client) or allowed (server) to a new location where a resource doesn't already exist. This means that the server allows the client to create new identities on the server"
2746 	)
2747 	private BooleanDt myUpdateCreate;
2748 	
2749 	@Child(name="searchInclude", type=StringDt.class, order=5, min=0, max=Child.MAX_UNLIMITED)	
2750 	@Description(
2751 		shortDefinition="_include values supported by the server",
2752 		formalDefinition="A list of _include values supported by the server"
2753 	)
2754 	private java.util.List<StringDt> mySearchInclude;
2755 	
2756 	@Child(name="searchParam", order=6, min=0, max=Child.MAX_UNLIMITED)	
2757 	@Description(
2758 		shortDefinition="Additional search params defined",
2759 		formalDefinition="Additional search parameters for implementations to support and/or make use of"
2760 	)
2761 	private java.util.List<RestResourceSearchParam> mySearchParam;
2762 	
2763 
2764 	@Override
2765 	public boolean isEmpty() {
2766 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myType,  myProfile,  myOperation,  myReadHistory,  myUpdateCreate,  mySearchInclude,  mySearchParam);
2767 	}
2768 	
2769 	@Override
2770 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
2771 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myType, myProfile, myOperation, myReadHistory, myUpdateCreate, mySearchInclude, mySearchParam);
2772 	}
2773 
2774 	/**
2775 	 * Gets the value(s) for <b>type</b> (A resource type that is supported).
2776 	 * creating it if it does
2777 	 * not exist. Will not return <code>null</code>.
2778 	 *
2779      * <p>
2780      * <b>Definition:</b>
2781      * A type of resource exposed via the restful interface
2782      * </p> 
2783 	 */
2784 	public BoundCodeDt<ResourceTypeEnum> getType() {  
2785 		if (myType == null) {
2786 			myType = new BoundCodeDt<ResourceTypeEnum>(ResourceTypeEnum.VALUESET_BINDER);
2787 		}
2788 		return myType;
2789 	}
2790 
2791 	/**
2792 	 * Sets the value(s) for <b>type</b> (A resource type that is supported)
2793 	 *
2794      * <p>
2795      * <b>Definition:</b>
2796      * A type of resource exposed via the restful interface
2797      * </p> 
2798 	 */
2799 	public RestResource setType(BoundCodeDt<ResourceTypeEnum> theValue) {
2800 		myType = theValue;
2801 		return this;
2802 	}
2803 
2804 	/**
2805 	 * Sets the value(s) for <b>type</b> (A resource type that is supported)
2806 	 *
2807      * <p>
2808      * <b>Definition:</b>
2809      * A type of resource exposed via the restful interface
2810      * </p> 
2811 	 */
2812 	public RestResource setType(ResourceTypeEnum theValue) {
2813 		getType().setValueAsEnum(theValue);
2814 		return this;
2815 	}
2816 
2817   
2818 	/**
2819 	 * Gets the value(s) for <b>profile</b> (What structural features are supported).
2820 	 * creating it if it does
2821 	 * not exist. Will not return <code>null</code>.
2822 	 *
2823      * <p>
2824      * <b>Definition:</b>
2825      * A specification of the profile that describes the solution's support for the resource, including any constraints on cardinality, bindings, lengths or other limitations
2826      * </p> 
2827 	 */
2828 	public ResourceReferenceDt getProfile() {  
2829 		if (myProfile == null) {
2830 			myProfile = new ResourceReferenceDt();
2831 		}
2832 		return myProfile;
2833 	}
2834 
2835 	/**
2836 	 * Sets the value(s) for <b>profile</b> (What structural features are supported)
2837 	 *
2838      * <p>
2839      * <b>Definition:</b>
2840      * A specification of the profile that describes the solution's support for the resource, including any constraints on cardinality, bindings, lengths or other limitations
2841      * </p> 
2842 	 */
2843 	public RestResource setProfile(ResourceReferenceDt theValue) {
2844 		myProfile = theValue;
2845 		return this;
2846 	}
2847 
2848   
2849 	/**
2850 	 * Gets the value(s) for <b>operation</b> (What operations are supported?).
2851 	 * creating it if it does
2852 	 * not exist. Will not return <code>null</code>.
2853 	 *
2854      * <p>
2855      * <b>Definition:</b>
2856      * Identifies a restful operation supported by the solution
2857      * </p> 
2858 	 */
2859 	public java.util.List<RestResourceOperation> getOperation() {  
2860 		if (myOperation == null) {
2861 			myOperation = new java.util.ArrayList<RestResourceOperation>();
2862 		}
2863 		return myOperation;
2864 	}
2865 
2866 	/**
2867 	 * Sets the value(s) for <b>operation</b> (What operations are supported?)
2868 	 *
2869      * <p>
2870      * <b>Definition:</b>
2871      * Identifies a restful operation supported by the solution
2872      * </p> 
2873 	 */
2874 	public RestResource setOperation(java.util.List<RestResourceOperation> theValue) {
2875 		myOperation = theValue;
2876 		return this;
2877 	}
2878 
2879 	/**
2880 	 * Adds and returns a new value for <b>operation</b> (What operations are supported?)
2881 	 *
2882      * <p>
2883      * <b>Definition:</b>
2884      * Identifies a restful operation supported by the solution
2885      * </p> 
2886 	 */
2887 	public RestResourceOperation addOperation() {
2888 		RestResourceOperation newType = new RestResourceOperation();
2889 		getOperation().add(newType);
2890 		return newType; 
2891 	}
2892 
2893 	/**
2894 	 * Gets the first repetition for <b>operation</b> (What operations are supported?),
2895 	 * creating it if it does not already exist.
2896 	 *
2897      * <p>
2898      * <b>Definition:</b>
2899      * Identifies a restful operation supported by the solution
2900      * </p> 
2901 	 */
2902 	public RestResourceOperation getOperationFirstRep() {
2903 		if (getOperation().isEmpty()) {
2904 			return addOperation();
2905 		}
2906 		return getOperation().get(0); 
2907 	}
2908   
2909 	/**
2910 	 * Gets the value(s) for <b>readHistory</b> (Whether vRead can return past versions).
2911 	 * creating it if it does
2912 	 * not exist. Will not return <code>null</code>.
2913 	 *
2914      * <p>
2915      * <b>Definition:</b>
2916      * A flag for whether the server is able to return past versions as part of the vRead operation
2917      * </p> 
2918 	 */
2919 	public BooleanDt getReadHistory() {  
2920 		if (myReadHistory == null) {
2921 			myReadHistory = new BooleanDt();
2922 		}
2923 		return myReadHistory;
2924 	}
2925 
2926 	/**
2927 	 * Sets the value(s) for <b>readHistory</b> (Whether vRead can return past versions)
2928 	 *
2929      * <p>
2930      * <b>Definition:</b>
2931      * A flag for whether the server is able to return past versions as part of the vRead operation
2932      * </p> 
2933 	 */
2934 	public RestResource setReadHistory(BooleanDt theValue) {
2935 		myReadHistory = theValue;
2936 		return this;
2937 	}
2938 
2939  	/**
2940 	 * Sets the value for <b>readHistory</b> (Whether vRead can return past versions)
2941 	 *
2942      * <p>
2943      * <b>Definition:</b>
2944      * A flag for whether the server is able to return past versions as part of the vRead operation
2945      * </p> 
2946 	 */
2947 	public RestResource setReadHistory( boolean theBoolean) {
2948 		myReadHistory = new BooleanDt(theBoolean); 
2949 		return this; 
2950 	}
2951 
2952  
2953 	/**
2954 	 * Gets the value(s) for <b>updateCreate</b> (If allows/uses update to a new location).
2955 	 * creating it if it does
2956 	 * not exist. Will not return <code>null</code>.
2957 	 *
2958      * <p>
2959      * <b>Definition:</b>
2960      * A flag to indicate that the server allows the client to create new identities on the server. If the update operation is used (client) or allowed (server) to a new location where a resource doesn't already exist. This means that the server allows the client to create new identities on the server
2961      * </p> 
2962 	 */
2963 	public BooleanDt getUpdateCreate() {  
2964 		if (myUpdateCreate == null) {
2965 			myUpdateCreate = new BooleanDt();
2966 		}
2967 		return myUpdateCreate;
2968 	}
2969 
2970 	/**
2971 	 * Sets the value(s) for <b>updateCreate</b> (If allows/uses update to a new location)
2972 	 *
2973      * <p>
2974      * <b>Definition:</b>
2975      * A flag to indicate that the server allows the client to create new identities on the server. If the update operation is used (client) or allowed (server) to a new location where a resource doesn't already exist. This means that the server allows the client to create new identities on the server
2976      * </p> 
2977 	 */
2978 	public RestResource setUpdateCreate(BooleanDt theValue) {
2979 		myUpdateCreate = theValue;
2980 		return this;
2981 	}
2982 
2983  	/**
2984 	 * Sets the value for <b>updateCreate</b> (If allows/uses update to a new location)
2985 	 *
2986      * <p>
2987      * <b>Definition:</b>
2988      * A flag to indicate that the server allows the client to create new identities on the server. If the update operation is used (client) or allowed (server) to a new location where a resource doesn't already exist. This means that the server allows the client to create new identities on the server
2989      * </p> 
2990 	 */
2991 	public RestResource setUpdateCreate( boolean theBoolean) {
2992 		myUpdateCreate = new BooleanDt(theBoolean); 
2993 		return this; 
2994 	}
2995 
2996  
2997 	/**
2998 	 * Gets the value(s) for <b>searchInclude</b> (_include values supported by the server).
2999 	 * creating it if it does
3000 	 * not exist. Will not return <code>null</code>.
3001 	 *
3002      * <p>
3003      * <b>Definition:</b>
3004      * A list of _include values supported by the server
3005      * </p> 
3006 	 */
3007 	public java.util.List<StringDt> getSearchInclude() {  
3008 		if (mySearchInclude == null) {
3009 			mySearchInclude = new java.util.ArrayList<StringDt>();
3010 		}
3011 		return mySearchInclude;
3012 	}
3013 
3014 	/**
3015 	 * Sets the value(s) for <b>searchInclude</b> (_include values supported by the server)
3016 	 *
3017      * <p>
3018      * <b>Definition:</b>
3019      * A list of _include values supported by the server
3020      * </p> 
3021 	 */
3022 	public RestResource setSearchInclude(java.util.List<StringDt> theValue) {
3023 		mySearchInclude = theValue;
3024 		return this;
3025 	}
3026 
3027 	/**
3028 	 * Adds and returns a new value for <b>searchInclude</b> (_include values supported by the server)
3029 	 *
3030      * <p>
3031      * <b>Definition:</b>
3032      * A list of _include values supported by the server
3033      * </p> 
3034 	 */
3035 	public StringDt addSearchInclude() {
3036 		StringDt newType = new StringDt();
3037 		getSearchInclude().add(newType);
3038 		return newType; 
3039 	}
3040 
3041 	/**
3042 	 * Gets the first repetition for <b>searchInclude</b> (_include values supported by the server),
3043 	 * creating it if it does not already exist.
3044 	 *
3045      * <p>
3046      * <b>Definition:</b>
3047      * A list of _include values supported by the server
3048      * </p> 
3049 	 */
3050 	public StringDt getSearchIncludeFirstRep() {
3051 		if (getSearchInclude().isEmpty()) {
3052 			return addSearchInclude();
3053 		}
3054 		return getSearchInclude().get(0); 
3055 	}
3056  	/**
3057 	 * Adds a new value for <b>searchInclude</b> (_include values supported by the server)
3058 	 *
3059      * <p>
3060      * <b>Definition:</b>
3061      * A list of _include values supported by the server
3062      * </p> 
3063      *
3064      * @return Returns a reference to this object, to allow for simple chaining.
3065 	 */
3066 	public RestResource addSearchInclude( String theString) {
3067 		if (mySearchInclude == null) {
3068 			mySearchInclude = new java.util.ArrayList<StringDt>();
3069 		}
3070 		mySearchInclude.add(new StringDt(theString));
3071 		return this; 
3072 	}
3073 
3074  
3075 	/**
3076 	 * Gets the value(s) for <b>searchParam</b> (Additional search params defined).
3077 	 * creating it if it does
3078 	 * not exist. Will not return <code>null</code>.
3079 	 *
3080      * <p>
3081      * <b>Definition:</b>
3082      * Additional search parameters for implementations to support and/or make use of
3083      * </p> 
3084 	 */
3085 	public java.util.List<RestResourceSearchParam> getSearchParam() {  
3086 		if (mySearchParam == null) {
3087 			mySearchParam = new java.util.ArrayList<RestResourceSearchParam>();
3088 		}
3089 		return mySearchParam;
3090 	}
3091 
3092 	/**
3093 	 * Sets the value(s) for <b>searchParam</b> (Additional search params defined)
3094 	 *
3095      * <p>
3096      * <b>Definition:</b>
3097      * Additional search parameters for implementations to support and/or make use of
3098      * </p> 
3099 	 */
3100 	public RestResource setSearchParam(java.util.List<RestResourceSearchParam> theValue) {
3101 		mySearchParam = theValue;
3102 		return this;
3103 	}
3104 
3105 	/**
3106 	 * Adds and returns a new value for <b>searchParam</b> (Additional search params defined)
3107 	 *
3108      * <p>
3109      * <b>Definition:</b>
3110      * Additional search parameters for implementations to support and/or make use of
3111      * </p> 
3112 	 */
3113 	public RestResourceSearchParam addSearchParam() {
3114 		RestResourceSearchParam newType = new RestResourceSearchParam();
3115 		getSearchParam().add(newType);
3116 		return newType; 
3117 	}
3118 
3119 	/**
3120 	 * Gets the first repetition for <b>searchParam</b> (Additional search params defined),
3121 	 * creating it if it does not already exist.
3122 	 *
3123      * <p>
3124      * <b>Definition:</b>
3125      * Additional search parameters for implementations to support and/or make use of
3126      * </p> 
3127 	 */
3128 	public RestResourceSearchParam getSearchParamFirstRep() {
3129 		if (getSearchParam().isEmpty()) {
3130 			return addSearchParam();
3131 		}
3132 		return getSearchParam().get(0); 
3133 	}
3134   
3135 
3136 	}
3137 
3138 	/**
3139 	 * Block class for child element: <b>Conformance.rest.resource.operation</b> (What operations are supported?)
3140 	 *
3141      * <p>
3142      * <b>Definition:</b>
3143      * Identifies a restful operation supported by the solution
3144      * </p> 
3145 	 */
3146 	@Block()	
3147 	public static class RestResourceOperation extends BaseIdentifiableElement implements IResourceBlock {
3148 	
3149 	@Child(name="code", type=CodeDt.class, order=0, min=1, max=1)	
3150 	@Description(
3151 		shortDefinition="read | vread | update | delete | history-instance | validate | history-type | create | search-type",
3152 		formalDefinition="Coded identifier of the operation, supported by the system resource"
3153 	)
3154 	private BoundCodeDt<RestfulOperationTypeEnum> myCode;
3155 	
3156 	@Child(name="documentation", type=StringDt.class, order=1, min=0, max=1)	
3157 	@Description(
3158 		shortDefinition="Anything special about operation behavior",
3159 		formalDefinition="Guidance specific to the implementation of this operation, such as 'delete is a logical delete' or 'updates are only allowed with version id' or 'creates permitted from pre-authorized certificates only'"
3160 	)
3161 	private StringDt myDocumentation;
3162 	
3163 
3164 	@Override
3165 	public boolean isEmpty() {
3166 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myCode,  myDocumentation);
3167 	}
3168 	
3169 	@Override
3170 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
3171 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myCode, myDocumentation);
3172 	}
3173 
3174 	/**
3175 	 * Gets the value(s) for <b>code</b> (read | vread | update | delete | history-instance | validate | history-type | create | search-type).
3176 	 * creating it if it does
3177 	 * not exist. Will not return <code>null</code>.
3178 	 *
3179      * <p>
3180      * <b>Definition:</b>
3181      * Coded identifier of the operation, supported by the system resource
3182      * </p> 
3183 	 */
3184 	public BoundCodeDt<RestfulOperationTypeEnum> getCode() {  
3185 		if (myCode == null) {
3186 			myCode = new BoundCodeDt<RestfulOperationTypeEnum>(RestfulOperationTypeEnum.VALUESET_BINDER);
3187 		}
3188 		return myCode;
3189 	}
3190 
3191 	/**
3192 	 * Sets the value(s) for <b>code</b> (read | vread | update | delete | history-instance | validate | history-type | create | search-type)
3193 	 *
3194      * <p>
3195      * <b>Definition:</b>
3196      * Coded identifier of the operation, supported by the system resource
3197      * </p> 
3198 	 */
3199 	public RestResourceOperation setCode(BoundCodeDt<RestfulOperationTypeEnum> theValue) {
3200 		myCode = theValue;
3201 		return this;
3202 	}
3203 
3204 	/**
3205 	 * Sets the value(s) for <b>code</b> (read | vread | update | delete | history-instance | validate | history-type | create | search-type)
3206 	 *
3207      * <p>
3208      * <b>Definition:</b>
3209      * Coded identifier of the operation, supported by the system resource
3210      * </p> 
3211 	 */
3212 	public RestResourceOperation setCode(RestfulOperationTypeEnum theValue) {
3213 		getCode().setValueAsEnum(theValue);
3214 		return this;
3215 	}
3216 
3217   
3218 	/**
3219 	 * Gets the value(s) for <b>documentation</b> (Anything special about operation behavior).
3220 	 * creating it if it does
3221 	 * not exist. Will not return <code>null</code>.
3222 	 *
3223      * <p>
3224      * <b>Definition:</b>
3225      * Guidance specific to the implementation of this operation, such as 'delete is a logical delete' or 'updates are only allowed with version id' or 'creates permitted from pre-authorized certificates only'
3226      * </p> 
3227 	 */
3228 	public StringDt getDocumentation() {  
3229 		if (myDocumentation == null) {
3230 			myDocumentation = new StringDt();
3231 		}
3232 		return myDocumentation;
3233 	}
3234 
3235 	/**
3236 	 * Sets the value(s) for <b>documentation</b> (Anything special about operation behavior)
3237 	 *
3238      * <p>
3239      * <b>Definition:</b>
3240      * Guidance specific to the implementation of this operation, such as 'delete is a logical delete' or 'updates are only allowed with version id' or 'creates permitted from pre-authorized certificates only'
3241      * </p> 
3242 	 */
3243 	public RestResourceOperation setDocumentation(StringDt theValue) {
3244 		myDocumentation = theValue;
3245 		return this;
3246 	}
3247 
3248  	/**
3249 	 * Sets the value for <b>documentation</b> (Anything special about operation behavior)
3250 	 *
3251      * <p>
3252      * <b>Definition:</b>
3253      * Guidance specific to the implementation of this operation, such as 'delete is a logical delete' or 'updates are only allowed with version id' or 'creates permitted from pre-authorized certificates only'
3254      * </p> 
3255 	 */
3256 	public RestResourceOperation setDocumentation( String theString) {
3257 		myDocumentation = new StringDt(theString); 
3258 		return this; 
3259 	}
3260 
3261  
3262 
3263 	}
3264 
3265 
3266 	/**
3267 	 * Block class for child element: <b>Conformance.rest.resource.searchParam</b> (Additional search params defined)
3268 	 *
3269      * <p>
3270      * <b>Definition:</b>
3271      * Additional search parameters for implementations to support and/or make use of
3272      * </p> 
3273 	 */
3274 	@Block()	
3275 	public static class RestResourceSearchParam extends BaseIdentifiableElement implements IResourceBlock {
3276 	
3277 	@Child(name="name", type=StringDt.class, order=0, min=1, max=1)	
3278 	@Description(
3279 		shortDefinition="Name of search parameter",
3280 		formalDefinition="The name of the search parameter used in the interface"
3281 	)
3282 	private StringDt myName;
3283 	
3284 	@Child(name="definition", type=UriDt.class, order=1, min=0, max=1)	
3285 	@Description(
3286 		shortDefinition="Source of definition for parameter",
3287 		formalDefinition="A formal reference to where this parameter was first defined, so that a client can be confident of the meaning of the search parameter"
3288 	)
3289 	private UriDt myDefinition;
3290 	
3291 	@Child(name="type", type=CodeDt.class, order=2, min=1, max=1)	
3292 	@Description(
3293 		shortDefinition="number | date | string | token | reference | composite | quantity",
3294 		formalDefinition="The type of value a search parameter refers to, and how the content is interpreted"
3295 	)
3296 	private BoundCodeDt<SearchParamTypeEnum> myType;
3297 	
3298 	@Child(name="documentation", type=StringDt.class, order=3, min=0, max=1)	
3299 	@Description(
3300 		shortDefinition="Server-specific usage",
3301 		formalDefinition="This allows documentation of any distinct behaviors about how the search parameter is used.  For example, text matching algorithms."
3302 	)
3303 	private StringDt myDocumentation;
3304 	
3305 	@Child(name="target", type=CodeDt.class, order=4, min=0, max=Child.MAX_UNLIMITED)	
3306 	@Description(
3307 		shortDefinition="Types of resource (if a resource reference)",
3308 		formalDefinition="Types of resource (if a resource is referenced)"
3309 	)
3310 	private java.util.List<BoundCodeDt<ResourceTypeEnum>> myTarget;
3311 	
3312 	@Child(name="chain", type=StringDt.class, order=5, min=0, max=Child.MAX_UNLIMITED)	
3313 	@Description(
3314 		shortDefinition="Chained names supported",
3315 		formalDefinition=""
3316 	)
3317 	private java.util.List<StringDt> myChain;
3318 	
3319 
3320 	@Override
3321 	public boolean isEmpty() {
3322 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myName,  myDefinition,  myType,  myDocumentation,  myTarget,  myChain);
3323 	}
3324 	
3325 	@Override
3326 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
3327 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myName, myDefinition, myType, myDocumentation, myTarget, myChain);
3328 	}
3329 
3330 	/**
3331 	 * Gets the value(s) for <b>name</b> (Name of search parameter).
3332 	 * creating it if it does
3333 	 * not exist. Will not return <code>null</code>.
3334 	 *
3335      * <p>
3336      * <b>Definition:</b>
3337      * The name of the search parameter used in the interface
3338      * </p> 
3339 	 */
3340 	public StringDt getName() {  
3341 		if (myName == null) {
3342 			myName = new StringDt();
3343 		}
3344 		return myName;
3345 	}
3346 
3347 	/**
3348 	 * Sets the value(s) for <b>name</b> (Name of search parameter)
3349 	 *
3350      * <p>
3351      * <b>Definition:</b>
3352      * The name of the search parameter used in the interface
3353      * </p> 
3354 	 */
3355 	public RestResourceSearchParam setName(StringDt theValue) {
3356 		myName = theValue;
3357 		return this;
3358 	}
3359 
3360  	/**
3361 	 * Sets the value for <b>name</b> (Name of search parameter)
3362 	 *
3363      * <p>
3364      * <b>Definition:</b>
3365      * The name of the search parameter used in the interface
3366      * </p> 
3367 	 */
3368 	public RestResourceSearchParam setName( String theString) {
3369 		myName = new StringDt(theString); 
3370 		return this; 
3371 	}
3372 
3373  
3374 	/**
3375 	 * Gets the value(s) for <b>definition</b> (Source of definition for parameter).
3376 	 * creating it if it does
3377 	 * not exist. Will not return <code>null</code>.
3378 	 *
3379      * <p>
3380      * <b>Definition:</b>
3381      * A formal reference to where this parameter was first defined, so that a client can be confident of the meaning of the search parameter
3382      * </p> 
3383 	 */
3384 	public UriDt getDefinition() {  
3385 		if (myDefinition == null) {
3386 			myDefinition = new UriDt();
3387 		}
3388 		return myDefinition;
3389 	}
3390 
3391 	/**
3392 	 * Sets the value(s) for <b>definition</b> (Source of definition for parameter)
3393 	 *
3394      * <p>
3395      * <b>Definition:</b>
3396      * A formal reference to where this parameter was first defined, so that a client can be confident of the meaning of the search parameter
3397      * </p> 
3398 	 */
3399 	public RestResourceSearchParam setDefinition(UriDt theValue) {
3400 		myDefinition = theValue;
3401 		return this;
3402 	}
3403 
3404  	/**
3405 	 * Sets the value for <b>definition</b> (Source of definition for parameter)
3406 	 *
3407      * <p>
3408      * <b>Definition:</b>
3409      * A formal reference to where this parameter was first defined, so that a client can be confident of the meaning of the search parameter
3410      * </p> 
3411 	 */
3412 	public RestResourceSearchParam setDefinition( String theUri) {
3413 		myDefinition = new UriDt(theUri); 
3414 		return this; 
3415 	}
3416 
3417  
3418 	/**
3419 	 * Gets the value(s) for <b>type</b> (number | date | string | token | reference | composite | quantity).
3420 	 * creating it if it does
3421 	 * not exist. Will not return <code>null</code>.
3422 	 *
3423      * <p>
3424      * <b>Definition:</b>
3425      * The type of value a search parameter refers to, and how the content is interpreted
3426      * </p> 
3427 	 */
3428 	public BoundCodeDt<SearchParamTypeEnum> getType() {  
3429 		if (myType == null) {
3430 			myType = new BoundCodeDt<SearchParamTypeEnum>(SearchParamTypeEnum.VALUESET_BINDER);
3431 		}
3432 		return myType;
3433 	}
3434 
3435 	/**
3436 	 * Sets the value(s) for <b>type</b> (number | date | string | token | reference | composite | quantity)
3437 	 *
3438      * <p>
3439      * <b>Definition:</b>
3440      * The type of value a search parameter refers to, and how the content is interpreted
3441      * </p> 
3442 	 */
3443 	public RestResourceSearchParam setType(BoundCodeDt<SearchParamTypeEnum> theValue) {
3444 		myType = theValue;
3445 		return this;
3446 	}
3447 
3448 	/**
3449 	 * Sets the value(s) for <b>type</b> (number | date | string | token | reference | composite | quantity)
3450 	 *
3451      * <p>
3452      * <b>Definition:</b>
3453      * The type of value a search parameter refers to, and how the content is interpreted
3454      * </p> 
3455 	 */
3456 	public RestResourceSearchParam setType(SearchParamTypeEnum theValue) {
3457 		getType().setValueAsEnum(theValue);
3458 		return this;
3459 	}
3460 
3461   
3462 	/**
3463 	 * Gets the value(s) for <b>documentation</b> (Server-specific usage).
3464 	 * creating it if it does
3465 	 * not exist. Will not return <code>null</code>.
3466 	 *
3467      * <p>
3468      * <b>Definition:</b>
3469      * This allows documentation of any distinct behaviors about how the search parameter is used.  For example, text matching algorithms.
3470      * </p> 
3471 	 */
3472 	public StringDt getDocumentation() {  
3473 		if (myDocumentation == null) {
3474 			myDocumentation = new StringDt();
3475 		}
3476 		return myDocumentation;
3477 	}
3478 
3479 	/**
3480 	 * Sets the value(s) for <b>documentation</b> (Server-specific usage)
3481 	 *
3482      * <p>
3483      * <b>Definition:</b>
3484      * This allows documentation of any distinct behaviors about how the search parameter is used.  For example, text matching algorithms.
3485      * </p> 
3486 	 */
3487 	public RestResourceSearchParam setDocumentation(StringDt theValue) {
3488 		myDocumentation = theValue;
3489 		return this;
3490 	}
3491 
3492  	/**
3493 	 * Sets the value for <b>documentation</b> (Server-specific usage)
3494 	 *
3495      * <p>
3496      * <b>Definition:</b>
3497      * This allows documentation of any distinct behaviors about how the search parameter is used.  For example, text matching algorithms.
3498      * </p> 
3499 	 */
3500 	public RestResourceSearchParam setDocumentation( String theString) {
3501 		myDocumentation = new StringDt(theString); 
3502 		return this; 
3503 	}
3504 
3505  
3506 	/**
3507 	 * Gets the value(s) for <b>target</b> (Types of resource (if a resource reference)).
3508 	 * creating it if it does
3509 	 * not exist. Will not return <code>null</code>.
3510 	 *
3511      * <p>
3512      * <b>Definition:</b>
3513      * Types of resource (if a resource is referenced)
3514      * </p> 
3515 	 */
3516 	public java.util.List<BoundCodeDt<ResourceTypeEnum>> getTarget() {  
3517 		if (myTarget == null) {
3518 			myTarget = new java.util.ArrayList<BoundCodeDt<ResourceTypeEnum>>();
3519 		}
3520 		return myTarget;
3521 	}
3522 
3523 	/**
3524 	 * Sets the value(s) for <b>target</b> (Types of resource (if a resource reference))
3525 	 *
3526      * <p>
3527      * <b>Definition:</b>
3528      * Types of resource (if a resource is referenced)
3529      * </p> 
3530 	 */
3531 	public RestResourceSearchParam setTarget(java.util.List<BoundCodeDt<ResourceTypeEnum>> theValue) {
3532 		myTarget = theValue;
3533 		return this;
3534 	}
3535 
3536 	/**
3537 	 * Add a value for <b>target</b> (Types of resource (if a resource reference)) using an enumerated type. This
3538 	 * is intended as a convenience method for situations where the FHIR defined ValueSets are mandatory
3539 	 * or contain the desirable codes. If you wish to use codes other than those which are built-in, 
3540 	 * you may also use the {@link #addType()} method.
3541 	 *
3542      * <p>
3543      * <b>Definition:</b>
3544      * Types of resource (if a resource is referenced)
3545      * </p> 
3546 	 */
3547 	public BoundCodeDt<ResourceTypeEnum> addTarget(ResourceTypeEnum theValue) {
3548 		BoundCodeDt<ResourceTypeEnum> retVal = new BoundCodeDt<ResourceTypeEnum>(ResourceTypeEnum.VALUESET_BINDER, theValue);
3549 		getTarget().add(retVal);
3550 		return retVal;
3551 	}
3552 
3553 	/**
3554 	 * Gets the first repetition for <b>target</b> (Types of resource (if a resource reference)),
3555 	 * creating it if it does not already exist.
3556 	 *
3557      * <p>
3558      * <b>Definition:</b>
3559      * Types of resource (if a resource is referenced)
3560      * </p> 
3561 	 */
3562 	public BoundCodeDt<ResourceTypeEnum> getTargetFirstRep() {
3563 		if (getTarget().size() == 0) {
3564 			addTarget();
3565 		}
3566 		return getTarget().get(0);
3567 	}
3568 
3569 	/**
3570 	 * Add a value for <b>target</b> (Types of resource (if a resource reference))
3571 	 *
3572      * <p>
3573      * <b>Definition:</b>
3574      * Types of resource (if a resource is referenced)
3575      * </p> 
3576 	 */
3577 	public BoundCodeDt<ResourceTypeEnum> addTarget() {
3578 		BoundCodeDt<ResourceTypeEnum> retVal = new BoundCodeDt<ResourceTypeEnum>(ResourceTypeEnum.VALUESET_BINDER);
3579 		getTarget().add(retVal);
3580 		return retVal;
3581 	}
3582 
3583 	/**
3584 	 * Sets the value(s), and clears any existing value(s) for <b>target</b> (Types of resource (if a resource reference))
3585 	 *
3586      * <p>
3587      * <b>Definition:</b>
3588      * Types of resource (if a resource is referenced)
3589      * </p> 
3590 	 */
3591 	public RestResourceSearchParam setTarget(ResourceTypeEnum theValue) {
3592 		getTarget().clear();
3593 		addTarget(theValue);
3594 		return this;
3595 	}
3596 
3597   
3598 	/**
3599 	 * Gets the value(s) for <b>chain</b> (Chained names supported).
3600 	 * creating it if it does
3601 	 * not exist. Will not return <code>null</code>.
3602 	 *
3603      * <p>
3604      * <b>Definition:</b>
3605      * 
3606      * </p> 
3607 	 */
3608 	public java.util.List<StringDt> getChain() {  
3609 		if (myChain == null) {
3610 			myChain = new java.util.ArrayList<StringDt>();
3611 		}
3612 		return myChain;
3613 	}
3614 
3615 	/**
3616 	 * Sets the value(s) for <b>chain</b> (Chained names supported)
3617 	 *
3618      * <p>
3619      * <b>Definition:</b>
3620      * 
3621      * </p> 
3622 	 */
3623 	public RestResourceSearchParam setChain(java.util.List<StringDt> theValue) {
3624 		myChain = theValue;
3625 		return this;
3626 	}
3627 
3628 	/**
3629 	 * Adds and returns a new value for <b>chain</b> (Chained names supported)
3630 	 *
3631      * <p>
3632      * <b>Definition:</b>
3633      * 
3634      * </p> 
3635 	 */
3636 	public StringDt addChain() {
3637 		StringDt newType = new StringDt();
3638 		getChain().add(newType);
3639 		return newType; 
3640 	}
3641 
3642 	/**
3643 	 * Gets the first repetition for <b>chain</b> (Chained names supported),
3644 	 * creating it if it does not already exist.
3645 	 *
3646      * <p>
3647      * <b>Definition:</b>
3648      * 
3649      * </p> 
3650 	 */
3651 	public StringDt getChainFirstRep() {
3652 		if (getChain().isEmpty()) {
3653 			return addChain();
3654 		}
3655 		return getChain().get(0); 
3656 	}
3657  	/**
3658 	 * Adds a new value for <b>chain</b> (Chained names supported)
3659 	 *
3660      * <p>
3661      * <b>Definition:</b>
3662      * 
3663      * </p> 
3664      *
3665      * @return Returns a reference to this object, to allow for simple chaining.
3666 	 */
3667 	public RestResourceSearchParam addChain( String theString) {
3668 		if (myChain == null) {
3669 			myChain = new java.util.ArrayList<StringDt>();
3670 		}
3671 		myChain.add(new StringDt(theString));
3672 		return this; 
3673 	}
3674 
3675  
3676 
3677 	}
3678 
3679 
3680 
3681 	/**
3682 	 * Block class for child element: <b>Conformance.rest.operation</b> (What operations are supported?)
3683 	 *
3684      * <p>
3685      * <b>Definition:</b>
3686      * A specification of restful operations supported by the system
3687      * </p> 
3688 	 */
3689 	@Block()	
3690 	public static class RestOperation extends BaseIdentifiableElement implements IResourceBlock {
3691 	
3692 	@Child(name="code", type=CodeDt.class, order=0, min=1, max=1)	
3693 	@Description(
3694 		shortDefinition="transaction | search-system | history-system",
3695 		formalDefinition="A coded identifier of the operation, supported by the system"
3696 	)
3697 	private BoundCodeDt<RestfulOperationSystemEnum> myCode;
3698 	
3699 	@Child(name="documentation", type=StringDt.class, order=1, min=0, max=1)	
3700 	@Description(
3701 		shortDefinition="Anything special about operation behavior",
3702 		formalDefinition="Guidance specific to the implementation of this operation, such as limitations on the kind of transactions allowed, or information about system wide search is implemented"
3703 	)
3704 	private StringDt myDocumentation;
3705 	
3706 
3707 	@Override
3708 	public boolean isEmpty() {
3709 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myCode,  myDocumentation);
3710 	}
3711 	
3712 	@Override
3713 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
3714 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myCode, myDocumentation);
3715 	}
3716 
3717 	/**
3718 	 * Gets the value(s) for <b>code</b> (transaction | search-system | history-system).
3719 	 * creating it if it does
3720 	 * not exist. Will not return <code>null</code>.
3721 	 *
3722      * <p>
3723      * <b>Definition:</b>
3724      * A coded identifier of the operation, supported by the system
3725      * </p> 
3726 	 */
3727 	public BoundCodeDt<RestfulOperationSystemEnum> getCode() {  
3728 		if (myCode == null) {
3729 			myCode = new BoundCodeDt<RestfulOperationSystemEnum>(RestfulOperationSystemEnum.VALUESET_BINDER);
3730 		}
3731 		return myCode;
3732 	}
3733 
3734 	/**
3735 	 * Sets the value(s) for <b>code</b> (transaction | search-system | history-system)
3736 	 *
3737      * <p>
3738      * <b>Definition:</b>
3739      * A coded identifier of the operation, supported by the system
3740      * </p> 
3741 	 */
3742 	public RestOperation setCode(BoundCodeDt<RestfulOperationSystemEnum> theValue) {
3743 		myCode = theValue;
3744 		return this;
3745 	}
3746 
3747 	/**
3748 	 * Sets the value(s) for <b>code</b> (transaction | search-system | history-system)
3749 	 *
3750      * <p>
3751      * <b>Definition:</b>
3752      * A coded identifier of the operation, supported by the system
3753      * </p> 
3754 	 */
3755 	public RestOperation setCode(RestfulOperationSystemEnum theValue) {
3756 		getCode().setValueAsEnum(theValue);
3757 		return this;
3758 	}
3759 
3760   
3761 	/**
3762 	 * Gets the value(s) for <b>documentation</b> (Anything special about operation behavior).
3763 	 * creating it if it does
3764 	 * not exist. Will not return <code>null</code>.
3765 	 *
3766      * <p>
3767      * <b>Definition:</b>
3768      * Guidance specific to the implementation of this operation, such as limitations on the kind of transactions allowed, or information about system wide search is implemented
3769      * </p> 
3770 	 */
3771 	public StringDt getDocumentation() {  
3772 		if (myDocumentation == null) {
3773 			myDocumentation = new StringDt();
3774 		}
3775 		return myDocumentation;
3776 	}
3777 
3778 	/**
3779 	 * Sets the value(s) for <b>documentation</b> (Anything special about operation behavior)
3780 	 *
3781      * <p>
3782      * <b>Definition:</b>
3783      * Guidance specific to the implementation of this operation, such as limitations on the kind of transactions allowed, or information about system wide search is implemented
3784      * </p> 
3785 	 */
3786 	public RestOperation setDocumentation(StringDt theValue) {
3787 		myDocumentation = theValue;
3788 		return this;
3789 	}
3790 
3791  	/**
3792 	 * Sets the value for <b>documentation</b> (Anything special about operation behavior)
3793 	 *
3794      * <p>
3795      * <b>Definition:</b>
3796      * Guidance specific to the implementation of this operation, such as limitations on the kind of transactions allowed, or information about system wide search is implemented
3797      * </p> 
3798 	 */
3799 	public RestOperation setDocumentation( String theString) {
3800 		myDocumentation = new StringDt(theString); 
3801 		return this; 
3802 	}
3803 
3804  
3805 
3806 	}
3807 
3808 
3809 	/**
3810 	 * Block class for child element: <b>Conformance.rest.query</b> (Definition of a named query)
3811 	 *
3812      * <p>
3813      * <b>Definition:</b>
3814      * Definition of a named query and its parameters and their meaning
3815      * </p> 
3816 	 */
3817 	@Block()	
3818 	public static class RestQuery extends BaseIdentifiableElement implements IResourceBlock {
3819 	
3820 	@Child(name="name", type=StringDt.class, order=0, min=1, max=1)	
3821 	@Description(
3822 		shortDefinition="Special named queries (_query=)",
3823 		formalDefinition="The name of a query, which is used in the _query parameter when the query is called"
3824 	)
3825 	private StringDt myName;
3826 	
3827 	@Child(name="definition", type=UriDt.class, order=1, min=1, max=1)	
3828 	@Description(
3829 		shortDefinition="Where query is defined",
3830 		formalDefinition="Identifies the custom query, defined either in FHIR core or another profile"
3831 	)
3832 	private UriDt myDefinition;
3833 	
3834 	@Child(name="documentation", type=StringDt.class, order=2, min=0, max=1)	
3835 	@Description(
3836 		shortDefinition="Additional usage guidance",
3837 		formalDefinition="Additional information about how the query functions in this particular implementation"
3838 	)
3839 	private StringDt myDocumentation;
3840 	
3841 	@Child(name="parameter", type=RestResourceSearchParam.class, order=3, min=0, max=Child.MAX_UNLIMITED)	
3842 	@Description(
3843 		shortDefinition="Parameter for the named query",
3844 		formalDefinition="Identifies which of the parameters for the named query are supported"
3845 	)
3846 	private java.util.List<RestResourceSearchParam> myParameter;
3847 	
3848 
3849 	@Override
3850 	public boolean isEmpty() {
3851 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myName,  myDefinition,  myDocumentation,  myParameter);
3852 	}
3853 	
3854 	@Override
3855 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
3856 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myName, myDefinition, myDocumentation, myParameter);
3857 	}
3858 
3859 	/**
3860 	 * Gets the value(s) for <b>name</b> (Special named queries (_query=)).
3861 	 * creating it if it does
3862 	 * not exist. Will not return <code>null</code>.
3863 	 *
3864      * <p>
3865      * <b>Definition:</b>
3866      * The name of a query, which is used in the _query parameter when the query is called
3867      * </p> 
3868 	 */
3869 	public StringDt getName() {  
3870 		if (myName == null) {
3871 			myName = new StringDt();
3872 		}
3873 		return myName;
3874 	}
3875 
3876 	/**
3877 	 * Sets the value(s) for <b>name</b> (Special named queries (_query=))
3878 	 *
3879      * <p>
3880      * <b>Definition:</b>
3881      * The name of a query, which is used in the _query parameter when the query is called
3882      * </p> 
3883 	 */
3884 	public RestQuery setName(StringDt theValue) {
3885 		myName = theValue;
3886 		return this;
3887 	}
3888 
3889  	/**
3890 	 * Sets the value for <b>name</b> (Special named queries (_query=))
3891 	 *
3892      * <p>
3893      * <b>Definition:</b>
3894      * The name of a query, which is used in the _query parameter when the query is called
3895      * </p> 
3896 	 */
3897 	public RestQuery setName( String theString) {
3898 		myName = new StringDt(theString); 
3899 		return this; 
3900 	}
3901 
3902  
3903 	/**
3904 	 * Gets the value(s) for <b>definition</b> (Where query is defined).
3905 	 * creating it if it does
3906 	 * not exist. Will not return <code>null</code>.
3907 	 *
3908      * <p>
3909      * <b>Definition:</b>
3910      * Identifies the custom query, defined either in FHIR core or another profile
3911      * </p> 
3912 	 */
3913 	public UriDt getDefinition() {  
3914 		if (myDefinition == null) {
3915 			myDefinition = new UriDt();
3916 		}
3917 		return myDefinition;
3918 	}
3919 
3920 	/**
3921 	 * Sets the value(s) for <b>definition</b> (Where query is defined)
3922 	 *
3923      * <p>
3924      * <b>Definition:</b>
3925      * Identifies the custom query, defined either in FHIR core or another profile
3926      * </p> 
3927 	 */
3928 	public RestQuery setDefinition(UriDt theValue) {
3929 		myDefinition = theValue;
3930 		return this;
3931 	}
3932 
3933  	/**
3934 	 * Sets the value for <b>definition</b> (Where query is defined)
3935 	 *
3936      * <p>
3937      * <b>Definition:</b>
3938      * Identifies the custom query, defined either in FHIR core or another profile
3939      * </p> 
3940 	 */
3941 	public RestQuery setDefinition( String theUri) {
3942 		myDefinition = new UriDt(theUri); 
3943 		return this; 
3944 	}
3945 
3946  
3947 	/**
3948 	 * Gets the value(s) for <b>documentation</b> (Additional usage guidance).
3949 	 * creating it if it does
3950 	 * not exist. Will not return <code>null</code>.
3951 	 *
3952      * <p>
3953      * <b>Definition:</b>
3954      * Additional information about how the query functions in this particular implementation
3955      * </p> 
3956 	 */
3957 	public StringDt getDocumentation() {  
3958 		if (myDocumentation == null) {
3959 			myDocumentation = new StringDt();
3960 		}
3961 		return myDocumentation;
3962 	}
3963 
3964 	/**
3965 	 * Sets the value(s) for <b>documentation</b> (Additional usage guidance)
3966 	 *
3967      * <p>
3968      * <b>Definition:</b>
3969      * Additional information about how the query functions in this particular implementation
3970      * </p> 
3971 	 */
3972 	public RestQuery setDocumentation(StringDt theValue) {
3973 		myDocumentation = theValue;
3974 		return this;
3975 	}
3976 
3977  	/**
3978 	 * Sets the value for <b>documentation</b> (Additional usage guidance)
3979 	 *
3980      * <p>
3981      * <b>Definition:</b>
3982      * Additional information about how the query functions in this particular implementation
3983      * </p> 
3984 	 */
3985 	public RestQuery setDocumentation( String theString) {
3986 		myDocumentation = new StringDt(theString); 
3987 		return this; 
3988 	}
3989 
3990  
3991 	/**
3992 	 * Gets the value(s) for <b>parameter</b> (Parameter for the named query).
3993 	 * creating it if it does
3994 	 * not exist. Will not return <code>null</code>.
3995 	 *
3996      * <p>
3997      * <b>Definition:</b>
3998      * Identifies which of the parameters for the named query are supported
3999      * </p> 
4000 	 */
4001 	public java.util.List<RestResourceSearchParam> getParameter() {  
4002 		if (myParameter == null) {
4003 			myParameter = new java.util.ArrayList<RestResourceSearchParam>();
4004 		}
4005 		return myParameter;
4006 	}
4007 
4008 	/**
4009 	 * Sets the value(s) for <b>parameter</b> (Parameter for the named query)
4010 	 *
4011      * <p>
4012      * <b>Definition:</b>
4013      * Identifies which of the parameters for the named query are supported
4014      * </p> 
4015 	 */
4016 	public RestQuery setParameter(java.util.List<RestResourceSearchParam> theValue) {
4017 		myParameter = theValue;
4018 		return this;
4019 	}
4020 
4021 	/**
4022 	 * Adds and returns a new value for <b>parameter</b> (Parameter for the named query)
4023 	 *
4024      * <p>
4025      * <b>Definition:</b>
4026      * Identifies which of the parameters for the named query are supported
4027      * </p> 
4028 	 */
4029 	public RestResourceSearchParam addParameter() {
4030 		RestResourceSearchParam newType = new RestResourceSearchParam();
4031 		getParameter().add(newType);
4032 		return newType; 
4033 	}
4034 
4035 	/**
4036 	 * Gets the first repetition for <b>parameter</b> (Parameter for the named query),
4037 	 * creating it if it does not already exist.
4038 	 *
4039      * <p>
4040      * <b>Definition:</b>
4041      * Identifies which of the parameters for the named query are supported
4042      * </p> 
4043 	 */
4044 	public RestResourceSearchParam getParameterFirstRep() {
4045 		if (getParameter().isEmpty()) {
4046 			return addParameter();
4047 		}
4048 		return getParameter().get(0); 
4049 	}
4050   
4051 
4052 	}
4053 
4054 
4055 
4056 	/**
4057 	 * Block class for child element: <b>Conformance.messaging</b> (If messaging is supported)
4058 	 *
4059      * <p>
4060      * <b>Definition:</b>
4061      * A description of the messaging capabilities of the solution
4062      * </p> 
4063 	 */
4064 	@Block()	
4065 	public static class Messaging extends BaseIdentifiableElement implements IResourceBlock {
4066 	
4067 	@Child(name="endpoint", type=UriDt.class, order=0, min=0, max=1)	
4068 	@Description(
4069 		shortDefinition="Actual endpoint being described",
4070 		formalDefinition="An address to which messages and/or replies are to be sent."
4071 	)
4072 	private UriDt myEndpoint;
4073 	
4074 	@Child(name="reliableCache", type=IntegerDt.class, order=1, min=0, max=1)	
4075 	@Description(
4076 		shortDefinition="Reliable Message Cache Length",
4077 		formalDefinition="Length if the receiver's reliable messaging cache (if a receiver) or how long the cache length on the receiver should be (if a sender)"
4078 	)
4079 	private IntegerDt myReliableCache;
4080 	
4081 	@Child(name="documentation", type=StringDt.class, order=2, min=0, max=1)	
4082 	@Description(
4083 		shortDefinition="Messaging interface behavior details",
4084 		formalDefinition="Documentation about the system's messaging capabilities for this endpoint not otherwise documented by the conformance statement.  For example, process for becoming an authorized messaging exchange partner."
4085 	)
4086 	private StringDt myDocumentation;
4087 	
4088 	@Child(name="event", order=3, min=1, max=Child.MAX_UNLIMITED)	
4089 	@Description(
4090 		shortDefinition="Declare support for this event",
4091 		formalDefinition="A description of the solution's support for an event at this end point."
4092 	)
4093 	private java.util.List<MessagingEvent> myEvent;
4094 	
4095 
4096 	@Override
4097 	public boolean isEmpty() {
4098 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myEndpoint,  myReliableCache,  myDocumentation,  myEvent);
4099 	}
4100 	
4101 	@Override
4102 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
4103 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myEndpoint, myReliableCache, myDocumentation, myEvent);
4104 	}
4105 
4106 	/**
4107 	 * Gets the value(s) for <b>endpoint</b> (Actual endpoint being described).
4108 	 * creating it if it does
4109 	 * not exist. Will not return <code>null</code>.
4110 	 *
4111      * <p>
4112      * <b>Definition:</b>
4113      * An address to which messages and/or replies are to be sent.
4114      * </p> 
4115 	 */
4116 	public UriDt getEndpoint() {  
4117 		if (myEndpoint == null) {
4118 			myEndpoint = new UriDt();
4119 		}
4120 		return myEndpoint;
4121 	}
4122 
4123 	/**
4124 	 * Sets the value(s) for <b>endpoint</b> (Actual endpoint being described)
4125 	 *
4126      * <p>
4127      * <b>Definition:</b>
4128      * An address to which messages and/or replies are to be sent.
4129      * </p> 
4130 	 */
4131 	public Messaging setEndpoint(UriDt theValue) {
4132 		myEndpoint = theValue;
4133 		return this;
4134 	}
4135 
4136  	/**
4137 	 * Sets the value for <b>endpoint</b> (Actual endpoint being described)
4138 	 *
4139      * <p>
4140      * <b>Definition:</b>
4141      * An address to which messages and/or replies are to be sent.
4142      * </p> 
4143 	 */
4144 	public Messaging setEndpoint( String theUri) {
4145 		myEndpoint = new UriDt(theUri); 
4146 		return this; 
4147 	}
4148 
4149  
4150 	/**
4151 	 * Gets the value(s) for <b>reliableCache</b> (Reliable Message Cache Length).
4152 	 * creating it if it does
4153 	 * not exist. Will not return <code>null</code>.
4154 	 *
4155      * <p>
4156      * <b>Definition:</b>
4157      * Length if the receiver's reliable messaging cache (if a receiver) or how long the cache length on the receiver should be (if a sender)
4158      * </p> 
4159 	 */
4160 	public IntegerDt getReliableCache() {  
4161 		if (myReliableCache == null) {
4162 			myReliableCache = new IntegerDt();
4163 		}
4164 		return myReliableCache;
4165 	}
4166 
4167 	/**
4168 	 * Sets the value(s) for <b>reliableCache</b> (Reliable Message Cache Length)
4169 	 *
4170      * <p>
4171      * <b>Definition:</b>
4172      * Length if the receiver's reliable messaging cache (if a receiver) or how long the cache length on the receiver should be (if a sender)
4173      * </p> 
4174 	 */
4175 	public Messaging setReliableCache(IntegerDt theValue) {
4176 		myReliableCache = theValue;
4177 		return this;
4178 	}
4179 
4180  	/**
4181 	 * Sets the value for <b>reliableCache</b> (Reliable Message Cache Length)
4182 	 *
4183      * <p>
4184      * <b>Definition:</b>
4185      * Length if the receiver's reliable messaging cache (if a receiver) or how long the cache length on the receiver should be (if a sender)
4186      * </p> 
4187 	 */
4188 	public Messaging setReliableCache( int theInteger) {
4189 		myReliableCache = new IntegerDt(theInteger); 
4190 		return this; 
4191 	}
4192 
4193  
4194 	/**
4195 	 * Gets the value(s) for <b>documentation</b> (Messaging interface behavior details).
4196 	 * creating it if it does
4197 	 * not exist. Will not return <code>null</code>.
4198 	 *
4199      * <p>
4200      * <b>Definition:</b>
4201      * Documentation about the system's messaging capabilities for this endpoint not otherwise documented by the conformance statement.  For example, process for becoming an authorized messaging exchange partner.
4202      * </p> 
4203 	 */
4204 	public StringDt getDocumentation() {  
4205 		if (myDocumentation == null) {
4206 			myDocumentation = new StringDt();
4207 		}
4208 		return myDocumentation;
4209 	}
4210 
4211 	/**
4212 	 * Sets the value(s) for <b>documentation</b> (Messaging interface behavior details)
4213 	 *
4214      * <p>
4215      * <b>Definition:</b>
4216      * Documentation about the system's messaging capabilities for this endpoint not otherwise documented by the conformance statement.  For example, process for becoming an authorized messaging exchange partner.
4217      * </p> 
4218 	 */
4219 	public Messaging setDocumentation(StringDt theValue) {
4220 		myDocumentation = theValue;
4221 		return this;
4222 	}
4223 
4224  	/**
4225 	 * Sets the value for <b>documentation</b> (Messaging interface behavior details)
4226 	 *
4227      * <p>
4228      * <b>Definition:</b>
4229      * Documentation about the system's messaging capabilities for this endpoint not otherwise documented by the conformance statement.  For example, process for becoming an authorized messaging exchange partner.
4230      * </p> 
4231 	 */
4232 	public Messaging setDocumentation( String theString) {
4233 		myDocumentation = new StringDt(theString); 
4234 		return this; 
4235 	}
4236 
4237  
4238 	/**
4239 	 * Gets the value(s) for <b>event</b> (Declare support for this event).
4240 	 * creating it if it does
4241 	 * not exist. Will not return <code>null</code>.
4242 	 *
4243      * <p>
4244      * <b>Definition:</b>
4245      * A description of the solution's support for an event at this end point.
4246      * </p> 
4247 	 */
4248 	public java.util.List<MessagingEvent> getEvent() {  
4249 		if (myEvent == null) {
4250 			myEvent = new java.util.ArrayList<MessagingEvent>();
4251 		}
4252 		return myEvent;
4253 	}
4254 
4255 	/**
4256 	 * Sets the value(s) for <b>event</b> (Declare support for this event)
4257 	 *
4258      * <p>
4259      * <b>Definition:</b>
4260      * A description of the solution's support for an event at this end point.
4261      * </p> 
4262 	 */
4263 	public Messaging setEvent(java.util.List<MessagingEvent> theValue) {
4264 		myEvent = theValue;
4265 		return this;
4266 	}
4267 
4268 	/**
4269 	 * Adds and returns a new value for <b>event</b> (Declare support for this event)
4270 	 *
4271      * <p>
4272      * <b>Definition:</b>
4273      * A description of the solution's support for an event at this end point.
4274      * </p> 
4275 	 */
4276 	public MessagingEvent addEvent() {
4277 		MessagingEvent newType = new MessagingEvent();
4278 		getEvent().add(newType);
4279 		return newType; 
4280 	}
4281 
4282 	/**
4283 	 * Gets the first repetition for <b>event</b> (Declare support for this event),
4284 	 * creating it if it does not already exist.
4285 	 *
4286      * <p>
4287      * <b>Definition:</b>
4288      * A description of the solution's support for an event at this end point.
4289      * </p> 
4290 	 */
4291 	public MessagingEvent getEventFirstRep() {
4292 		if (getEvent().isEmpty()) {
4293 			return addEvent();
4294 		}
4295 		return getEvent().get(0); 
4296 	}
4297   
4298 
4299 	}
4300 
4301 	/**
4302 	 * Block class for child element: <b>Conformance.messaging.event</b> (Declare support for this event)
4303 	 *
4304      * <p>
4305      * <b>Definition:</b>
4306      * A description of the solution's support for an event at this end point.
4307      * </p> 
4308 	 */
4309 	@Block()	
4310 	public static class MessagingEvent extends BaseIdentifiableElement implements IResourceBlock {
4311 	
4312 	@Child(name="code", type=CodingDt.class, order=0, min=1, max=1)	
4313 	@Description(
4314 		shortDefinition="Event type",
4315 		formalDefinition="A coded identifier of a supported messaging event"
4316 	)
4317 	private CodingDt myCode;
4318 	
4319 	@Child(name="category", type=CodeDt.class, order=1, min=0, max=1)	
4320 	@Description(
4321 		shortDefinition="Consequence | Currency | Notification",
4322 		formalDefinition="The impact of the content of the message"
4323 	)
4324 	private BoundCodeDt<MessageSignificanceCategoryEnum> myCategory;
4325 	
4326 	@Child(name="mode", type=CodeDt.class, order=2, min=1, max=1)	
4327 	@Description(
4328 		shortDefinition="sender | receiver",
4329 		formalDefinition="The mode of this event declaration - whether application is sender or receiver"
4330 	)
4331 	private BoundCodeDt<ConformanceEventModeEnum> myMode;
4332 	
4333 	@Child(name="protocol", type=CodingDt.class, order=3, min=0, max=Child.MAX_UNLIMITED)	
4334 	@Description(
4335 		shortDefinition="http | ftp | mllp +",
4336 		formalDefinition="A list of the messaging transport protocol(s) identifiers, supported by this endpoint"
4337 	)
4338 	private java.util.List<CodingDt> myProtocol;
4339 	
4340 	@Child(name="focus", type=CodeDt.class, order=4, min=1, max=1)	
4341 	@Description(
4342 		shortDefinition="Resource that's focus of message",
4343 		formalDefinition="A resource associated with the event.  This is the resource that defines the event."
4344 	)
4345 	private BoundCodeDt<ResourceTypeEnum> myFocus;
4346 	
4347 	@Child(name="request", order=5, min=1, max=1, type={
4348 		ca.uhn.fhir.model.dstu.resource.Profile.class	})
4349 	@Description(
4350 		shortDefinition="Profile that describes the request",
4351 		formalDefinition="Information about the request for this event"
4352 	)
4353 	private ResourceReferenceDt myRequest;
4354 	
4355 	@Child(name="response", order=6, min=1, max=1, type={
4356 		ca.uhn.fhir.model.dstu.resource.Profile.class	})
4357 	@Description(
4358 		shortDefinition="Profile that describes the response",
4359 		formalDefinition="Information about the response for this event"
4360 	)
4361 	private ResourceReferenceDt myResponse;
4362 	
4363 	@Child(name="documentation", type=StringDt.class, order=7, min=0, max=1)	
4364 	@Description(
4365 		shortDefinition="Endpoint-specific event documentation",
4366 		formalDefinition="Guidance on how this event is handled, such as internal system trigger points, business rules, etc."
4367 	)
4368 	private StringDt myDocumentation;
4369 	
4370 
4371 	@Override
4372 	public boolean isEmpty() {
4373 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myCode,  myCategory,  myMode,  myProtocol,  myFocus,  myRequest,  myResponse,  myDocumentation);
4374 	}
4375 	
4376 	@Override
4377 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
4378 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myCode, myCategory, myMode, myProtocol, myFocus, myRequest, myResponse, myDocumentation);
4379 	}
4380 
4381 	/**
4382 	 * Gets the value(s) for <b>code</b> (Event type).
4383 	 * creating it if it does
4384 	 * not exist. Will not return <code>null</code>.
4385 	 *
4386      * <p>
4387      * <b>Definition:</b>
4388      * A coded identifier of a supported messaging event
4389      * </p> 
4390 	 */
4391 	public CodingDt getCode() {  
4392 		if (myCode == null) {
4393 			myCode = new CodingDt();
4394 		}
4395 		return myCode;
4396 	}
4397 
4398 	/**
4399 	 * Sets the value(s) for <b>code</b> (Event type)
4400 	 *
4401      * <p>
4402      * <b>Definition:</b>
4403      * A coded identifier of a supported messaging event
4404      * </p> 
4405 	 */
4406 	public MessagingEvent setCode(CodingDt theValue) {
4407 		myCode = theValue;
4408 		return this;
4409 	}
4410 
4411   
4412 	/**
4413 	 * Gets the value(s) for <b>category</b> (Consequence | Currency | Notification).
4414 	 * creating it if it does
4415 	 * not exist. Will not return <code>null</code>.
4416 	 *
4417      * <p>
4418      * <b>Definition:</b>
4419      * The impact of the content of the message
4420      * </p> 
4421 	 */
4422 	public BoundCodeDt<MessageSignificanceCategoryEnum> getCategory() {  
4423 		if (myCategory == null) {
4424 			myCategory = new BoundCodeDt<MessageSignificanceCategoryEnum>(MessageSignificanceCategoryEnum.VALUESET_BINDER);
4425 		}
4426 		return myCategory;
4427 	}
4428 
4429 	/**
4430 	 * Sets the value(s) for <b>category</b> (Consequence | Currency | Notification)
4431 	 *
4432      * <p>
4433      * <b>Definition:</b>
4434      * The impact of the content of the message
4435      * </p> 
4436 	 */
4437 	public MessagingEvent setCategory(BoundCodeDt<MessageSignificanceCategoryEnum> theValue) {
4438 		myCategory = theValue;
4439 		return this;
4440 	}
4441 
4442 	/**
4443 	 * Sets the value(s) for <b>category</b> (Consequence | Currency | Notification)
4444 	 *
4445      * <p>
4446      * <b>Definition:</b>
4447      * The impact of the content of the message
4448      * </p> 
4449 	 */
4450 	public MessagingEvent setCategory(MessageSignificanceCategoryEnum theValue) {
4451 		getCategory().setValueAsEnum(theValue);
4452 		return this;
4453 	}
4454 
4455   
4456 	/**
4457 	 * Gets the value(s) for <b>mode</b> (sender | receiver).
4458 	 * creating it if it does
4459 	 * not exist. Will not return <code>null</code>.
4460 	 *
4461      * <p>
4462      * <b>Definition:</b>
4463      * The mode of this event declaration - whether application is sender or receiver
4464      * </p> 
4465 	 */
4466 	public BoundCodeDt<ConformanceEventModeEnum> getMode() {  
4467 		if (myMode == null) {
4468 			myMode = new BoundCodeDt<ConformanceEventModeEnum>(ConformanceEventModeEnum.VALUESET_BINDER);
4469 		}
4470 		return myMode;
4471 	}
4472 
4473 	/**
4474 	 * Sets the value(s) for <b>mode</b> (sender | receiver)
4475 	 *
4476      * <p>
4477      * <b>Definition:</b>
4478      * The mode of this event declaration - whether application is sender or receiver
4479      * </p> 
4480 	 */
4481 	public MessagingEvent setMode(BoundCodeDt<ConformanceEventModeEnum> theValue) {
4482 		myMode = theValue;
4483 		return this;
4484 	}
4485 
4486 	/**
4487 	 * Sets the value(s) for <b>mode</b> (sender | receiver)
4488 	 *
4489      * <p>
4490      * <b>Definition:</b>
4491      * The mode of this event declaration - whether application is sender or receiver
4492      * </p> 
4493 	 */
4494 	public MessagingEvent setMode(ConformanceEventModeEnum theValue) {
4495 		getMode().setValueAsEnum(theValue);
4496 		return this;
4497 	}
4498 
4499   
4500 	/**
4501 	 * Gets the value(s) for <b>protocol</b> (http | ftp | mllp +).
4502 	 * creating it if it does
4503 	 * not exist. Will not return <code>null</code>.
4504 	 *
4505      * <p>
4506      * <b>Definition:</b>
4507      * A list of the messaging transport protocol(s) identifiers, supported by this endpoint
4508      * </p> 
4509 	 */
4510 	public java.util.List<CodingDt> getProtocol() {  
4511 		if (myProtocol == null) {
4512 			myProtocol = new java.util.ArrayList<CodingDt>();
4513 		}
4514 		return myProtocol;
4515 	}
4516 
4517 	/**
4518 	 * Sets the value(s) for <b>protocol</b> (http | ftp | mllp +)
4519 	 *
4520      * <p>
4521      * <b>Definition:</b>
4522      * A list of the messaging transport protocol(s) identifiers, supported by this endpoint
4523      * </p> 
4524 	 */
4525 	public MessagingEvent setProtocol(java.util.List<CodingDt> theValue) {
4526 		myProtocol = theValue;
4527 		return this;
4528 	}
4529 
4530 	/**
4531 	 * Adds and returns a new value for <b>protocol</b> (http | ftp | mllp +)
4532 	 *
4533      * <p>
4534      * <b>Definition:</b>
4535      * A list of the messaging transport protocol(s) identifiers, supported by this endpoint
4536      * </p> 
4537 	 */
4538 	public CodingDt addProtocol() {
4539 		CodingDt newType = new CodingDt();
4540 		getProtocol().add(newType);
4541 		return newType; 
4542 	}
4543 
4544 	/**
4545 	 * Gets the first repetition for <b>protocol</b> (http | ftp | mllp +),
4546 	 * creating it if it does not already exist.
4547 	 *
4548      * <p>
4549      * <b>Definition:</b>
4550      * A list of the messaging transport protocol(s) identifiers, supported by this endpoint
4551      * </p> 
4552 	 */
4553 	public CodingDt getProtocolFirstRep() {
4554 		if (getProtocol().isEmpty()) {
4555 			return addProtocol();
4556 		}
4557 		return getProtocol().get(0); 
4558 	}
4559   
4560 	/**
4561 	 * Gets the value(s) for <b>focus</b> (Resource that's focus of message).
4562 	 * creating it if it does
4563 	 * not exist. Will not return <code>null</code>.
4564 	 *
4565      * <p>
4566      * <b>Definition:</b>
4567      * A resource associated with the event.  This is the resource that defines the event.
4568      * </p> 
4569 	 */
4570 	public BoundCodeDt<ResourceTypeEnum> getFocus() {  
4571 		if (myFocus == null) {
4572 			myFocus = new BoundCodeDt<ResourceTypeEnum>(ResourceTypeEnum.VALUESET_BINDER);
4573 		}
4574 		return myFocus;
4575 	}
4576 
4577 	/**
4578 	 * Sets the value(s) for <b>focus</b> (Resource that's focus of message)
4579 	 *
4580      * <p>
4581      * <b>Definition:</b>
4582      * A resource associated with the event.  This is the resource that defines the event.
4583      * </p> 
4584 	 */
4585 	public MessagingEvent setFocus(BoundCodeDt<ResourceTypeEnum> theValue) {
4586 		myFocus = theValue;
4587 		return this;
4588 	}
4589 
4590 	/**
4591 	 * Sets the value(s) for <b>focus</b> (Resource that's focus of message)
4592 	 *
4593      * <p>
4594      * <b>Definition:</b>
4595      * A resource associated with the event.  This is the resource that defines the event.
4596      * </p> 
4597 	 */
4598 	public MessagingEvent setFocus(ResourceTypeEnum theValue) {
4599 		getFocus().setValueAsEnum(theValue);
4600 		return this;
4601 	}
4602 
4603   
4604 	/**
4605 	 * Gets the value(s) for <b>request</b> (Profile that describes the request).
4606 	 * creating it if it does
4607 	 * not exist. Will not return <code>null</code>.
4608 	 *
4609      * <p>
4610      * <b>Definition:</b>
4611      * Information about the request for this event
4612      * </p> 
4613 	 */
4614 	public ResourceReferenceDt getRequest() {  
4615 		if (myRequest == null) {
4616 			myRequest = new ResourceReferenceDt();
4617 		}
4618 		return myRequest;
4619 	}
4620 
4621 	/**
4622 	 * Sets the value(s) for <b>request</b> (Profile that describes the request)
4623 	 *
4624      * <p>
4625      * <b>Definition:</b>
4626      * Information about the request for this event
4627      * </p> 
4628 	 */
4629 	public MessagingEvent setRequest(ResourceReferenceDt theValue) {
4630 		myRequest = theValue;
4631 		return this;
4632 	}
4633 
4634   
4635 	/**
4636 	 * Gets the value(s) for <b>response</b> (Profile that describes the response).
4637 	 * creating it if it does
4638 	 * not exist. Will not return <code>null</code>.
4639 	 *
4640      * <p>
4641      * <b>Definition:</b>
4642      * Information about the response for this event
4643      * </p> 
4644 	 */
4645 	public ResourceReferenceDt getResponse() {  
4646 		if (myResponse == null) {
4647 			myResponse = new ResourceReferenceDt();
4648 		}
4649 		return myResponse;
4650 	}
4651 
4652 	/**
4653 	 * Sets the value(s) for <b>response</b> (Profile that describes the response)
4654 	 *
4655      * <p>
4656      * <b>Definition:</b>
4657      * Information about the response for this event
4658      * </p> 
4659 	 */
4660 	public MessagingEvent setResponse(ResourceReferenceDt theValue) {
4661 		myResponse = theValue;
4662 		return this;
4663 	}
4664 
4665   
4666 	/**
4667 	 * Gets the value(s) for <b>documentation</b> (Endpoint-specific event documentation).
4668 	 * creating it if it does
4669 	 * not exist. Will not return <code>null</code>.
4670 	 *
4671      * <p>
4672      * <b>Definition:</b>
4673      * Guidance on how this event is handled, such as internal system trigger points, business rules, etc.
4674      * </p> 
4675 	 */
4676 	public StringDt getDocumentation() {  
4677 		if (myDocumentation == null) {
4678 			myDocumentation = new StringDt();
4679 		}
4680 		return myDocumentation;
4681 	}
4682 
4683 	/**
4684 	 * Sets the value(s) for <b>documentation</b> (Endpoint-specific event documentation)
4685 	 *
4686      * <p>
4687      * <b>Definition:</b>
4688      * Guidance on how this event is handled, such as internal system trigger points, business rules, etc.
4689      * </p> 
4690 	 */
4691 	public MessagingEvent setDocumentation(StringDt theValue) {
4692 		myDocumentation = theValue;
4693 		return this;
4694 	}
4695 
4696  	/**
4697 	 * Sets the value for <b>documentation</b> (Endpoint-specific event documentation)
4698 	 *
4699      * <p>
4700      * <b>Definition:</b>
4701      * Guidance on how this event is handled, such as internal system trigger points, business rules, etc.
4702      * </p> 
4703 	 */
4704 	public MessagingEvent setDocumentation( String theString) {
4705 		myDocumentation = new StringDt(theString); 
4706 		return this; 
4707 	}
4708 
4709  
4710 
4711 	}
4712 
4713 
4714 
4715 	/**
4716 	 * Block class for child element: <b>Conformance.document</b> (Document definition)
4717 	 *
4718      * <p>
4719      * <b>Definition:</b>
4720      * A document definition
4721      * </p> 
4722 	 */
4723 	@Block()	
4724 	public static class Document extends BaseIdentifiableElement implements IResourceBlock {
4725 	
4726 	@Child(name="mode", type=CodeDt.class, order=0, min=1, max=1)	
4727 	@Description(
4728 		shortDefinition="producer | consumer",
4729 		formalDefinition="Mode of this document declaration - whether application is producer or consumer"
4730 	)
4731 	private BoundCodeDt<DocumentModeEnum> myMode;
4732 	
4733 	@Child(name="documentation", type=StringDt.class, order=1, min=0, max=1)	
4734 	@Description(
4735 		shortDefinition="Description of document support",
4736 		formalDefinition="A description of how the application supports or uses the specified document profile.  For example, when are documents created, what action is taken with consumed documents, etc."
4737 	)
4738 	private StringDt myDocumentation;
4739 	
4740 	@Child(name="profile", order=2, min=1, max=1, type={
4741 		ca.uhn.fhir.model.dstu.resource.Profile.class	})
4742 	@Description(
4743 		shortDefinition="Constraint on a resource used in the document",
4744 		formalDefinition="A constraint on a resource used in the document"
4745 	)
4746 	private ResourceReferenceDt myProfile;
4747 	
4748 
4749 	@Override
4750 	public boolean isEmpty() {
4751 		return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myMode,  myDocumentation,  myProfile);
4752 	}
4753 	
4754 	@Override
4755 	public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
4756 		return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myMode, myDocumentation, myProfile);
4757 	}
4758 
4759 	/**
4760 	 * Gets the value(s) for <b>mode</b> (producer | consumer).
4761 	 * creating it if it does
4762 	 * not exist. Will not return <code>null</code>.
4763 	 *
4764      * <p>
4765      * <b>Definition:</b>
4766      * Mode of this document declaration - whether application is producer or consumer
4767      * </p> 
4768 	 */
4769 	public BoundCodeDt<DocumentModeEnum> getMode() {  
4770 		if (myMode == null) {
4771 			myMode = new BoundCodeDt<DocumentModeEnum>(DocumentModeEnum.VALUESET_BINDER);
4772 		}
4773 		return myMode;
4774 	}
4775 
4776 	/**
4777 	 * Sets the value(s) for <b>mode</b> (producer | consumer)
4778 	 *
4779      * <p>
4780      * <b>Definition:</b>
4781      * Mode of this document declaration - whether application is producer or consumer
4782      * </p> 
4783 	 */
4784 	public Document setMode(BoundCodeDt<DocumentModeEnum> theValue) {
4785 		myMode = theValue;
4786 		return this;
4787 	}
4788 
4789 	/**
4790 	 * Sets the value(s) for <b>mode</b> (producer | consumer)
4791 	 *
4792      * <p>
4793      * <b>Definition:</b>
4794      * Mode of this document declaration - whether application is producer or consumer
4795      * </p> 
4796 	 */
4797 	public Document setMode(DocumentModeEnum theValue) {
4798 		getMode().setValueAsEnum(theValue);
4799 		return this;
4800 	}
4801 
4802   
4803 	/**
4804 	 * Gets the value(s) for <b>documentation</b> (Description of document support).
4805 	 * creating it if it does
4806 	 * not exist. Will not return <code>null</code>.
4807 	 *
4808      * <p>
4809      * <b>Definition:</b>
4810      * A description of how the application supports or uses the specified document profile.  For example, when are documents created, what action is taken with consumed documents, etc.
4811      * </p> 
4812 	 */
4813 	public StringDt getDocumentation() {  
4814 		if (myDocumentation == null) {
4815 			myDocumentation = new StringDt();
4816 		}
4817 		return myDocumentation;
4818 	}
4819 
4820 	/**
4821 	 * Sets the value(s) for <b>documentation</b> (Description of document support)
4822 	 *
4823      * <p>
4824      * <b>Definition:</b>
4825      * A description of how the application supports or uses the specified document profile.  For example, when are documents created, what action is taken with consumed documents, etc.
4826      * </p> 
4827 	 */
4828 	public Document setDocumentation(StringDt theValue) {
4829 		myDocumentation = theValue;
4830 		return this;
4831 	}
4832 
4833  	/**
4834 	 * Sets the value for <b>documentation</b> (Description of document support)
4835 	 *
4836      * <p>
4837      * <b>Definition:</b>
4838      * A description of how the application supports or uses the specified document profile.  For example, when are documents created, what action is taken with consumed documents, etc.
4839      * </p> 
4840 	 */
4841 	public Document setDocumentation( String theString) {
4842 		myDocumentation = new StringDt(theString); 
4843 		return this; 
4844 	}
4845 
4846  
4847 	/**
4848 	 * Gets the value(s) for <b>profile</b> (Constraint on a resource used in the document).
4849 	 * creating it if it does
4850 	 * not exist. Will not return <code>null</code>.
4851 	 *
4852      * <p>
4853      * <b>Definition:</b>
4854      * A constraint on a resource used in the document
4855      * </p> 
4856 	 */
4857 	public ResourceReferenceDt getProfile() {  
4858 		if (myProfile == null) {
4859 			myProfile = new ResourceReferenceDt();
4860 		}
4861 		return myProfile;
4862 	}
4863 
4864 	/**
4865 	 * Sets the value(s) for <b>profile</b> (Constraint on a resource used in the document)
4866 	 *
4867      * <p>
4868      * <b>Definition:</b>
4869      * A constraint on a resource used in the document
4870      * </p> 
4871 	 */
4872 	public Document setProfile(ResourceReferenceDt theValue) {
4873 		myProfile = theValue;
4874 		return this;
4875 	}
4876 
4877   
4878 
4879 	}
4880 
4881 
4882 
4883 
4884 }