001
002
003
004
005
006
007
008
009
010
011
012
013
014
015
016
017package ca.uhn.fhir.model.dstu2.resource;
018
019import java.math.BigDecimal;
020import java.net.URI;
021import java.util.*;
022import ca.uhn.fhir.model.api.*;
023import ca.uhn.fhir.model.api.annotation.*;
024import ca.uhn.fhir.rest.gclient.*;
025
026import ca.uhn.fhir.model.dstu2.valueset.AccountStatusEnum;
027import ca.uhn.fhir.model.dstu2.valueset.ActionListEnum;
028import ca.uhn.fhir.model.dstu2.composite.AddressDt;
029import ca.uhn.fhir.model.dstu2.valueset.AdjudicationCodesEnum;
030import ca.uhn.fhir.model.dstu2.valueset.AdjudicationErrorCodesEnum;
031import ca.uhn.fhir.model.dstu2.valueset.AdjustmentReasonCodesEnum;
032import ca.uhn.fhir.model.dstu2.valueset.AdministrativeGenderEnum;
033import ca.uhn.fhir.model.dstu2.valueset.AdmitSourceEnum;
034import ca.uhn.fhir.model.dstu2.resource.AllergyIntolerance;
035import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceCategoryEnum;
036import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceCertaintyEnum;
037import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceCriticalityEnum;
038import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceSeverityEnum;
039import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceStatusEnum;
040import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceTypeEnum;
041import ca.uhn.fhir.model.dstu2.composite.AnnotationDt;
042import ca.uhn.fhir.model.dstu2.valueset.AnswerFormatEnum;
043import ca.uhn.fhir.model.dstu2.resource.Appointment;
044import ca.uhn.fhir.model.dstu2.valueset.AppointmentStatusEnum;
045import ca.uhn.fhir.model.dstu2.valueset.AssertionDirectionTypeEnum;
046import ca.uhn.fhir.model.dstu2.valueset.AssertionOperatorTypeEnum;
047import ca.uhn.fhir.model.dstu2.valueset.AssertionResponseTypesEnum;
048import ca.uhn.fhir.model.dstu2.composite.AttachmentDt;
049import ca.uhn.fhir.model.dstu2.valueset.AuditEventActionEnum;
050import ca.uhn.fhir.model.dstu2.valueset.AuditEventObjectLifecycleEnum;
051import ca.uhn.fhir.model.dstu2.valueset.AuditEventObjectRoleEnum;
052import ca.uhn.fhir.model.dstu2.valueset.AuditEventObjectTypeEnum;
053import ca.uhn.fhir.model.dstu2.valueset.AuditEventOutcomeEnum;
054import ca.uhn.fhir.model.dstu2.valueset.AuditEventParticipantNetworkTypeEnum;
055import ca.uhn.fhir.model.dstu2.valueset.AuditEventSourceTypeEnum;
056import ca.uhn.fhir.model.dstu2.valueset.BindingStrengthEnum;
057import ca.uhn.fhir.model.dstu2.resource.BodySite;
058import ca.uhn.fhir.model.dstu2.valueset.BundleTypeEnum;
059import ca.uhn.fhir.model.dstu2.resource.CarePlan;
060import ca.uhn.fhir.model.dstu2.valueset.CarePlanActivityStatusEnum;
061import ca.uhn.fhir.model.dstu2.valueset.CarePlanRelationshipEnum;
062import ca.uhn.fhir.model.dstu2.valueset.CarePlanStatusEnum;
063import ca.uhn.fhir.model.dstu2.resource.Claim;
064import ca.uhn.fhir.model.dstu2.resource.ClaimResponse;
065import ca.uhn.fhir.model.dstu2.valueset.ClaimTypeEnum;
066import ca.uhn.fhir.model.dstu2.resource.ClinicalImpression;
067import ca.uhn.fhir.model.dstu2.valueset.ClinicalImpressionStatusEnum;
068import ca.uhn.fhir.model.dstu2.composite.CodeableConceptDt;
069import ca.uhn.fhir.model.dstu2.composite.CodingDt;
070import ca.uhn.fhir.model.dstu2.resource.CommunicationRequest;
071import ca.uhn.fhir.model.dstu2.valueset.CommunicationRequestStatusEnum;
072import ca.uhn.fhir.model.dstu2.valueset.CommunicationStatusEnum;
073import ca.uhn.fhir.model.dstu2.resource.Composition;
074import ca.uhn.fhir.model.dstu2.valueset.CompositionAttestationModeEnum;
075import ca.uhn.fhir.model.dstu2.valueset.CompositionStatusEnum;
076import ca.uhn.fhir.model.dstu2.valueset.ConceptMapEquivalenceEnum;
077import ca.uhn.fhir.model.dstu2.resource.Condition;
078import ca.uhn.fhir.model.dstu2.valueset.ConditionCategoryCodesEnum;
079import ca.uhn.fhir.model.dstu2.valueset.ConditionClinicalStatusCodesEnum;
080import ca.uhn.fhir.model.dstu2.valueset.ConditionVerificationStatusEnum;
081import ca.uhn.fhir.model.dstu2.valueset.ConditionalDeleteStatusEnum;
082import ca.uhn.fhir.model.dstu2.resource.Conformance;
083import ca.uhn.fhir.model.dstu2.valueset.ConformanceEventModeEnum;
084import ca.uhn.fhir.model.dstu2.valueset.ConformanceResourceStatusEnum;
085import ca.uhn.fhir.model.dstu2.valueset.ConformanceStatementKindEnum;
086import ca.uhn.fhir.model.dstu2.composite.ContactPointDt;
087import ca.uhn.fhir.model.dstu2.valueset.ContentTypeEnum;
088import ca.uhn.fhir.model.dstu2.resource.Contract;
089import ca.uhn.fhir.model.dstu2.resource.Coverage;
090import ca.uhn.fhir.model.dstu2.valueset.DataElementStringencyEnum;
091import ca.uhn.fhir.model.dstu2.valueset.DaysOfWeekEnum;
092import ca.uhn.fhir.model.dstu2.valueset.DetectedIssueSeverityEnum;
093import ca.uhn.fhir.model.dstu2.resource.Device;
094import ca.uhn.fhir.model.dstu2.resource.DeviceComponent;
095import ca.uhn.fhir.model.dstu2.resource.DeviceMetric;
096import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricCalibrationStateEnum;
097import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricCalibrationTypeEnum;
098import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricCategoryEnum;
099import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricColorEnum;
100import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricOperationalStatusEnum;
101import ca.uhn.fhir.model.dstu2.valueset.DeviceStatusEnum;
102import ca.uhn.fhir.model.dstu2.resource.DeviceUseRequest;
103import ca.uhn.fhir.model.dstu2.valueset.DeviceUseRequestPriorityEnum;
104import ca.uhn.fhir.model.dstu2.valueset.DeviceUseRequestStatusEnum;
105import ca.uhn.fhir.model.dstu2.resource.DiagnosticOrder;
106import ca.uhn.fhir.model.dstu2.valueset.DiagnosticOrderPriorityEnum;
107import ca.uhn.fhir.model.dstu2.valueset.DiagnosticOrderStatusEnum;
108import ca.uhn.fhir.model.dstu2.resource.DiagnosticReport;
109import ca.uhn.fhir.model.dstu2.valueset.DiagnosticReportStatusEnum;
110import ca.uhn.fhir.model.dstu2.valueset.DigitalMediaTypeEnum;
111import ca.uhn.fhir.model.dstu2.valueset.DocumentModeEnum;
112import ca.uhn.fhir.model.dstu2.resource.DocumentReference;
113import ca.uhn.fhir.model.dstu2.valueset.DocumentReferenceStatusEnum;
114import ca.uhn.fhir.model.dstu2.valueset.DocumentRelationshipTypeEnum;
115import ca.uhn.fhir.model.dstu2.composite.ElementDefinitionDt;
116import ca.uhn.fhir.model.dstu2.resource.EligibilityRequest;
117import ca.uhn.fhir.model.dstu2.resource.Encounter;
118import ca.uhn.fhir.model.dstu2.valueset.EncounterClassEnum;
119import ca.uhn.fhir.model.dstu2.valueset.EncounterLocationStatusEnum;
120import ca.uhn.fhir.model.dstu2.valueset.EncounterStateEnum;
121import ca.uhn.fhir.model.dstu2.resource.EnrollmentRequest;
122import ca.uhn.fhir.model.dstu2.resource.EpisodeOfCare;
123import ca.uhn.fhir.model.dstu2.valueset.EpisodeOfCareStatusEnum;
124import ca.uhn.fhir.model.dstu2.valueset.ExtensionContextEnum;
125import ca.uhn.fhir.model.dstu2.valueset.FamilyHistoryStatusEnum;
126import ca.uhn.fhir.model.dstu2.resource.FamilyMemberHistory;
127import ca.uhn.fhir.model.dstu2.valueset.FilterOperatorEnum;
128import ca.uhn.fhir.model.dstu2.valueset.FlagStatusEnum;
129import ca.uhn.fhir.model.dstu2.resource.Goal;
130import ca.uhn.fhir.model.dstu2.valueset.GoalPriorityEnum;
131import ca.uhn.fhir.model.dstu2.valueset.GoalStatusEnum;
132import ca.uhn.fhir.model.dstu2.resource.Group;
133import ca.uhn.fhir.model.dstu2.valueset.GroupTypeEnum;
134import ca.uhn.fhir.model.dstu2.valueset.GuideDependencyTypeEnum;
135import ca.uhn.fhir.model.dstu2.valueset.GuidePageKindEnum;
136import ca.uhn.fhir.model.dstu2.valueset.GuideResourcePurposeEnum;
137import ca.uhn.fhir.model.dstu2.valueset.HTTPVerbEnum;
138import ca.uhn.fhir.model.dstu2.resource.HealthcareService;
139import ca.uhn.fhir.model.dstu2.composite.HumanNameDt;
140import ca.uhn.fhir.model.dstu2.composite.IdentifierDt;
141import ca.uhn.fhir.model.dstu2.valueset.IdentifierTypeCodesEnum;
142import ca.uhn.fhir.model.dstu2.valueset.IdentityAssuranceLevelEnum;
143import ca.uhn.fhir.model.dstu2.resource.ImagingObjectSelection;
144import ca.uhn.fhir.model.dstu2.resource.ImagingStudy;
145import ca.uhn.fhir.model.dstu2.resource.Immunization;
146import ca.uhn.fhir.model.dstu2.valueset.InstanceAvailabilityEnum;
147import ca.uhn.fhir.model.dstu2.valueset.IssueSeverityEnum;
148import ca.uhn.fhir.model.dstu2.valueset.IssueTypeEnum;
149import ca.uhn.fhir.model.dstu2.valueset.KOStitleEnum;
150import ca.uhn.fhir.model.dstu2.valueset.LinkTypeEnum;
151import ca.uhn.fhir.model.dstu2.valueset.ListModeEnum;
152import ca.uhn.fhir.model.dstu2.valueset.ListOrderCodesEnum;
153import ca.uhn.fhir.model.dstu2.valueset.ListStatusEnum;
154import ca.uhn.fhir.model.dstu2.resource.Location;
155import ca.uhn.fhir.model.dstu2.valueset.LocationModeEnum;
156import ca.uhn.fhir.model.dstu2.valueset.LocationStatusEnum;
157import ca.uhn.fhir.model.dstu2.valueset.LocationTypeEnum;
158import ca.uhn.fhir.model.dstu2.valueset.MaritalStatusCodesEnum;
159import ca.uhn.fhir.model.dstu2.valueset.MeasmntPrincipleEnum;
160import ca.uhn.fhir.model.dstu2.resource.Media;
161import ca.uhn.fhir.model.dstu2.resource.Medication;
162import ca.uhn.fhir.model.dstu2.valueset.MedicationAdministrationStatusEnum;
163import ca.uhn.fhir.model.dstu2.valueset.MedicationDispenseStatusEnum;
164import ca.uhn.fhir.model.dstu2.resource.MedicationOrder;
165import ca.uhn.fhir.model.dstu2.valueset.MedicationOrderStatusEnum;
166import ca.uhn.fhir.model.dstu2.resource.MedicationStatement;
167import ca.uhn.fhir.model.dstu2.valueset.MedicationStatementStatusEnum;
168import ca.uhn.fhir.model.dstu2.valueset.MessageEventEnum;
169import ca.uhn.fhir.model.dstu2.valueset.MessageSignificanceCategoryEnum;
170import ca.uhn.fhir.model.dstu2.valueset.MessageTransportEnum;
171import ca.uhn.fhir.model.dstu2.resource.NamingSystem;
172import ca.uhn.fhir.model.dstu2.valueset.NamingSystemIdentifierTypeEnum;
173import ca.uhn.fhir.model.dstu2.valueset.NamingSystemTypeEnum;
174import ca.uhn.fhir.model.dstu2.valueset.NoteTypeEnum;
175import ca.uhn.fhir.model.dstu2.resource.NutritionOrder;
176import ca.uhn.fhir.model.dstu2.valueset.NutritionOrderStatusEnum;
177import ca.uhn.fhir.model.dstu2.resource.Observation;
178import ca.uhn.fhir.model.dstu2.valueset.ObservationRelationshipTypeEnum;
179import ca.uhn.fhir.model.dstu2.valueset.ObservationStatusEnum;
180import ca.uhn.fhir.model.dstu2.resource.OperationDefinition;
181import ca.uhn.fhir.model.dstu2.valueset.OperationKindEnum;
182import ca.uhn.fhir.model.dstu2.resource.OperationOutcome;
183import ca.uhn.fhir.model.dstu2.valueset.OperationParameterUseEnum;
184import ca.uhn.fhir.model.dstu2.resource.Order;
185import ca.uhn.fhir.model.dstu2.valueset.OrderStatusEnum;
186import ca.uhn.fhir.model.dstu2.resource.Organization;
187import ca.uhn.fhir.model.dstu2.valueset.ParticipantRequiredEnum;
188import ca.uhn.fhir.model.dstu2.valueset.ParticipantStatusEnum;
189import ca.uhn.fhir.model.dstu2.valueset.ParticipantTypeEnum;
190import ca.uhn.fhir.model.dstu2.valueset.ParticipationStatusEnum;
191import ca.uhn.fhir.model.dstu2.resource.Patient;
192import ca.uhn.fhir.model.dstu2.valueset.PayeeTypeCodesEnum;
193import ca.uhn.fhir.model.dstu2.composite.PeriodDt;
194import ca.uhn.fhir.model.dstu2.resource.Person;
195import ca.uhn.fhir.model.dstu2.resource.Practitioner;
196import ca.uhn.fhir.model.dstu2.resource.Procedure;
197import ca.uhn.fhir.model.dstu2.resource.ProcedureRequest;
198import ca.uhn.fhir.model.dstu2.valueset.ProcedureRequestPriorityEnum;
199import ca.uhn.fhir.model.dstu2.valueset.ProcedureRequestStatusEnum;
200import ca.uhn.fhir.model.dstu2.valueset.ProcedureStatusEnum;
201import ca.uhn.fhir.model.dstu2.resource.ProcessRequest;
202import ca.uhn.fhir.model.dstu2.valueset.ProvenanceEntityRoleEnum;
203import ca.uhn.fhir.model.dstu2.composite.QuantityDt;
204import ca.uhn.fhir.model.dstu2.resource.Questionnaire;
205import ca.uhn.fhir.model.dstu2.resource.QuestionnaireResponse;
206import ca.uhn.fhir.model.dstu2.valueset.QuestionnaireResponseStatusEnum;
207import ca.uhn.fhir.model.dstu2.valueset.QuestionnaireStatusEnum;
208import ca.uhn.fhir.model.dstu2.composite.RangeDt;
209import ca.uhn.fhir.model.dstu2.composite.RatioDt;
210import ca.uhn.fhir.model.dstu2.valueset.ReferralMethodEnum;
211import ca.uhn.fhir.model.dstu2.resource.ReferralRequest;
212import ca.uhn.fhir.model.dstu2.valueset.ReferralStatusEnum;
213import ca.uhn.fhir.model.dstu2.resource.RelatedPerson;
214import ca.uhn.fhir.model.dstu2.valueset.RemittanceOutcomeEnum;
215import ca.uhn.fhir.model.dstu2.valueset.ResourceTypeEnum;
216import ca.uhn.fhir.model.dstu2.valueset.ResourceVersionPolicyEnum;
217import ca.uhn.fhir.model.dstu2.valueset.ResponseTypeEnum;
218import ca.uhn.fhir.model.dstu2.valueset.RestfulConformanceModeEnum;
219import ca.uhn.fhir.model.dstu2.valueset.RestfulSecurityServiceEnum;
220import ca.uhn.fhir.model.dstu2.resource.RiskAssessment;
221import ca.uhn.fhir.model.dstu2.valueset.RulesetCodesEnum;
222import ca.uhn.fhir.model.dstu2.composite.SampledDataDt;
223import ca.uhn.fhir.model.dstu2.resource.Schedule;
224import ca.uhn.fhir.model.dstu2.valueset.SearchEntryModeEnum;
225import ca.uhn.fhir.model.dstu2.valueset.SearchModifierCodeEnum;
226import ca.uhn.fhir.model.dstu2.valueset.SearchParamTypeEnum;
227import ca.uhn.fhir.model.dstu2.valueset.ServiceProvisionConditionsEnum;
228import ca.uhn.fhir.model.dstu2.composite.SignatureDt;
229import ca.uhn.fhir.model.dstu2.resource.Slot;
230import ca.uhn.fhir.model.dstu2.valueset.SlotStatusEnum;
231import ca.uhn.fhir.model.dstu2.resource.Specimen;
232import ca.uhn.fhir.model.dstu2.valueset.SpecimenStatusEnum;
233import ca.uhn.fhir.model.dstu2.resource.StructureDefinition;
234import ca.uhn.fhir.model.dstu2.valueset.StructureDefinitionKindEnum;
235import ca.uhn.fhir.model.dstu2.valueset.SubscriptionChannelTypeEnum;
236import ca.uhn.fhir.model.dstu2.valueset.SubscriptionStatusEnum;
237import ca.uhn.fhir.model.dstu2.resource.Substance;
238import ca.uhn.fhir.model.dstu2.valueset.SubstanceCategoryCodesEnum;
239import ca.uhn.fhir.model.dstu2.valueset.SupplyDeliveryStatusEnum;
240import ca.uhn.fhir.model.dstu2.resource.SupplyRequest;
241import ca.uhn.fhir.model.dstu2.valueset.SupplyRequestStatusEnum;
242import ca.uhn.fhir.model.dstu2.valueset.SystemRestfulInteractionEnum;
243import ca.uhn.fhir.model.api.TemporalPrecisionEnum;
244import ca.uhn.fhir.model.dstu2.composite.TimingDt;
245import ca.uhn.fhir.model.dstu2.valueset.TransactionModeEnum;
246import ca.uhn.fhir.model.dstu2.valueset.TypeRestfulInteractionEnum;
247import ca.uhn.fhir.model.dstu2.valueset.UnknownContentCodeEnum;
248import ca.uhn.fhir.model.dstu2.valueset.UseEnum;
249import ca.uhn.fhir.model.dstu2.resource.ValueSet;
250import ca.uhn.fhir.model.dstu2.valueset.VisionBaseEnum;
251import ca.uhn.fhir.model.dstu2.valueset.VisionEyesEnum;
252import ca.uhn.fhir.model.dstu2.resource.VisionPrescription;
253import ca.uhn.fhir.model.dstu2.valueset.XPathUsageTypeEnum;
254import ca.uhn.fhir.model.api.IResource;
255import ca.uhn.fhir.model.dstu2.composite.AgeDt;
256import ca.uhn.fhir.model.dstu2.composite.BoundCodeableConceptDt;
257import ca.uhn.fhir.model.dstu2.composite.DurationDt;
258import ca.uhn.fhir.model.dstu2.composite.MoneyDt;
259import ca.uhn.fhir.model.dstu2.composite.NarrativeDt;
260import ca.uhn.fhir.model.dstu2.composite.ResourceReferenceDt;
261import ca.uhn.fhir.model.dstu2.composite.SimpleQuantityDt;
262import ca.uhn.fhir.model.primitive.Base64BinaryDt;
263import ca.uhn.fhir.model.primitive.BooleanDt;
264import ca.uhn.fhir.model.primitive.BoundCodeDt;
265import ca.uhn.fhir.model.primitive.CodeDt;
266import ca.uhn.fhir.model.primitive.DateDt;
267import ca.uhn.fhir.model.primitive.DateTimeDt;
268import ca.uhn.fhir.model.primitive.DecimalDt;
269import ca.uhn.fhir.model.primitive.IdDt;
270import ca.uhn.fhir.model.primitive.InstantDt;
271import ca.uhn.fhir.model.primitive.IntegerDt;
272import ca.uhn.fhir.model.primitive.OidDt;
273import ca.uhn.fhir.model.primitive.PositiveIntDt;
274import ca.uhn.fhir.model.primitive.StringDt;
275import ca.uhn.fhir.model.primitive.TimeDt;
276import ca.uhn.fhir.model.primitive.UnsignedIntDt;
277import ca.uhn.fhir.model.primitive.UriDt;
278
279
280/**
281 * HAPI/FHIR <b>StructureDefinition</b> Resource
282 * (conformance.content)
283 *
284 * <p>
285 * <b>Definition:</b>
286 * A definition of a FHIR structure. This resource is used to describe the underlying resources, data types defined in FHIR, and also for describing extensions, and constraints on resources and data types.
287 * </p> 
288 *
289 * <p>
290 * <b>Requirements:</b>
291 * 
292 * </p> 
293 *
294 * <p>
295 * <b>Profile Definition:</b>
296 * <a href="http://hl7.org/fhir/profiles/StructureDefinition">http://hl7.org/fhir/profiles/StructureDefinition</a> 
297 * </p>
298 *
299 */
300@ResourceDef(name="StructureDefinition", profile="http://hl7.org/fhir/profiles/StructureDefinition", id="structuredefinition")
301public class StructureDefinition extends ca.uhn.fhir.model.dstu2.resource.BaseResource
302    implements  IResource     {
303
304        /**
305         * Search parameter constant for <b>url</b>
306         * <p>
307         * Description: <b></b><br>
308         * Type: <b>uri</b><br>
309         * Path: <b>StructureDefinition.url</b><br>
310         * </p>
311         */
312        @SearchParamDefinition(name="url", path="StructureDefinition.url", description="", type="uri"  )
313        public static final String SP_URL = "url";
314
315        /**
316         * <b>Fluent Client</b> search parameter constant for <b>url</b>
317         * <p>
318         * Description: <b></b><br>
319         * Type: <b>uri</b><br>
320         * Path: <b>StructureDefinition.url</b><br>
321         * </p>
322         */
323        public static final UriClientParam URL = new UriClientParam(SP_URL);
324
325        /**
326         * Search parameter constant for <b>identifier</b>
327         * <p>
328         * Description: <b>The identifier of the profile</b><br>
329         * Type: <b>token</b><br>
330         * Path: <b>StructureDefinition.identifier</b><br>
331         * </p>
332         */
333        @SearchParamDefinition(name="identifier", path="StructureDefinition.identifier", description="The identifier of the profile", type="token"  )
334        public static final String SP_IDENTIFIER = "identifier";
335
336        /**
337         * <b>Fluent Client</b> search parameter constant for <b>identifier</b>
338         * <p>
339         * Description: <b>The identifier of the profile</b><br>
340         * Type: <b>token</b><br>
341         * Path: <b>StructureDefinition.identifier</b><br>
342         * </p>
343         */
344        public static final TokenClientParam IDENTIFIER = new TokenClientParam(SP_IDENTIFIER);
345
346        /**
347         * Search parameter constant for <b>version</b>
348         * <p>
349         * Description: <b>The version identifier of the profile</b><br>
350         * Type: <b>token</b><br>
351         * Path: <b>StructureDefinition.version</b><br>
352         * </p>
353         */
354        @SearchParamDefinition(name="version", path="StructureDefinition.version", description="The version identifier of the profile", type="token"  )
355        public static final String SP_VERSION = "version";
356
357        /**
358         * <b>Fluent Client</b> search parameter constant for <b>version</b>
359         * <p>
360         * Description: <b>The version identifier of the profile</b><br>
361         * Type: <b>token</b><br>
362         * Path: <b>StructureDefinition.version</b><br>
363         * </p>
364         */
365        public static final TokenClientParam VERSION = new TokenClientParam(SP_VERSION);
366
367        /**
368         * Search parameter constant for <b>name</b>
369         * <p>
370         * Description: <b>Name of the profile</b><br>
371         * Type: <b>string</b><br>
372         * Path: <b>StructureDefinition.name</b><br>
373         * </p>
374         */
375        @SearchParamDefinition(name="name", path="StructureDefinition.name", description="Name of the profile", type="string"  )
376        public static final String SP_NAME = "name";
377
378        /**
379         * <b>Fluent Client</b> search parameter constant for <b>name</b>
380         * <p>
381         * Description: <b>Name of the profile</b><br>
382         * Type: <b>string</b><br>
383         * Path: <b>StructureDefinition.name</b><br>
384         * </p>
385         */
386        public static final StringClientParam NAME = new StringClientParam(SP_NAME);
387
388        /**
389         * Search parameter constant for <b>publisher</b>
390         * <p>
391         * Description: <b>Name of the publisher of the profile</b><br>
392         * Type: <b>string</b><br>
393         * Path: <b>StructureDefinition.publisher</b><br>
394         * </p>
395         */
396        @SearchParamDefinition(name="publisher", path="StructureDefinition.publisher", description="Name of the publisher of the profile", type="string"  )
397        public static final String SP_PUBLISHER = "publisher";
398
399        /**
400         * <b>Fluent Client</b> search parameter constant for <b>publisher</b>
401         * <p>
402         * Description: <b>Name of the publisher of the profile</b><br>
403         * Type: <b>string</b><br>
404         * Path: <b>StructureDefinition.publisher</b><br>
405         * </p>
406         */
407        public static final StringClientParam PUBLISHER = new StringClientParam(SP_PUBLISHER);
408
409        /**
410         * Search parameter constant for <b>description</b>
411         * <p>
412         * Description: <b>Text search in the description of the profile</b><br>
413         * Type: <b>string</b><br>
414         * Path: <b>StructureDefinition.description</b><br>
415         * </p>
416         */
417        @SearchParamDefinition(name="description", path="StructureDefinition.description", description="Text search in the description of the profile", type="string"  )
418        public static final String SP_DESCRIPTION = "description";
419
420        /**
421         * <b>Fluent Client</b> search parameter constant for <b>description</b>
422         * <p>
423         * Description: <b>Text search in the description of the profile</b><br>
424         * Type: <b>string</b><br>
425         * Path: <b>StructureDefinition.description</b><br>
426         * </p>
427         */
428        public static final StringClientParam DESCRIPTION = new StringClientParam(SP_DESCRIPTION);
429
430        /**
431         * Search parameter constant for <b>status</b>
432         * <p>
433         * Description: <b>The current status of the profile</b><br>
434         * Type: <b>token</b><br>
435         * Path: <b>StructureDefinition.status</b><br>
436         * </p>
437         */
438        @SearchParamDefinition(name="status", path="StructureDefinition.status", description="The current status of the profile", type="token"  )
439        public static final String SP_STATUS = "status";
440
441        /**
442         * <b>Fluent Client</b> search parameter constant for <b>status</b>
443         * <p>
444         * Description: <b>The current status of the profile</b><br>
445         * Type: <b>token</b><br>
446         * Path: <b>StructureDefinition.status</b><br>
447         * </p>
448         */
449        public static final TokenClientParam STATUS = new TokenClientParam(SP_STATUS);
450
451        /**
452         * Search parameter constant for <b>date</b>
453         * <p>
454         * Description: <b>The profile publication date</b><br>
455         * Type: <b>date</b><br>
456         * Path: <b>StructureDefinition.date</b><br>
457         * </p>
458         */
459        @SearchParamDefinition(name="date", path="StructureDefinition.date", description="The profile publication date", type="date"  )
460        public static final String SP_DATE = "date";
461
462        /**
463         * <b>Fluent Client</b> search parameter constant for <b>date</b>
464         * <p>
465         * Description: <b>The profile publication date</b><br>
466         * Type: <b>date</b><br>
467         * Path: <b>StructureDefinition.date</b><br>
468         * </p>
469         */
470        public static final DateClientParam DATE = new DateClientParam(SP_DATE);
471
472        /**
473         * Search parameter constant for <b>code</b>
474         * <p>
475         * Description: <b>A code for the profile</b><br>
476         * Type: <b>token</b><br>
477         * Path: <b>StructureDefinition.code</b><br>
478         * </p>
479         */
480        @SearchParamDefinition(name="code", path="StructureDefinition.code", description="A code for the profile", type="token"  )
481        public static final String SP_CODE = "code";
482
483        /**
484         * <b>Fluent Client</b> search parameter constant for <b>code</b>
485         * <p>
486         * Description: <b>A code for the profile</b><br>
487         * Type: <b>token</b><br>
488         * Path: <b>StructureDefinition.code</b><br>
489         * </p>
490         */
491        public static final TokenClientParam CODE = new TokenClientParam(SP_CODE);
492
493        /**
494         * Search parameter constant for <b>valueset</b>
495         * <p>
496         * Description: <b>A vocabulary binding reference</b><br>
497         * Type: <b>reference</b><br>
498         * Path: <b>StructureDefinition.snapshot.element.binding.valueSet[x]</b><br>
499         * </p>
500         */
501        @SearchParamDefinition(name="valueset", path="StructureDefinition.snapshot.element.binding.valueSet[x]", description="A vocabulary binding reference", type="reference"  )
502        public static final String SP_VALUESET = "valueset";
503
504        /**
505         * <b>Fluent Client</b> search parameter constant for <b>valueset</b>
506         * <p>
507         * Description: <b>A vocabulary binding reference</b><br>
508         * Type: <b>reference</b><br>
509         * Path: <b>StructureDefinition.snapshot.element.binding.valueSet[x]</b><br>
510         * </p>
511         */
512        public static final ReferenceClientParam VALUESET = new ReferenceClientParam(SP_VALUESET);
513
514        /**
515         * Search parameter constant for <b>type</b>
516         * <p>
517         * Description: <b></b><br>
518         * Type: <b>token</b><br>
519         * Path: <b>StructureDefinition.constrainedType</b><br>
520         * </p>
521         */
522        @SearchParamDefinition(name="type", path="StructureDefinition.constrainedType", description="", type="token"  )
523        public static final String SP_TYPE = "type";
524
525        /**
526         * <b>Fluent Client</b> search parameter constant for <b>type</b>
527         * <p>
528         * Description: <b></b><br>
529         * Type: <b>token</b><br>
530         * Path: <b>StructureDefinition.constrainedType</b><br>
531         * </p>
532         */
533        public static final TokenClientParam TYPE = new TokenClientParam(SP_TYPE);
534
535        /**
536         * Search parameter constant for <b>kind</b>
537         * <p>
538         * Description: <b></b><br>
539         * Type: <b>token</b><br>
540         * Path: <b>StructureDefinition.kind</b><br>
541         * </p>
542         */
543        @SearchParamDefinition(name="kind", path="StructureDefinition.kind", description="", type="token"  )
544        public static final String SP_KIND = "kind";
545
546        /**
547         * <b>Fluent Client</b> search parameter constant for <b>kind</b>
548         * <p>
549         * Description: <b></b><br>
550         * Type: <b>token</b><br>
551         * Path: <b>StructureDefinition.kind</b><br>
552         * </p>
553         */
554        public static final TokenClientParam KIND = new TokenClientParam(SP_KIND);
555
556        /**
557         * Search parameter constant for <b>path</b>
558         * <p>
559         * Description: <b>A path that is constrained in the profile</b><br>
560         * Type: <b>token</b><br>
561         * Path: <b>StructureDefinition.snapshot.element.path | StructureDefinition.differential.element.path </b><br>
562         * </p>
563         */
564        @SearchParamDefinition(name="path", path="StructureDefinition.snapshot.element.path | StructureDefinition.differential.element.path ", description="A path that is constrained in the profile", type="token"  )
565        public static final String SP_PATH = "path";
566
567        /**
568         * <b>Fluent Client</b> search parameter constant for <b>path</b>
569         * <p>
570         * Description: <b>A path that is constrained in the profile</b><br>
571         * Type: <b>token</b><br>
572         * Path: <b>StructureDefinition.snapshot.element.path | StructureDefinition.differential.element.path </b><br>
573         * </p>
574         */
575        public static final TokenClientParam PATH = new TokenClientParam(SP_PATH);
576
577        /**
578         * Search parameter constant for <b>context</b>
579         * <p>
580         * Description: <b>A use context assigned to the structure</b><br>
581         * Type: <b>token</b><br>
582         * Path: <b>StructureDefinition.useContext</b><br>
583         * </p>
584         */
585        @SearchParamDefinition(name="context", path="StructureDefinition.useContext", description="A use context assigned to the structure", type="token"  )
586        public static final String SP_CONTEXT = "context";
587
588        /**
589         * <b>Fluent Client</b> search parameter constant for <b>context</b>
590         * <p>
591         * Description: <b>A use context assigned to the structure</b><br>
592         * Type: <b>token</b><br>
593         * Path: <b>StructureDefinition.useContext</b><br>
594         * </p>
595         */
596        public static final TokenClientParam CONTEXT = new TokenClientParam(SP_CONTEXT);
597
598        /**
599         * Search parameter constant for <b>display</b>
600         * <p>
601         * Description: <b></b><br>
602         * Type: <b>string</b><br>
603         * Path: <b>StructureDefinition.display</b><br>
604         * </p>
605         */
606        @SearchParamDefinition(name="display", path="StructureDefinition.display", description="", type="string"  )
607        public static final String SP_DISPLAY = "display";
608
609        /**
610         * <b>Fluent Client</b> search parameter constant for <b>display</b>
611         * <p>
612         * Description: <b></b><br>
613         * Type: <b>string</b><br>
614         * Path: <b>StructureDefinition.display</b><br>
615         * </p>
616         */
617        public static final StringClientParam DISPLAY = new StringClientParam(SP_DISPLAY);
618
619        /**
620         * Search parameter constant for <b>experimental</b>
621         * <p>
622         * Description: <b></b><br>
623         * Type: <b>token</b><br>
624         * Path: <b>StructureDefinition.experimental</b><br>
625         * </p>
626         */
627        @SearchParamDefinition(name="experimental", path="StructureDefinition.experimental", description="", type="token"  )
628        public static final String SP_EXPERIMENTAL = "experimental";
629
630        /**
631         * <b>Fluent Client</b> search parameter constant for <b>experimental</b>
632         * <p>
633         * Description: <b></b><br>
634         * Type: <b>token</b><br>
635         * Path: <b>StructureDefinition.experimental</b><br>
636         * </p>
637         */
638        public static final TokenClientParam EXPERIMENTAL = new TokenClientParam(SP_EXPERIMENTAL);
639
640        /**
641         * Search parameter constant for <b>abstract</b>
642         * <p>
643         * Description: <b></b><br>
644         * Type: <b>token</b><br>
645         * Path: <b>StructureDefinition.abstract</b><br>
646         * </p>
647         */
648        @SearchParamDefinition(name="abstract", path="StructureDefinition.abstract", description="", type="token"  )
649        public static final String SP_ABSTRACT = "abstract";
650
651        /**
652         * <b>Fluent Client</b> search parameter constant for <b>abstract</b>
653         * <p>
654         * Description: <b></b><br>
655         * Type: <b>token</b><br>
656         * Path: <b>StructureDefinition.abstract</b><br>
657         * </p>
658         */
659        public static final TokenClientParam ABSTRACT = new TokenClientParam(SP_ABSTRACT);
660
661        /**
662         * Search parameter constant for <b>context-type</b>
663         * <p>
664         * Description: <b></b><br>
665         * Type: <b>token</b><br>
666         * Path: <b>StructureDefinition.contextType</b><br>
667         * </p>
668         */
669        @SearchParamDefinition(name="context-type", path="StructureDefinition.contextType", description="", type="token"  )
670        public static final String SP_CONTEXT_TYPE = "context-type";
671
672        /**
673         * <b>Fluent Client</b> search parameter constant for <b>context-type</b>
674         * <p>
675         * Description: <b></b><br>
676         * Type: <b>token</b><br>
677         * Path: <b>StructureDefinition.contextType</b><br>
678         * </p>
679         */
680        public static final TokenClientParam CONTEXT_TYPE = new TokenClientParam(SP_CONTEXT_TYPE);
681
682        /**
683         * Search parameter constant for <b>ext-context</b>
684         * <p>
685         * Description: <b></b><br>
686         * Type: <b>string</b><br>
687         * Path: <b>StructureDefinition.context</b><br>
688         * </p>
689         */
690        @SearchParamDefinition(name="ext-context", path="StructureDefinition.context", description="", type="string"  )
691        public static final String SP_EXT_CONTEXT = "ext-context";
692
693        /**
694         * <b>Fluent Client</b> search parameter constant for <b>ext-context</b>
695         * <p>
696         * Description: <b></b><br>
697         * Type: <b>string</b><br>
698         * Path: <b>StructureDefinition.context</b><br>
699         * </p>
700         */
701        public static final StringClientParam EXT_CONTEXT = new StringClientParam(SP_EXT_CONTEXT);
702
703        /**
704         * Search parameter constant for <b>base</b>
705         * <p>
706         * Description: <b></b><br>
707         * Type: <b>uri</b><br>
708         * Path: <b>StructureDefinition.base</b><br>
709         * </p>
710         */
711        @SearchParamDefinition(name="base", path="StructureDefinition.base", description="", type="uri"  )
712        public static final String SP_BASE = "base";
713
714        /**
715         * <b>Fluent Client</b> search parameter constant for <b>base</b>
716         * <p>
717         * Description: <b></b><br>
718         * Type: <b>uri</b><br>
719         * Path: <b>StructureDefinition.base</b><br>
720         * </p>
721         */
722        public static final UriClientParam BASE = new UriClientParam(SP_BASE);
723
724        /**
725         * Search parameter constant for <b>base-path</b>
726         * <p>
727         * Description: <b></b><br>
728         * Type: <b>token</b><br>
729         * Path: <b>StructureDefinition.snapshot.element.base.path | StructureDefinition.differential.element.base.path </b><br>
730         * </p>
731         */
732        @SearchParamDefinition(name="base-path", path="StructureDefinition.snapshot.element.base.path | StructureDefinition.differential.element.base.path ", description="", type="token"  )
733        public static final String SP_BASE_PATH = "base-path";
734
735        /**
736         * <b>Fluent Client</b> search parameter constant for <b>base-path</b>
737         * <p>
738         * Description: <b></b><br>
739         * Type: <b>token</b><br>
740         * Path: <b>StructureDefinition.snapshot.element.base.path | StructureDefinition.differential.element.base.path </b><br>
741         * </p>
742         */
743        public static final TokenClientParam BASE_PATH = new TokenClientParam(SP_BASE_PATH);
744
745
746        /**
747         * Constant for fluent queries to be used to add include statements. Specifies
748         * the path value of "<b>StructureDefinition:valueset</b>".
749         */
750        public static final Include INCLUDE_VALUESET = new Include("StructureDefinition:valueset");
751
752
753        @Child(name="url", type=UriDt.class, order=0, min=1, max=1, summary=true, modifier=false)       
754        @Description(
755                shortDefinition="id",
756                formalDefinition="An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published"
757        )
758        private UriDt myUrl;
759        
760        @Child(name="identifier", type=IdentifierDt.class, order=1, min=0, max=Child.MAX_UNLIMITED, summary=true, modifier=false)       
761        @Description(
762                shortDefinition="id",
763                formalDefinition="Formal identifier that is used to identify this StructureDefinition when it is represented in other formats, or referenced in a specification, model, design or an instance  (should be globally unique OID, UUID, or URI), (if it's not possible to use the literal URI)"
764        )
765        private java.util.List<IdentifierDt> myIdentifier;
766        
767        @Child(name="version", type=StringDt.class, order=2, min=0, max=1, summary=true, modifier=false)        
768        @Description(
769                shortDefinition="id.version",
770                formalDefinition="The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually"
771        )
772        private StringDt myVersion;
773        
774        @Child(name="name", type=StringDt.class, order=3, min=1, max=1, summary=true, modifier=false)   
775        @Description(
776                shortDefinition="",
777                formalDefinition="A free text natural language name identifying the StructureDefinition"
778        )
779        private StringDt myName;
780        
781        @Child(name="display", type=StringDt.class, order=4, min=0, max=1, summary=true, modifier=false)        
782        @Description(
783                shortDefinition="",
784                formalDefinition="Defined so that applications can use this name when displaying the value of the extension to the user"
785        )
786        private StringDt myDisplay;
787        
788        @Child(name="status", type=CodeDt.class, order=5, min=1, max=1, summary=true, modifier=false)   
789        @Description(
790                shortDefinition="status",
791                formalDefinition="The status of the StructureDefinition"
792        )
793        @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/conformance-resource-status")
794        private BoundCodeDt<ConformanceResourceStatusEnum> myStatus;
795        
796        @Child(name="experimental", type=BooleanDt.class, order=6, min=0, max=1, summary=true, modifier=false)  
797        @Description(
798                shortDefinition="class",
799                formalDefinition="This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage"
800        )
801        private BooleanDt myExperimental;
802        
803        @Child(name="publisher", type=StringDt.class, order=7, min=0, max=1, summary=true, modifier=false)      
804        @Description(
805                shortDefinition="who.witness",
806                formalDefinition="The name of the individual or organization that published the structure definition"
807        )
808        private StringDt myPublisher;
809        
810        @Child(name="contact", order=8, min=0, max=Child.MAX_UNLIMITED, summary=true, modifier=false)   
811        @Description(
812                shortDefinition="",
813                formalDefinition="Contacts to assist a user in finding and communicating with the publisher"
814        )
815        private java.util.List<Contact> myContact;
816        
817        @Child(name="date", type=DateTimeDt.class, order=9, min=0, max=1, summary=true, modifier=false) 
818        @Description(
819                shortDefinition="when.recorded",
820                formalDefinition="The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes"
821        )
822        private DateTimeDt myDate;
823        
824        @Child(name="description", type=StringDt.class, order=10, min=0, max=1, summary=true, modifier=false)   
825        @Description(
826                shortDefinition="",
827                formalDefinition="A free text natural language description of the StructureDefinition and its use"
828        )
829        private StringDt myDescription;
830        
831        @Child(name="useContext", type=CodeableConceptDt.class, order=11, min=0, max=Child.MAX_UNLIMITED, summary=true, modifier=false) 
832        @Description(
833                shortDefinition="",
834                formalDefinition="The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of structure definitions."
835        )
836        private java.util.List<CodeableConceptDt> myUseContext;
837        
838        @Child(name="requirements", type=StringDt.class, order=12, min=0, max=1, summary=false, modifier=false) 
839        @Description(
840                shortDefinition="why",
841                formalDefinition="Explains why this structure definition is needed and why it's been constrained as it has"
842        )
843        private StringDt myRequirements;
844        
845        @Child(name="copyright", type=StringDt.class, order=13, min=0, max=1, summary=false, modifier=false)    
846        @Description(
847                shortDefinition="",
848                formalDefinition="A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings"
849        )
850        private StringDt myCopyright;
851        
852        @Child(name="code", type=CodingDt.class, order=14, min=0, max=Child.MAX_UNLIMITED, summary=true, modifier=false)        
853        @Description(
854                shortDefinition="",
855                formalDefinition="A set of terms from external terminologies that may be used to assist with indexing and searching of templates."
856        )
857        private java.util.List<CodingDt> myCode;
858        
859        @Child(name="fhirVersion", type=IdDt.class, order=15, min=0, max=1, summary=true, modifier=false)       
860        @Description(
861                shortDefinition="",
862                formalDefinition="The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is $version$ for this version"
863        )
864        private IdDt myFhirVersion;
865        
866        @Child(name="mapping", order=16, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false) 
867        @Description(
868                shortDefinition="",
869                formalDefinition="An external specification that the content is mapped to"
870        )
871        private java.util.List<Mapping> myMapping;
872        
873        @Child(name="kind", type=CodeDt.class, order=17, min=1, max=1, summary=true, modifier=false)    
874        @Description(
875                shortDefinition="",
876                formalDefinition="Defines the kind of structure that this definition is describing"
877        )
878        @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/structure-definition-kind")
879        private BoundCodeDt<StructureDefinitionKindEnum> myKind;
880        
881        @Child(name="constrainedType", type=CodeDt.class, order=18, min=0, max=1, summary=true, modifier=false) 
882        @Description(
883                shortDefinition="",
884                formalDefinition="The type of type that is being constrained - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is a constraint. If it is not present, then the structure definition is the definition of a base structure"
885        )
886        @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/defined-types")
887        private CodeDt myConstrainedType;
888        
889        @Child(name="abstract", type=BooleanDt.class, order=19, min=1, max=1, summary=true, modifier=false)     
890        @Description(
891                shortDefinition="",
892                formalDefinition="Whether structure this definition describes is abstract or not  - that is, whether an actual exchanged item can ever be of this type"
893        )
894        private BooleanDt myAbstract;
895        
896        @Child(name="contextType", type=CodeDt.class, order=20, min=0, max=1, summary=true, modifier=false)     
897        @Description(
898                shortDefinition="",
899                formalDefinition="If this is an extension, Identifies the context within FHIR resources where the extension can be used"
900        )
901        @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/extension-context")
902        private BoundCodeDt<ExtensionContextEnum> myContextType;
903        
904        @Child(name="context", type=StringDt.class, order=21, min=0, max=Child.MAX_UNLIMITED, summary=true, modifier=false)     
905        @Description(
906                shortDefinition="",
907                formalDefinition="Identifies the types of resource or data type elements to which the extension can be applied"
908        )
909        private java.util.List<StringDt> myContext;
910        
911        @Child(name="base", type=UriDt.class, order=22, min=0, max=1, summary=true, modifier=false)     
912        @Description(
913                shortDefinition="",
914                formalDefinition="An absolute URI that is the base structure from which this set of constraints is derived"
915        )
916        private UriDt myBase;
917        
918        @Child(name="snapshot", order=23, min=0, max=1, summary=false, modifier=false)  
919        @Description(
920                shortDefinition="",
921                formalDefinition="A snapshot view is expressed in a stand alone form that can be used and interpreted without considering the base StructureDefinition"
922        )
923        private Snapshot mySnapshot;
924        
925        @Child(name="differential", order=24, min=0, max=1, summary=false, modifier=false)      
926        @Description(
927                shortDefinition="",
928                formalDefinition="A differential view is expressed relative to the base StructureDefinition - a statement of differences that it applies"
929        )
930        private Differential myDifferential;
931        
932
933        @Override
934        public boolean isEmpty() {
935                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myUrl,  myIdentifier,  myVersion,  myName,  myDisplay,  myStatus,  myExperimental,  myPublisher,  myContact,  myDate,  myDescription,  myUseContext,  myRequirements,  myCopyright,  myCode,  myFhirVersion,  myMapping,  myKind,  myConstrainedType,  myAbstract,  myContextType,  myContext,  myBase,  mySnapshot,  myDifferential);
936        }
937        
938        @Override
939        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
940                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myUrl, myIdentifier, myVersion, myName, myDisplay, myStatus, myExperimental, myPublisher, myContact, myDate, myDescription, myUseContext, myRequirements, myCopyright, myCode, myFhirVersion, myMapping, myKind, myConstrainedType, myAbstract, myContextType, myContext, myBase, mySnapshot, myDifferential);
941        }
942
943        /**
944         * Gets the value(s) for <b>url</b> (id).
945         * creating it if it does
946         * not exist. Will not return <code>null</code>.
947         *
948     * <p>
949     * <b>Definition:</b>
950     * An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published
951     * </p> 
952         */
953        public UriDt getUrlElement() {  
954                if (myUrl == null) {
955                        myUrl = new UriDt();
956                }
957                return myUrl;
958        }
959
960        
961        /**
962         * Gets the value(s) for <b>url</b> (id).
963         * creating it if it does
964         * not exist. This method may return <code>null</code>.
965         *
966     * <p>
967     * <b>Definition:</b>
968     * An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published
969     * </p> 
970         */
971        public String getUrl() {  
972                return getUrlElement().getValue();
973        }
974
975        /**
976         * Sets the value(s) for <b>url</b> (id)
977         *
978     * <p>
979     * <b>Definition:</b>
980     * An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published
981     * </p> 
982         */
983        public StructureDefinition setUrl(UriDt theValue) {
984                myUrl = theValue;
985                return this;
986        }
987        
988        
989
990        /**
991         * Sets the value for <b>url</b> (id)
992         *
993     * <p>
994     * <b>Definition:</b>
995     * An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published
996     * </p> 
997         */
998        public StructureDefinition setUrl( String theUri) {
999                myUrl = new UriDt(theUri); 
1000                return this; 
1001        }
1002
1003 
1004        /**
1005         * Gets the value(s) for <b>identifier</b> (id).
1006         * creating it if it does
1007         * not exist. Will not return <code>null</code>.
1008         *
1009     * <p>
1010     * <b>Definition:</b>
1011     * Formal identifier that is used to identify this StructureDefinition when it is represented in other formats, or referenced in a specification, model, design or an instance  (should be globally unique OID, UUID, or URI), (if it's not possible to use the literal URI)
1012     * </p> 
1013         */
1014        public java.util.List<IdentifierDt> getIdentifier() {  
1015                if (myIdentifier == null) {
1016                        myIdentifier = new java.util.ArrayList<IdentifierDt>();
1017                }
1018                return myIdentifier;
1019        }
1020
1021        /**
1022         * Sets the value(s) for <b>identifier</b> (id)
1023         *
1024     * <p>
1025     * <b>Definition:</b>
1026     * Formal identifier that is used to identify this StructureDefinition when it is represented in other formats, or referenced in a specification, model, design or an instance  (should be globally unique OID, UUID, or URI), (if it's not possible to use the literal URI)
1027     * </p> 
1028         */
1029        public StructureDefinition setIdentifier(java.util.List<IdentifierDt> theValue) {
1030                myIdentifier = theValue;
1031                return this;
1032        }
1033        
1034        
1035
1036        /**
1037         * Adds and returns a new value for <b>identifier</b> (id)
1038         *
1039     * <p>
1040     * <b>Definition:</b>
1041     * Formal identifier that is used to identify this StructureDefinition when it is represented in other formats, or referenced in a specification, model, design or an instance  (should be globally unique OID, UUID, or URI), (if it's not possible to use the literal URI)
1042     * </p> 
1043         */
1044        public IdentifierDt addIdentifier() {
1045                IdentifierDt newType = new IdentifierDt();
1046                getIdentifier().add(newType);
1047                return newType; 
1048        }
1049
1050        /**
1051         * Adds a given new value for <b>identifier</b> (id)
1052         *
1053         * <p>
1054         * <b>Definition:</b>
1055         * Formal identifier that is used to identify this StructureDefinition when it is represented in other formats, or referenced in a specification, model, design or an instance  (should be globally unique OID, UUID, or URI), (if it's not possible to use the literal URI)
1056         * </p>
1057         * @param theValue The identifier to add (must not be <code>null</code>)
1058         */
1059        public StructureDefinition addIdentifier(IdentifierDt theValue) {
1060                if (theValue == null) {
1061                        throw new NullPointerException("theValue must not be null");
1062                }
1063                getIdentifier().add(theValue);
1064                return this;
1065        }
1066
1067        /**
1068         * Gets the first repetition for <b>identifier</b> (id),
1069         * creating it if it does not already exist.
1070         *
1071     * <p>
1072     * <b>Definition:</b>
1073     * Formal identifier that is used to identify this StructureDefinition when it is represented in other formats, or referenced in a specification, model, design or an instance  (should be globally unique OID, UUID, or URI), (if it's not possible to use the literal URI)
1074     * </p> 
1075         */
1076        public IdentifierDt getIdentifierFirstRep() {
1077                if (getIdentifier().isEmpty()) {
1078                        return addIdentifier();
1079                }
1080                return getIdentifier().get(0); 
1081        }
1082  
1083        /**
1084         * Gets the value(s) for <b>version</b> (id.version).
1085         * creating it if it does
1086         * not exist. Will not return <code>null</code>.
1087         *
1088     * <p>
1089     * <b>Definition:</b>
1090     * The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually
1091     * </p> 
1092         */
1093        public StringDt getVersionElement() {  
1094                if (myVersion == null) {
1095                        myVersion = new StringDt();
1096                }
1097                return myVersion;
1098        }
1099
1100        
1101        /**
1102         * Gets the value(s) for <b>version</b> (id.version).
1103         * creating it if it does
1104         * not exist. This method may return <code>null</code>.
1105         *
1106     * <p>
1107     * <b>Definition:</b>
1108     * The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually
1109     * </p> 
1110         */
1111        public String getVersion() {  
1112                return getVersionElement().getValue();
1113        }
1114
1115        /**
1116         * Sets the value(s) for <b>version</b> (id.version)
1117         *
1118     * <p>
1119     * <b>Definition:</b>
1120     * The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually
1121     * </p> 
1122         */
1123        public StructureDefinition setVersion(StringDt theValue) {
1124                myVersion = theValue;
1125                return this;
1126        }
1127        
1128        
1129
1130        /**
1131         * Sets the value for <b>version</b> (id.version)
1132         *
1133     * <p>
1134     * <b>Definition:</b>
1135     * The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually
1136     * </p> 
1137         */
1138        public StructureDefinition setVersion( String theString) {
1139                myVersion = new StringDt(theString); 
1140                return this; 
1141        }
1142
1143 
1144        /**
1145         * Gets the value(s) for <b>name</b> ().
1146         * creating it if it does
1147         * not exist. Will not return <code>null</code>.
1148         *
1149     * <p>
1150     * <b>Definition:</b>
1151     * A free text natural language name identifying the StructureDefinition
1152     * </p> 
1153         */
1154        public StringDt getNameElement() {  
1155                if (myName == null) {
1156                        myName = new StringDt();
1157                }
1158                return myName;
1159        }
1160
1161        
1162        /**
1163         * Gets the value(s) for <b>name</b> ().
1164         * creating it if it does
1165         * not exist. This method may return <code>null</code>.
1166         *
1167     * <p>
1168     * <b>Definition:</b>
1169     * A free text natural language name identifying the StructureDefinition
1170     * </p> 
1171         */
1172        public String getName() {  
1173                return getNameElement().getValue();
1174        }
1175
1176        /**
1177         * Sets the value(s) for <b>name</b> ()
1178         *
1179     * <p>
1180     * <b>Definition:</b>
1181     * A free text natural language name identifying the StructureDefinition
1182     * </p> 
1183         */
1184        public StructureDefinition setName(StringDt theValue) {
1185                myName = theValue;
1186                return this;
1187        }
1188        
1189        
1190
1191        /**
1192         * Sets the value for <b>name</b> ()
1193         *
1194     * <p>
1195     * <b>Definition:</b>
1196     * A free text natural language name identifying the StructureDefinition
1197     * </p> 
1198         */
1199        public StructureDefinition setName( String theString) {
1200                myName = new StringDt(theString); 
1201                return this; 
1202        }
1203
1204 
1205        /**
1206         * Gets the value(s) for <b>display</b> ().
1207         * creating it if it does
1208         * not exist. Will not return <code>null</code>.
1209         *
1210     * <p>
1211     * <b>Definition:</b>
1212     * Defined so that applications can use this name when displaying the value of the extension to the user
1213     * </p> 
1214         */
1215        public StringDt getDisplayElement() {  
1216                if (myDisplay == null) {
1217                        myDisplay = new StringDt();
1218                }
1219                return myDisplay;
1220        }
1221
1222        
1223        /**
1224         * Gets the value(s) for <b>display</b> ().
1225         * creating it if it does
1226         * not exist. This method may return <code>null</code>.
1227         *
1228     * <p>
1229     * <b>Definition:</b>
1230     * Defined so that applications can use this name when displaying the value of the extension to the user
1231     * </p> 
1232         */
1233        public String getDisplay() {  
1234                return getDisplayElement().getValue();
1235        }
1236
1237        /**
1238         * Sets the value(s) for <b>display</b> ()
1239         *
1240     * <p>
1241     * <b>Definition:</b>
1242     * Defined so that applications can use this name when displaying the value of the extension to the user
1243     * </p> 
1244         */
1245        public StructureDefinition setDisplay(StringDt theValue) {
1246                myDisplay = theValue;
1247                return this;
1248        }
1249        
1250        
1251
1252        /**
1253         * Sets the value for <b>display</b> ()
1254         *
1255     * <p>
1256     * <b>Definition:</b>
1257     * Defined so that applications can use this name when displaying the value of the extension to the user
1258     * </p> 
1259         */
1260        public StructureDefinition setDisplay( String theString) {
1261                myDisplay = new StringDt(theString); 
1262                return this; 
1263        }
1264
1265 
1266        /**
1267         * Gets the value(s) for <b>status</b> (status).
1268         * creating it if it does
1269         * not exist. Will not return <code>null</code>.
1270         *
1271     * <p>
1272     * <b>Definition:</b>
1273     * The status of the StructureDefinition
1274     * </p> 
1275         */
1276        public BoundCodeDt<ConformanceResourceStatusEnum> getStatusElement() {  
1277                if (myStatus == null) {
1278                        myStatus = new BoundCodeDt<ConformanceResourceStatusEnum>(ConformanceResourceStatusEnum.VALUESET_BINDER);
1279                }
1280                return myStatus;
1281        }
1282
1283        
1284        /**
1285         * Gets the value(s) for <b>status</b> (status).
1286         * creating it if it does
1287         * not exist. This method may return <code>null</code>.
1288         *
1289     * <p>
1290     * <b>Definition:</b>
1291     * The status of the StructureDefinition
1292     * </p> 
1293         */
1294        public String getStatus() {  
1295                return getStatusElement().getValue();
1296        }
1297
1298        /**
1299         * Sets the value(s) for <b>status</b> (status)
1300         *
1301     * <p>
1302     * <b>Definition:</b>
1303     * The status of the StructureDefinition
1304     * </p> 
1305         */
1306        public StructureDefinition setStatus(BoundCodeDt<ConformanceResourceStatusEnum> theValue) {
1307                myStatus = theValue;
1308                return this;
1309        }
1310        
1311        
1312
1313        /**
1314         * Sets the value(s) for <b>status</b> (status)
1315         *
1316     * <p>
1317     * <b>Definition:</b>
1318     * The status of the StructureDefinition
1319     * </p> 
1320         */
1321        public StructureDefinition setStatus(ConformanceResourceStatusEnum theValue) {
1322                setStatus(new BoundCodeDt<ConformanceResourceStatusEnum>(ConformanceResourceStatusEnum.VALUESET_BINDER, theValue));
1323                
1324/*
1325                getStatusElement().setValueAsEnum(theValue);
1326*/
1327                return this;
1328        }
1329
1330  
1331        /**
1332         * Gets the value(s) for <b>experimental</b> (class).
1333         * creating it if it does
1334         * not exist. Will not return <code>null</code>.
1335         *
1336     * <p>
1337     * <b>Definition:</b>
1338     * This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage
1339     * </p> 
1340         */
1341        public BooleanDt getExperimentalElement() {  
1342                if (myExperimental == null) {
1343                        myExperimental = new BooleanDt();
1344                }
1345                return myExperimental;
1346        }
1347
1348        
1349        /**
1350         * Gets the value(s) for <b>experimental</b> (class).
1351         * creating it if it does
1352         * not exist. This method may return <code>null</code>.
1353         *
1354     * <p>
1355     * <b>Definition:</b>
1356     * This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage
1357     * </p> 
1358         */
1359        public Boolean getExperimental() {  
1360                return getExperimentalElement().getValue();
1361        }
1362
1363        /**
1364         * Sets the value(s) for <b>experimental</b> (class)
1365         *
1366     * <p>
1367     * <b>Definition:</b>
1368     * This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage
1369     * </p> 
1370         */
1371        public StructureDefinition setExperimental(BooleanDt theValue) {
1372                myExperimental = theValue;
1373                return this;
1374        }
1375        
1376        
1377
1378        /**
1379         * Sets the value for <b>experimental</b> (class)
1380         *
1381     * <p>
1382     * <b>Definition:</b>
1383     * This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage
1384     * </p> 
1385         */
1386        public StructureDefinition setExperimental( boolean theBoolean) {
1387                myExperimental = new BooleanDt(theBoolean); 
1388                return this; 
1389        }
1390
1391 
1392        /**
1393         * Gets the value(s) for <b>publisher</b> (who.witness).
1394         * creating it if it does
1395         * not exist. Will not return <code>null</code>.
1396         *
1397     * <p>
1398     * <b>Definition:</b>
1399     * The name of the individual or organization that published the structure definition
1400     * </p> 
1401         */
1402        public StringDt getPublisherElement() {  
1403                if (myPublisher == null) {
1404                        myPublisher = new StringDt();
1405                }
1406                return myPublisher;
1407        }
1408
1409        
1410        /**
1411         * Gets the value(s) for <b>publisher</b> (who.witness).
1412         * creating it if it does
1413         * not exist. This method may return <code>null</code>.
1414         *
1415     * <p>
1416     * <b>Definition:</b>
1417     * The name of the individual or organization that published the structure definition
1418     * </p> 
1419         */
1420        public String getPublisher() {  
1421                return getPublisherElement().getValue();
1422        }
1423
1424        /**
1425         * Sets the value(s) for <b>publisher</b> (who.witness)
1426         *
1427     * <p>
1428     * <b>Definition:</b>
1429     * The name of the individual or organization that published the structure definition
1430     * </p> 
1431         */
1432        public StructureDefinition setPublisher(StringDt theValue) {
1433                myPublisher = theValue;
1434                return this;
1435        }
1436        
1437        
1438
1439        /**
1440         * Sets the value for <b>publisher</b> (who.witness)
1441         *
1442     * <p>
1443     * <b>Definition:</b>
1444     * The name of the individual or organization that published the structure definition
1445     * </p> 
1446         */
1447        public StructureDefinition setPublisher( String theString) {
1448                myPublisher = new StringDt(theString); 
1449                return this; 
1450        }
1451
1452 
1453        /**
1454         * Gets the value(s) for <b>contact</b> ().
1455         * creating it if it does
1456         * not exist. Will not return <code>null</code>.
1457         *
1458     * <p>
1459     * <b>Definition:</b>
1460     * Contacts to assist a user in finding and communicating with the publisher
1461     * </p> 
1462         */
1463        public java.util.List<Contact> getContact() {  
1464                if (myContact == null) {
1465                        myContact = new java.util.ArrayList<Contact>();
1466                }
1467                return myContact;
1468        }
1469
1470        /**
1471         * Sets the value(s) for <b>contact</b> ()
1472         *
1473     * <p>
1474     * <b>Definition:</b>
1475     * Contacts to assist a user in finding and communicating with the publisher
1476     * </p> 
1477         */
1478        public StructureDefinition setContact(java.util.List<Contact> theValue) {
1479                myContact = theValue;
1480                return this;
1481        }
1482        
1483        
1484
1485        /**
1486         * Adds and returns a new value for <b>contact</b> ()
1487         *
1488     * <p>
1489     * <b>Definition:</b>
1490     * Contacts to assist a user in finding and communicating with the publisher
1491     * </p> 
1492         */
1493        public Contact addContact() {
1494                Contact newType = new Contact();
1495                getContact().add(newType);
1496                return newType; 
1497        }
1498
1499        /**
1500         * Adds a given new value for <b>contact</b> ()
1501         *
1502         * <p>
1503         * <b>Definition:</b>
1504         * Contacts to assist a user in finding and communicating with the publisher
1505         * </p>
1506         * @param theValue The contact to add (must not be <code>null</code>)
1507         */
1508        public StructureDefinition addContact(Contact theValue) {
1509                if (theValue == null) {
1510                        throw new NullPointerException("theValue must not be null");
1511                }
1512                getContact().add(theValue);
1513                return this;
1514        }
1515
1516        /**
1517         * Gets the first repetition for <b>contact</b> (),
1518         * creating it if it does not already exist.
1519         *
1520     * <p>
1521     * <b>Definition:</b>
1522     * Contacts to assist a user in finding and communicating with the publisher
1523     * </p> 
1524         */
1525        public Contact getContactFirstRep() {
1526                if (getContact().isEmpty()) {
1527                        return addContact();
1528                }
1529                return getContact().get(0); 
1530        }
1531  
1532        /**
1533         * Gets the value(s) for <b>date</b> (when.recorded).
1534         * creating it if it does
1535         * not exist. Will not return <code>null</code>.
1536         *
1537     * <p>
1538     * <b>Definition:</b>
1539     * The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes
1540     * </p> 
1541         */
1542        public DateTimeDt getDateElement() {  
1543                if (myDate == null) {
1544                        myDate = new DateTimeDt();
1545                }
1546                return myDate;
1547        }
1548
1549        
1550        /**
1551         * Gets the value(s) for <b>date</b> (when.recorded).
1552         * creating it if it does
1553         * not exist. This method may return <code>null</code>.
1554         *
1555     * <p>
1556     * <b>Definition:</b>
1557     * The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes
1558     * </p> 
1559         */
1560        public Date getDate() {  
1561                return getDateElement().getValue();
1562        }
1563
1564        /**
1565         * Sets the value(s) for <b>date</b> (when.recorded)
1566         *
1567     * <p>
1568     * <b>Definition:</b>
1569     * The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes
1570     * </p> 
1571         */
1572        public StructureDefinition setDate(DateTimeDt theValue) {
1573                myDate = theValue;
1574                return this;
1575        }
1576        
1577        
1578
1579        /**
1580         * Sets the value for <b>date</b> (when.recorded)
1581         *
1582     * <p>
1583     * <b>Definition:</b>
1584     * The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes
1585     * </p> 
1586         */
1587        public StructureDefinition setDateWithSecondsPrecision( Date theDate) {
1588                myDate = new DateTimeDt(theDate); 
1589                return this; 
1590        }
1591
1592        /**
1593         * Sets the value for <b>date</b> (when.recorded)
1594         *
1595     * <p>
1596     * <b>Definition:</b>
1597     * The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes
1598     * </p> 
1599         */
1600        public StructureDefinition setDate( Date theDate,  TemporalPrecisionEnum thePrecision) {
1601                myDate = new DateTimeDt(theDate, thePrecision); 
1602                return this; 
1603        }
1604
1605 
1606        /**
1607         * Gets the value(s) for <b>description</b> ().
1608         * creating it if it does
1609         * not exist. Will not return <code>null</code>.
1610         *
1611     * <p>
1612     * <b>Definition:</b>
1613     * A free text natural language description of the StructureDefinition and its use
1614     * </p> 
1615         */
1616        public StringDt getDescriptionElement() {  
1617                if (myDescription == null) {
1618                        myDescription = new StringDt();
1619                }
1620                return myDescription;
1621        }
1622
1623        
1624        /**
1625         * Gets the value(s) for <b>description</b> ().
1626         * creating it if it does
1627         * not exist. This method may return <code>null</code>.
1628         *
1629     * <p>
1630     * <b>Definition:</b>
1631     * A free text natural language description of the StructureDefinition and its use
1632     * </p> 
1633         */
1634        public String getDescription() {  
1635                return getDescriptionElement().getValue();
1636        }
1637
1638        /**
1639         * Sets the value(s) for <b>description</b> ()
1640         *
1641     * <p>
1642     * <b>Definition:</b>
1643     * A free text natural language description of the StructureDefinition and its use
1644     * </p> 
1645         */
1646        public StructureDefinition setDescription(StringDt theValue) {
1647                myDescription = theValue;
1648                return this;
1649        }
1650        
1651        
1652
1653        /**
1654         * Sets the value for <b>description</b> ()
1655         *
1656     * <p>
1657     * <b>Definition:</b>
1658     * A free text natural language description of the StructureDefinition and its use
1659     * </p> 
1660         */
1661        public StructureDefinition setDescription( String theString) {
1662                myDescription = new StringDt(theString); 
1663                return this; 
1664        }
1665
1666 
1667        /**
1668         * Gets the value(s) for <b>useContext</b> ().
1669         * creating it if it does
1670         * not exist. Will not return <code>null</code>.
1671         *
1672     * <p>
1673     * <b>Definition:</b>
1674     * The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of structure definitions.
1675     * </p> 
1676         */
1677        public java.util.List<CodeableConceptDt> getUseContext() {  
1678                if (myUseContext == null) {
1679                        myUseContext = new java.util.ArrayList<CodeableConceptDt>();
1680                }
1681                return myUseContext;
1682        }
1683
1684        /**
1685         * Sets the value(s) for <b>useContext</b> ()
1686         *
1687     * <p>
1688     * <b>Definition:</b>
1689     * The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of structure definitions.
1690     * </p> 
1691         */
1692        public StructureDefinition setUseContext(java.util.List<CodeableConceptDt> theValue) {
1693                myUseContext = theValue;
1694                return this;
1695        }
1696        
1697        
1698
1699        /**
1700         * Adds and returns a new value for <b>useContext</b> ()
1701         *
1702     * <p>
1703     * <b>Definition:</b>
1704     * The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of structure definitions.
1705     * </p> 
1706         */
1707        public CodeableConceptDt addUseContext() {
1708                CodeableConceptDt newType = new CodeableConceptDt();
1709                getUseContext().add(newType);
1710                return newType; 
1711        }
1712
1713        /**
1714         * Adds a given new value for <b>useContext</b> ()
1715         *
1716         * <p>
1717         * <b>Definition:</b>
1718         * The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of structure definitions.
1719         * </p>
1720         * @param theValue The useContext to add (must not be <code>null</code>)
1721         */
1722        public StructureDefinition addUseContext(CodeableConceptDt theValue) {
1723                if (theValue == null) {
1724                        throw new NullPointerException("theValue must not be null");
1725                }
1726                getUseContext().add(theValue);
1727                return this;
1728        }
1729
1730        /**
1731         * Gets the first repetition for <b>useContext</b> (),
1732         * creating it if it does not already exist.
1733         *
1734     * <p>
1735     * <b>Definition:</b>
1736     * The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of structure definitions.
1737     * </p> 
1738         */
1739        public CodeableConceptDt getUseContextFirstRep() {
1740                if (getUseContext().isEmpty()) {
1741                        return addUseContext();
1742                }
1743                return getUseContext().get(0); 
1744        }
1745  
1746        /**
1747         * Gets the value(s) for <b>requirements</b> (why).
1748         * creating it if it does
1749         * not exist. Will not return <code>null</code>.
1750         *
1751     * <p>
1752     * <b>Definition:</b>
1753     * Explains why this structure definition is needed and why it's been constrained as it has
1754     * </p> 
1755         */
1756        public StringDt getRequirementsElement() {  
1757                if (myRequirements == null) {
1758                        myRequirements = new StringDt();
1759                }
1760                return myRequirements;
1761        }
1762
1763        
1764        /**
1765         * Gets the value(s) for <b>requirements</b> (why).
1766         * creating it if it does
1767         * not exist. This method may return <code>null</code>.
1768         *
1769     * <p>
1770     * <b>Definition:</b>
1771     * Explains why this structure definition is needed and why it's been constrained as it has
1772     * </p> 
1773         */
1774        public String getRequirements() {  
1775                return getRequirementsElement().getValue();
1776        }
1777
1778        /**
1779         * Sets the value(s) for <b>requirements</b> (why)
1780         *
1781     * <p>
1782     * <b>Definition:</b>
1783     * Explains why this structure definition is needed and why it's been constrained as it has
1784     * </p> 
1785         */
1786        public StructureDefinition setRequirements(StringDt theValue) {
1787                myRequirements = theValue;
1788                return this;
1789        }
1790        
1791        
1792
1793        /**
1794         * Sets the value for <b>requirements</b> (why)
1795         *
1796     * <p>
1797     * <b>Definition:</b>
1798     * Explains why this structure definition is needed and why it's been constrained as it has
1799     * </p> 
1800         */
1801        public StructureDefinition setRequirements( String theString) {
1802                myRequirements = new StringDt(theString); 
1803                return this; 
1804        }
1805
1806 
1807        /**
1808         * Gets the value(s) for <b>copyright</b> ().
1809         * creating it if it does
1810         * not exist. Will not return <code>null</code>.
1811         *
1812     * <p>
1813     * <b>Definition:</b>
1814     * A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings
1815     * </p> 
1816         */
1817        public StringDt getCopyrightElement() {  
1818                if (myCopyright == null) {
1819                        myCopyright = new StringDt();
1820                }
1821                return myCopyright;
1822        }
1823
1824        
1825        /**
1826         * Gets the value(s) for <b>copyright</b> ().
1827         * creating it if it does
1828         * not exist. This method may return <code>null</code>.
1829         *
1830     * <p>
1831     * <b>Definition:</b>
1832     * A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings
1833     * </p> 
1834         */
1835        public String getCopyright() {  
1836                return getCopyrightElement().getValue();
1837        }
1838
1839        /**
1840         * Sets the value(s) for <b>copyright</b> ()
1841         *
1842     * <p>
1843     * <b>Definition:</b>
1844     * A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings
1845     * </p> 
1846         */
1847        public StructureDefinition setCopyright(StringDt theValue) {
1848                myCopyright = theValue;
1849                return this;
1850        }
1851        
1852        
1853
1854        /**
1855         * Sets the value for <b>copyright</b> ()
1856         *
1857     * <p>
1858     * <b>Definition:</b>
1859     * A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings
1860     * </p> 
1861         */
1862        public StructureDefinition setCopyright( String theString) {
1863                myCopyright = new StringDt(theString); 
1864                return this; 
1865        }
1866
1867 
1868        /**
1869         * Gets the value(s) for <b>code</b> ().
1870         * creating it if it does
1871         * not exist. Will not return <code>null</code>.
1872         *
1873     * <p>
1874     * <b>Definition:</b>
1875     * A set of terms from external terminologies that may be used to assist with indexing and searching of templates.
1876     * </p> 
1877         */
1878        public java.util.List<CodingDt> getCode() {  
1879                if (myCode == null) {
1880                        myCode = new java.util.ArrayList<CodingDt>();
1881                }
1882                return myCode;
1883        }
1884
1885        /**
1886         * Sets the value(s) for <b>code</b> ()
1887         *
1888     * <p>
1889     * <b>Definition:</b>
1890     * A set of terms from external terminologies that may be used to assist with indexing and searching of templates.
1891     * </p> 
1892         */
1893        public StructureDefinition setCode(java.util.List<CodingDt> theValue) {
1894                myCode = theValue;
1895                return this;
1896        }
1897        
1898        
1899
1900        /**
1901         * Adds and returns a new value for <b>code</b> ()
1902         *
1903     * <p>
1904     * <b>Definition:</b>
1905     * A set of terms from external terminologies that may be used to assist with indexing and searching of templates.
1906     * </p> 
1907         */
1908        public CodingDt addCode() {
1909                CodingDt newType = new CodingDt();
1910                getCode().add(newType);
1911                return newType; 
1912        }
1913
1914        /**
1915         * Adds a given new value for <b>code</b> ()
1916         *
1917         * <p>
1918         * <b>Definition:</b>
1919         * A set of terms from external terminologies that may be used to assist with indexing and searching of templates.
1920         * </p>
1921         * @param theValue The code to add (must not be <code>null</code>)
1922         */
1923        public StructureDefinition addCode(CodingDt theValue) {
1924                if (theValue == null) {
1925                        throw new NullPointerException("theValue must not be null");
1926                }
1927                getCode().add(theValue);
1928                return this;
1929        }
1930
1931        /**
1932         * Gets the first repetition for <b>code</b> (),
1933         * creating it if it does not already exist.
1934         *
1935     * <p>
1936     * <b>Definition:</b>
1937     * A set of terms from external terminologies that may be used to assist with indexing and searching of templates.
1938     * </p> 
1939         */
1940        public CodingDt getCodeFirstRep() {
1941                if (getCode().isEmpty()) {
1942                        return addCode();
1943                }
1944                return getCode().get(0); 
1945        }
1946  
1947        /**
1948         * Gets the value(s) for <b>fhirVersion</b> ().
1949         * creating it if it does
1950         * not exist. Will not return <code>null</code>.
1951         *
1952     * <p>
1953     * <b>Definition:</b>
1954     * The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is $version$ for this version
1955     * </p> 
1956         */
1957        public IdDt getFhirVersionElement() {  
1958                if (myFhirVersion == null) {
1959                        myFhirVersion = new IdDt();
1960                }
1961                return myFhirVersion;
1962        }
1963
1964        
1965        /**
1966         * Gets the value(s) for <b>fhirVersion</b> ().
1967         * creating it if it does
1968         * not exist. This method may return <code>null</code>.
1969         *
1970     * <p>
1971     * <b>Definition:</b>
1972     * The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is $version$ for this version
1973     * </p> 
1974         */
1975        public String getFhirVersion() {  
1976                return getFhirVersionElement().getValue();
1977        }
1978
1979        /**
1980         * Sets the value(s) for <b>fhirVersion</b> ()
1981         *
1982     * <p>
1983     * <b>Definition:</b>
1984     * The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is $version$ for this version
1985     * </p> 
1986         */
1987        public StructureDefinition setFhirVersion(IdDt theValue) {
1988                myFhirVersion = theValue;
1989                return this;
1990        }
1991        
1992        
1993
1994        /**
1995         * Sets the value for <b>fhirVersion</b> ()
1996         *
1997     * <p>
1998     * <b>Definition:</b>
1999     * The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is $version$ for this version
2000     * </p> 
2001         */
2002        public StructureDefinition setFhirVersion( String theId) {
2003                myFhirVersion = new IdDt(theId); 
2004                return this; 
2005        }
2006
2007 
2008        /**
2009         * Gets the value(s) for <b>mapping</b> ().
2010         * creating it if it does
2011         * not exist. Will not return <code>null</code>.
2012         *
2013     * <p>
2014     * <b>Definition:</b>
2015     * An external specification that the content is mapped to
2016     * </p> 
2017         */
2018        public java.util.List<Mapping> getMapping() {  
2019                if (myMapping == null) {
2020                        myMapping = new java.util.ArrayList<Mapping>();
2021                }
2022                return myMapping;
2023        }
2024
2025        /**
2026         * Sets the value(s) for <b>mapping</b> ()
2027         *
2028     * <p>
2029     * <b>Definition:</b>
2030     * An external specification that the content is mapped to
2031     * </p> 
2032         */
2033        public StructureDefinition setMapping(java.util.List<Mapping> theValue) {
2034                myMapping = theValue;
2035                return this;
2036        }
2037        
2038        
2039
2040        /**
2041         * Adds and returns a new value for <b>mapping</b> ()
2042         *
2043     * <p>
2044     * <b>Definition:</b>
2045     * An external specification that the content is mapped to
2046     * </p> 
2047         */
2048        public Mapping addMapping() {
2049                Mapping newType = new Mapping();
2050                getMapping().add(newType);
2051                return newType; 
2052        }
2053
2054        /**
2055         * Adds a given new value for <b>mapping</b> ()
2056         *
2057         * <p>
2058         * <b>Definition:</b>
2059         * An external specification that the content is mapped to
2060         * </p>
2061         * @param theValue The mapping to add (must not be <code>null</code>)
2062         */
2063        public StructureDefinition addMapping(Mapping theValue) {
2064                if (theValue == null) {
2065                        throw new NullPointerException("theValue must not be null");
2066                }
2067                getMapping().add(theValue);
2068                return this;
2069        }
2070
2071        /**
2072         * Gets the first repetition for <b>mapping</b> (),
2073         * creating it if it does not already exist.
2074         *
2075     * <p>
2076     * <b>Definition:</b>
2077     * An external specification that the content is mapped to
2078     * </p> 
2079         */
2080        public Mapping getMappingFirstRep() {
2081                if (getMapping().isEmpty()) {
2082                        return addMapping();
2083                }
2084                return getMapping().get(0); 
2085        }
2086  
2087        /**
2088         * Gets the value(s) for <b>kind</b> ().
2089         * creating it if it does
2090         * not exist. Will not return <code>null</code>.
2091         *
2092     * <p>
2093     * <b>Definition:</b>
2094     * Defines the kind of structure that this definition is describing
2095     * </p> 
2096         */
2097        public BoundCodeDt<StructureDefinitionKindEnum> getKindElement() {  
2098                if (myKind == null) {
2099                        myKind = new BoundCodeDt<StructureDefinitionKindEnum>(StructureDefinitionKindEnum.VALUESET_BINDER);
2100                }
2101                return myKind;
2102        }
2103
2104        
2105        /**
2106         * Gets the value(s) for <b>kind</b> ().
2107         * creating it if it does
2108         * not exist. This method may return <code>null</code>.
2109         *
2110     * <p>
2111     * <b>Definition:</b>
2112     * Defines the kind of structure that this definition is describing
2113     * </p> 
2114         */
2115        public String getKind() {  
2116                return getKindElement().getValue();
2117        }
2118
2119        /**
2120         * Sets the value(s) for <b>kind</b> ()
2121         *
2122     * <p>
2123     * <b>Definition:</b>
2124     * Defines the kind of structure that this definition is describing
2125     * </p> 
2126         */
2127        public StructureDefinition setKind(BoundCodeDt<StructureDefinitionKindEnum> theValue) {
2128                myKind = theValue;
2129                return this;
2130        }
2131        
2132        
2133
2134        /**
2135         * Sets the value(s) for <b>kind</b> ()
2136         *
2137     * <p>
2138     * <b>Definition:</b>
2139     * Defines the kind of structure that this definition is describing
2140     * </p> 
2141         */
2142        public StructureDefinition setKind(StructureDefinitionKindEnum theValue) {
2143                setKind(new BoundCodeDt<StructureDefinitionKindEnum>(StructureDefinitionKindEnum.VALUESET_BINDER, theValue));
2144                
2145/*
2146                getKindElement().setValueAsEnum(theValue);
2147*/
2148                return this;
2149        }
2150
2151  
2152        /**
2153         * Gets the value(s) for <b>constrainedType</b> ().
2154         * creating it if it does
2155         * not exist. Will not return <code>null</code>.
2156         *
2157     * <p>
2158     * <b>Definition:</b>
2159     * The type of type that is being constrained - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is a constraint. If it is not present, then the structure definition is the definition of a base structure
2160     * </p> 
2161         */
2162        public CodeDt getConstrainedTypeElement() {  
2163                if (myConstrainedType == null) {
2164                        myConstrainedType = new CodeDt();
2165                }
2166                return myConstrainedType;
2167        }
2168
2169        
2170        /**
2171         * Gets the value(s) for <b>constrainedType</b> ().
2172         * creating it if it does
2173         * not exist. This method may return <code>null</code>.
2174         *
2175     * <p>
2176     * <b>Definition:</b>
2177     * The type of type that is being constrained - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is a constraint. If it is not present, then the structure definition is the definition of a base structure
2178     * </p> 
2179         */
2180        public String getConstrainedType() {  
2181                return getConstrainedTypeElement().getValue();
2182        }
2183
2184        /**
2185         * Sets the value(s) for <b>constrainedType</b> ()
2186         *
2187     * <p>
2188     * <b>Definition:</b>
2189     * The type of type that is being constrained - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is a constraint. If it is not present, then the structure definition is the definition of a base structure
2190     * </p> 
2191         */
2192        public StructureDefinition setConstrainedType(CodeDt theValue) {
2193                myConstrainedType = theValue;
2194                return this;
2195        }
2196        
2197        
2198
2199        /**
2200         * Sets the value for <b>constrainedType</b> ()
2201         *
2202     * <p>
2203     * <b>Definition:</b>
2204     * The type of type that is being constrained - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is a constraint. If it is not present, then the structure definition is the definition of a base structure
2205     * </p> 
2206         */
2207        public StructureDefinition setConstrainedType( String theCode) {
2208                myConstrainedType = new CodeDt(theCode); 
2209                return this; 
2210        }
2211
2212 
2213        /**
2214         * Gets the value(s) for <b>abstract</b> ().
2215         * creating it if it does
2216         * not exist. Will not return <code>null</code>.
2217         *
2218     * <p>
2219     * <b>Definition:</b>
2220     * Whether structure this definition describes is abstract or not  - that is, whether an actual exchanged item can ever be of this type
2221     * </p> 
2222         */
2223        public BooleanDt getAbstractElement() {  
2224                if (myAbstract == null) {
2225                        myAbstract = new BooleanDt();
2226                }
2227                return myAbstract;
2228        }
2229
2230        
2231        /**
2232         * Gets the value(s) for <b>abstract</b> ().
2233         * creating it if it does
2234         * not exist. This method may return <code>null</code>.
2235         *
2236     * <p>
2237     * <b>Definition:</b>
2238     * Whether structure this definition describes is abstract or not  - that is, whether an actual exchanged item can ever be of this type
2239     * </p> 
2240         */
2241        public Boolean getAbstract() {  
2242                return getAbstractElement().getValue();
2243        }
2244
2245        /**
2246         * Sets the value(s) for <b>abstract</b> ()
2247         *
2248     * <p>
2249     * <b>Definition:</b>
2250     * Whether structure this definition describes is abstract or not  - that is, whether an actual exchanged item can ever be of this type
2251     * </p> 
2252         */
2253        public StructureDefinition setAbstract(BooleanDt theValue) {
2254                myAbstract = theValue;
2255                return this;
2256        }
2257        
2258        
2259
2260        /**
2261         * Sets the value for <b>abstract</b> ()
2262         *
2263     * <p>
2264     * <b>Definition:</b>
2265     * Whether structure this definition describes is abstract or not  - that is, whether an actual exchanged item can ever be of this type
2266     * </p> 
2267         */
2268        public StructureDefinition setAbstract( boolean theBoolean) {
2269                myAbstract = new BooleanDt(theBoolean); 
2270                return this; 
2271        }
2272
2273 
2274        /**
2275         * Gets the value(s) for <b>contextType</b> ().
2276         * creating it if it does
2277         * not exist. Will not return <code>null</code>.
2278         *
2279     * <p>
2280     * <b>Definition:</b>
2281     * If this is an extension, Identifies the context within FHIR resources where the extension can be used
2282     * </p> 
2283         */
2284        public BoundCodeDt<ExtensionContextEnum> getContextTypeElement() {  
2285                if (myContextType == null) {
2286                        myContextType = new BoundCodeDt<ExtensionContextEnum>(ExtensionContextEnum.VALUESET_BINDER);
2287                }
2288                return myContextType;
2289        }
2290
2291        
2292        /**
2293         * Gets the value(s) for <b>contextType</b> ().
2294         * creating it if it does
2295         * not exist. This method may return <code>null</code>.
2296         *
2297     * <p>
2298     * <b>Definition:</b>
2299     * If this is an extension, Identifies the context within FHIR resources where the extension can be used
2300     * </p> 
2301         */
2302        public String getContextType() {  
2303                return getContextTypeElement().getValue();
2304        }
2305
2306        /**
2307         * Sets the value(s) for <b>contextType</b> ()
2308         *
2309     * <p>
2310     * <b>Definition:</b>
2311     * If this is an extension, Identifies the context within FHIR resources where the extension can be used
2312     * </p> 
2313         */
2314        public StructureDefinition setContextType(BoundCodeDt<ExtensionContextEnum> theValue) {
2315                myContextType = theValue;
2316                return this;
2317        }
2318        
2319        
2320
2321        /**
2322         * Sets the value(s) for <b>contextType</b> ()
2323         *
2324     * <p>
2325     * <b>Definition:</b>
2326     * If this is an extension, Identifies the context within FHIR resources where the extension can be used
2327     * </p> 
2328         */
2329        public StructureDefinition setContextType(ExtensionContextEnum theValue) {
2330                setContextType(new BoundCodeDt<ExtensionContextEnum>(ExtensionContextEnum.VALUESET_BINDER, theValue));
2331                
2332/*
2333                getContextTypeElement().setValueAsEnum(theValue);
2334*/
2335                return this;
2336        }
2337
2338  
2339        /**
2340         * Gets the value(s) for <b>context</b> ().
2341         * creating it if it does
2342         * not exist. Will not return <code>null</code>.
2343         *
2344     * <p>
2345     * <b>Definition:</b>
2346     * Identifies the types of resource or data type elements to which the extension can be applied
2347     * </p> 
2348         */
2349        public java.util.List<StringDt> getContext() {  
2350                if (myContext == null) {
2351                        myContext = new java.util.ArrayList<StringDt>();
2352                }
2353                return myContext;
2354        }
2355
2356        /**
2357         * Sets the value(s) for <b>context</b> ()
2358         *
2359     * <p>
2360     * <b>Definition:</b>
2361     * Identifies the types of resource or data type elements to which the extension can be applied
2362     * </p> 
2363         */
2364        public StructureDefinition setContext(java.util.List<StringDt> theValue) {
2365                myContext = theValue;
2366                return this;
2367        }
2368        
2369        
2370
2371        /**
2372         * Adds and returns a new value for <b>context</b> ()
2373         *
2374     * <p>
2375     * <b>Definition:</b>
2376     * Identifies the types of resource or data type elements to which the extension can be applied
2377     * </p> 
2378         */
2379        public StringDt addContext() {
2380                StringDt newType = new StringDt();
2381                getContext().add(newType);
2382                return newType; 
2383        }
2384
2385        /**
2386         * Adds a given new value for <b>context</b> ()
2387         *
2388         * <p>
2389         * <b>Definition:</b>
2390         * Identifies the types of resource or data type elements to which the extension can be applied
2391         * </p>
2392         * @param theValue The context to add (must not be <code>null</code>)
2393         */
2394        public StructureDefinition addContext(StringDt theValue) {
2395                if (theValue == null) {
2396                        throw new NullPointerException("theValue must not be null");
2397                }
2398                getContext().add(theValue);
2399                return this;
2400        }
2401
2402        /**
2403         * Gets the first repetition for <b>context</b> (),
2404         * creating it if it does not already exist.
2405         *
2406     * <p>
2407     * <b>Definition:</b>
2408     * Identifies the types of resource or data type elements to which the extension can be applied
2409     * </p> 
2410         */
2411        public StringDt getContextFirstRep() {
2412                if (getContext().isEmpty()) {
2413                        return addContext();
2414                }
2415                return getContext().get(0); 
2416        }
2417        /**
2418         * Adds a new value for <b>context</b> ()
2419         *
2420     * <p>
2421     * <b>Definition:</b>
2422     * Identifies the types of resource or data type elements to which the extension can be applied
2423     * </p> 
2424     *
2425     * @return Returns a reference to this object, to allow for simple chaining.
2426         */
2427        public StructureDefinition addContext( String theString) {
2428                if (myContext == null) {
2429                        myContext = new java.util.ArrayList<StringDt>();
2430                }
2431                myContext.add(new StringDt(theString));
2432                return this; 
2433        }
2434
2435 
2436        /**
2437         * Gets the value(s) for <b>base</b> ().
2438         * creating it if it does
2439         * not exist. Will not return <code>null</code>.
2440         *
2441     * <p>
2442     * <b>Definition:</b>
2443     * An absolute URI that is the base structure from which this set of constraints is derived
2444     * </p> 
2445         */
2446        public UriDt getBaseElement() {  
2447                if (myBase == null) {
2448                        myBase = new UriDt();
2449                }
2450                return myBase;
2451        }
2452
2453        
2454        /**
2455         * Gets the value(s) for <b>base</b> ().
2456         * creating it if it does
2457         * not exist. This method may return <code>null</code>.
2458         *
2459     * <p>
2460     * <b>Definition:</b>
2461     * An absolute URI that is the base structure from which this set of constraints is derived
2462     * </p> 
2463         */
2464        public String getBase() {  
2465                return getBaseElement().getValue();
2466        }
2467
2468        /**
2469         * Sets the value(s) for <b>base</b> ()
2470         *
2471     * <p>
2472     * <b>Definition:</b>
2473     * An absolute URI that is the base structure from which this set of constraints is derived
2474     * </p> 
2475         */
2476        public StructureDefinition setBase(UriDt theValue) {
2477                myBase = theValue;
2478                return this;
2479        }
2480        
2481        
2482
2483        /**
2484         * Sets the value for <b>base</b> ()
2485         *
2486     * <p>
2487     * <b>Definition:</b>
2488     * An absolute URI that is the base structure from which this set of constraints is derived
2489     * </p> 
2490         */
2491        public StructureDefinition setBase( String theUri) {
2492                myBase = new UriDt(theUri); 
2493                return this; 
2494        }
2495
2496 
2497        /**
2498         * Gets the value(s) for <b>snapshot</b> ().
2499         * creating it if it does
2500         * not exist. Will not return <code>null</code>.
2501         *
2502     * <p>
2503     * <b>Definition:</b>
2504     * A snapshot view is expressed in a stand alone form that can be used and interpreted without considering the base StructureDefinition
2505     * </p> 
2506         */
2507        public Snapshot getSnapshot() {  
2508                if (mySnapshot == null) {
2509                        mySnapshot = new Snapshot();
2510                }
2511                return mySnapshot;
2512        }
2513
2514        /**
2515         * Sets the value(s) for <b>snapshot</b> ()
2516         *
2517     * <p>
2518     * <b>Definition:</b>
2519     * A snapshot view is expressed in a stand alone form that can be used and interpreted without considering the base StructureDefinition
2520     * </p> 
2521         */
2522        public StructureDefinition setSnapshot(Snapshot theValue) {
2523                mySnapshot = theValue;
2524                return this;
2525        }
2526        
2527        
2528
2529  
2530        /**
2531         * Gets the value(s) for <b>differential</b> ().
2532         * creating it if it does
2533         * not exist. Will not return <code>null</code>.
2534         *
2535     * <p>
2536     * <b>Definition:</b>
2537     * A differential view is expressed relative to the base StructureDefinition - a statement of differences that it applies
2538     * </p> 
2539         */
2540        public Differential getDifferential() {  
2541                if (myDifferential == null) {
2542                        myDifferential = new Differential();
2543                }
2544                return myDifferential;
2545        }
2546
2547        /**
2548         * Sets the value(s) for <b>differential</b> ()
2549         *
2550     * <p>
2551     * <b>Definition:</b>
2552     * A differential view is expressed relative to the base StructureDefinition - a statement of differences that it applies
2553     * </p> 
2554         */
2555        public StructureDefinition setDifferential(Differential theValue) {
2556                myDifferential = theValue;
2557                return this;
2558        }
2559        
2560        
2561
2562  
2563        /**
2564         * Block class for child element: <b>StructureDefinition.contact</b> ()
2565         *
2566     * <p>
2567     * <b>Definition:</b>
2568     * Contacts to assist a user in finding and communicating with the publisher
2569     * </p> 
2570         */
2571        @Block()        
2572        public static class Contact 
2573            extends  BaseIdentifiableElement        implements IResourceBlock {
2574        
2575        @Child(name="name", type=StringDt.class, order=0, min=0, max=1, summary=true, modifier=false)   
2576        @Description(
2577                shortDefinition="",
2578                formalDefinition="The name of an individual to contact regarding the structure definition"
2579        )
2580        private StringDt myName;
2581        
2582        @Child(name="telecom", type=ContactPointDt.class, order=1, min=0, max=Child.MAX_UNLIMITED, summary=true, modifier=false)        
2583        @Description(
2584                shortDefinition="",
2585                formalDefinition="Contact details for individual (if a name was provided) or the publisher"
2586        )
2587        private java.util.List<ContactPointDt> myTelecom;
2588        
2589
2590        @Override
2591        public boolean isEmpty() {
2592                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myName,  myTelecom);
2593        }
2594        
2595        @Override
2596        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
2597                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myName, myTelecom);
2598        }
2599
2600        /**
2601         * Gets the value(s) for <b>name</b> ().
2602         * creating it if it does
2603         * not exist. Will not return <code>null</code>.
2604         *
2605     * <p>
2606     * <b>Definition:</b>
2607     * The name of an individual to contact regarding the structure definition
2608     * </p> 
2609         */
2610        public StringDt getNameElement() {  
2611                if (myName == null) {
2612                        myName = new StringDt();
2613                }
2614                return myName;
2615        }
2616
2617        
2618        /**
2619         * Gets the value(s) for <b>name</b> ().
2620         * creating it if it does
2621         * not exist. This method may return <code>null</code>.
2622         *
2623     * <p>
2624     * <b>Definition:</b>
2625     * The name of an individual to contact regarding the structure definition
2626     * </p> 
2627         */
2628        public String getName() {  
2629                return getNameElement().getValue();
2630        }
2631
2632        /**
2633         * Sets the value(s) for <b>name</b> ()
2634         *
2635     * <p>
2636     * <b>Definition:</b>
2637     * The name of an individual to contact regarding the structure definition
2638     * </p> 
2639         */
2640        public Contact setName(StringDt theValue) {
2641                myName = theValue;
2642                return this;
2643        }
2644        
2645        
2646
2647        /**
2648         * Sets the value for <b>name</b> ()
2649         *
2650     * <p>
2651     * <b>Definition:</b>
2652     * The name of an individual to contact regarding the structure definition
2653     * </p> 
2654         */
2655        public Contact setName( String theString) {
2656                myName = new StringDt(theString); 
2657                return this; 
2658        }
2659
2660 
2661        /**
2662         * Gets the value(s) for <b>telecom</b> ().
2663         * creating it if it does
2664         * not exist. Will not return <code>null</code>.
2665         *
2666     * <p>
2667     * <b>Definition:</b>
2668     * Contact details for individual (if a name was provided) or the publisher
2669     * </p> 
2670         */
2671        public java.util.List<ContactPointDt> getTelecom() {  
2672                if (myTelecom == null) {
2673                        myTelecom = new java.util.ArrayList<ContactPointDt>();
2674                }
2675                return myTelecom;
2676        }
2677
2678        /**
2679         * Sets the value(s) for <b>telecom</b> ()
2680         *
2681     * <p>
2682     * <b>Definition:</b>
2683     * Contact details for individual (if a name was provided) or the publisher
2684     * </p> 
2685         */
2686        public Contact setTelecom(java.util.List<ContactPointDt> theValue) {
2687                myTelecom = theValue;
2688                return this;
2689        }
2690        
2691        
2692
2693        /**
2694         * Adds and returns a new value for <b>telecom</b> ()
2695         *
2696     * <p>
2697     * <b>Definition:</b>
2698     * Contact details for individual (if a name was provided) or the publisher
2699     * </p> 
2700         */
2701        public ContactPointDt addTelecom() {
2702                ContactPointDt newType = new ContactPointDt();
2703                getTelecom().add(newType);
2704                return newType; 
2705        }
2706
2707        /**
2708         * Adds a given new value for <b>telecom</b> ()
2709         *
2710         * <p>
2711         * <b>Definition:</b>
2712         * Contact details for individual (if a name was provided) or the publisher
2713         * </p>
2714         * @param theValue The telecom to add (must not be <code>null</code>)
2715         */
2716        public Contact addTelecom(ContactPointDt theValue) {
2717                if (theValue == null) {
2718                        throw new NullPointerException("theValue must not be null");
2719                }
2720                getTelecom().add(theValue);
2721                return this;
2722        }
2723
2724        /**
2725         * Gets the first repetition for <b>telecom</b> (),
2726         * creating it if it does not already exist.
2727         *
2728     * <p>
2729     * <b>Definition:</b>
2730     * Contact details for individual (if a name was provided) or the publisher
2731     * </p> 
2732         */
2733        public ContactPointDt getTelecomFirstRep() {
2734                if (getTelecom().isEmpty()) {
2735                        return addTelecom();
2736                }
2737                return getTelecom().get(0); 
2738        }
2739  
2740
2741
2742        }
2743
2744
2745        /**
2746         * Block class for child element: <b>StructureDefinition.mapping</b> ()
2747         *
2748     * <p>
2749     * <b>Definition:</b>
2750     * An external specification that the content is mapped to
2751     * </p> 
2752         */
2753        @Block()        
2754        public static class Mapping 
2755            extends  BaseIdentifiableElement        implements IResourceBlock {
2756        
2757        @Child(name="identity", type=IdDt.class, order=0, min=1, max=1, summary=false, modifier=false)  
2758        @Description(
2759                shortDefinition="",
2760                formalDefinition="An Internal id that is used to identify this mapping set when specific mappings are made"
2761        )
2762        private IdDt myIdentity;
2763        
2764        @Child(name="uri", type=UriDt.class, order=1, min=0, max=1, summary=false, modifier=false)      
2765        @Description(
2766                shortDefinition="",
2767                formalDefinition="An absolute URI that identifies the specification that this mapping is expressed to"
2768        )
2769        private UriDt myUri;
2770        
2771        @Child(name="name", type=StringDt.class, order=2, min=0, max=1, summary=false, modifier=false)  
2772        @Description(
2773                shortDefinition="",
2774                formalDefinition="A name for the specification that is being mapped to"
2775        )
2776        private StringDt myName;
2777        
2778        @Child(name="comments", type=StringDt.class, order=3, min=0, max=1, summary=false, modifier=false)      
2779        @Description(
2780                shortDefinition="",
2781                formalDefinition="Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage"
2782        )
2783        private StringDt myComments;
2784        
2785
2786        @Override
2787        public boolean isEmpty() {
2788                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myIdentity,  myUri,  myName,  myComments);
2789        }
2790        
2791        @Override
2792        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
2793                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myIdentity, myUri, myName, myComments);
2794        }
2795
2796        /**
2797         * Gets the value(s) for <b>identity</b> ().
2798         * creating it if it does
2799         * not exist. Will not return <code>null</code>.
2800         *
2801     * <p>
2802     * <b>Definition:</b>
2803     * An Internal id that is used to identify this mapping set when specific mappings are made
2804     * </p> 
2805         */
2806        public IdDt getIdentityElement() {  
2807                if (myIdentity == null) {
2808                        myIdentity = new IdDt();
2809                }
2810                return myIdentity;
2811        }
2812
2813        
2814        /**
2815         * Gets the value(s) for <b>identity</b> ().
2816         * creating it if it does
2817         * not exist. This method may return <code>null</code>.
2818         *
2819     * <p>
2820     * <b>Definition:</b>
2821     * An Internal id that is used to identify this mapping set when specific mappings are made
2822     * </p> 
2823         */
2824        public String getIdentity() {  
2825                return getIdentityElement().getValue();
2826        }
2827
2828        /**
2829         * Sets the value(s) for <b>identity</b> ()
2830         *
2831     * <p>
2832     * <b>Definition:</b>
2833     * An Internal id that is used to identify this mapping set when specific mappings are made
2834     * </p> 
2835         */
2836        public Mapping setIdentity(IdDt theValue) {
2837                myIdentity = theValue;
2838                return this;
2839        }
2840        
2841        
2842
2843        /**
2844         * Sets the value for <b>identity</b> ()
2845         *
2846     * <p>
2847     * <b>Definition:</b>
2848     * An Internal id that is used to identify this mapping set when specific mappings are made
2849     * </p> 
2850         */
2851        public Mapping setIdentity( String theId) {
2852                myIdentity = new IdDt(theId); 
2853                return this; 
2854        }
2855
2856 
2857        /**
2858         * Gets the value(s) for <b>uri</b> ().
2859         * creating it if it does
2860         * not exist. Will not return <code>null</code>.
2861         *
2862     * <p>
2863     * <b>Definition:</b>
2864     * An absolute URI that identifies the specification that this mapping is expressed to
2865     * </p> 
2866         */
2867        public UriDt getUriElement() {  
2868                if (myUri == null) {
2869                        myUri = new UriDt();
2870                }
2871                return myUri;
2872        }
2873
2874        
2875        /**
2876         * Gets the value(s) for <b>uri</b> ().
2877         * creating it if it does
2878         * not exist. This method may return <code>null</code>.
2879         *
2880     * <p>
2881     * <b>Definition:</b>
2882     * An absolute URI that identifies the specification that this mapping is expressed to
2883     * </p> 
2884         */
2885        public String getUri() {  
2886                return getUriElement().getValue();
2887        }
2888
2889        /**
2890         * Sets the value(s) for <b>uri</b> ()
2891         *
2892     * <p>
2893     * <b>Definition:</b>
2894     * An absolute URI that identifies the specification that this mapping is expressed to
2895     * </p> 
2896         */
2897        public Mapping setUri(UriDt theValue) {
2898                myUri = theValue;
2899                return this;
2900        }
2901        
2902        
2903
2904        /**
2905         * Sets the value for <b>uri</b> ()
2906         *
2907     * <p>
2908     * <b>Definition:</b>
2909     * An absolute URI that identifies the specification that this mapping is expressed to
2910     * </p> 
2911         */
2912        public Mapping setUri( String theUri) {
2913                myUri = new UriDt(theUri); 
2914                return this; 
2915        }
2916
2917 
2918        /**
2919         * Gets the value(s) for <b>name</b> ().
2920         * creating it if it does
2921         * not exist. Will not return <code>null</code>.
2922         *
2923     * <p>
2924     * <b>Definition:</b>
2925     * A name for the specification that is being mapped to
2926     * </p> 
2927         */
2928        public StringDt getNameElement() {  
2929                if (myName == null) {
2930                        myName = new StringDt();
2931                }
2932                return myName;
2933        }
2934
2935        
2936        /**
2937         * Gets the value(s) for <b>name</b> ().
2938         * creating it if it does
2939         * not exist. This method may return <code>null</code>.
2940         *
2941     * <p>
2942     * <b>Definition:</b>
2943     * A name for the specification that is being mapped to
2944     * </p> 
2945         */
2946        public String getName() {  
2947                return getNameElement().getValue();
2948        }
2949
2950        /**
2951         * Sets the value(s) for <b>name</b> ()
2952         *
2953     * <p>
2954     * <b>Definition:</b>
2955     * A name for the specification that is being mapped to
2956     * </p> 
2957         */
2958        public Mapping setName(StringDt theValue) {
2959                myName = theValue;
2960                return this;
2961        }
2962        
2963        
2964
2965        /**
2966         * Sets the value for <b>name</b> ()
2967         *
2968     * <p>
2969     * <b>Definition:</b>
2970     * A name for the specification that is being mapped to
2971     * </p> 
2972         */
2973        public Mapping setName( String theString) {
2974                myName = new StringDt(theString); 
2975                return this; 
2976        }
2977
2978 
2979        /**
2980         * Gets the value(s) for <b>comments</b> ().
2981         * creating it if it does
2982         * not exist. Will not return <code>null</code>.
2983         *
2984     * <p>
2985     * <b>Definition:</b>
2986     * Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage
2987     * </p> 
2988         */
2989        public StringDt getCommentsElement() {  
2990                if (myComments == null) {
2991                        myComments = new StringDt();
2992                }
2993                return myComments;
2994        }
2995
2996        
2997        /**
2998         * Gets the value(s) for <b>comments</b> ().
2999         * creating it if it does
3000         * not exist. This method may return <code>null</code>.
3001         *
3002     * <p>
3003     * <b>Definition:</b>
3004     * Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage
3005     * </p> 
3006         */
3007        public String getComments() {  
3008                return getCommentsElement().getValue();
3009        }
3010
3011        /**
3012         * Sets the value(s) for <b>comments</b> ()
3013         *
3014     * <p>
3015     * <b>Definition:</b>
3016     * Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage
3017     * </p> 
3018         */
3019        public Mapping setComments(StringDt theValue) {
3020                myComments = theValue;
3021                return this;
3022        }
3023        
3024        
3025
3026        /**
3027         * Sets the value for <b>comments</b> ()
3028         *
3029     * <p>
3030     * <b>Definition:</b>
3031     * Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage
3032     * </p> 
3033         */
3034        public Mapping setComments( String theString) {
3035                myComments = new StringDt(theString); 
3036                return this; 
3037        }
3038
3039 
3040
3041
3042        }
3043
3044
3045        /**
3046         * Block class for child element: <b>StructureDefinition.snapshot</b> ()
3047         *
3048     * <p>
3049     * <b>Definition:</b>
3050     * A snapshot view is expressed in a stand alone form that can be used and interpreted without considering the base StructureDefinition
3051     * </p> 
3052         */
3053        @Block()        
3054        public static class Snapshot 
3055            extends  BaseIdentifiableElement        implements IResourceBlock {
3056        
3057        @Child(name="element", type=ElementDefinitionDt.class, order=0, min=1, max=Child.MAX_UNLIMITED, summary=false, modifier=false)  
3058        @Description(
3059                shortDefinition="",
3060                formalDefinition="Captures constraints on each element within the resource"
3061        )
3062        private java.util.List<ElementDefinitionDt> myElement;
3063        
3064
3065        @Override
3066        public boolean isEmpty() {
3067                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myElement);
3068        }
3069        
3070        @Override
3071        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
3072                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myElement);
3073        }
3074
3075        /**
3076         * Gets the value(s) for <b>element</b> ().
3077         * creating it if it does
3078         * not exist. Will not return <code>null</code>.
3079         *
3080     * <p>
3081     * <b>Definition:</b>
3082     * Captures constraints on each element within the resource
3083     * </p> 
3084         */
3085        public java.util.List<ElementDefinitionDt> getElement() {  
3086                if (myElement == null) {
3087                        myElement = new java.util.ArrayList<ElementDefinitionDt>();
3088                }
3089                return myElement;
3090        }
3091
3092        /**
3093         * Sets the value(s) for <b>element</b> ()
3094         *
3095     * <p>
3096     * <b>Definition:</b>
3097     * Captures constraints on each element within the resource
3098     * </p> 
3099         */
3100        public Snapshot setElement(java.util.List<ElementDefinitionDt> theValue) {
3101                myElement = theValue;
3102                return this;
3103        }
3104        
3105        
3106
3107        /**
3108         * Adds and returns a new value for <b>element</b> ()
3109         *
3110     * <p>
3111     * <b>Definition:</b>
3112     * Captures constraints on each element within the resource
3113     * </p> 
3114         */
3115        public ElementDefinitionDt addElement() {
3116                ElementDefinitionDt newType = new ElementDefinitionDt();
3117                getElement().add(newType);
3118                return newType; 
3119        }
3120
3121        /**
3122         * Adds a given new value for <b>element</b> ()
3123         *
3124         * <p>
3125         * <b>Definition:</b>
3126         * Captures constraints on each element within the resource
3127         * </p>
3128         * @param theValue The element to add (must not be <code>null</code>)
3129         */
3130        public Snapshot addElement(ElementDefinitionDt theValue) {
3131                if (theValue == null) {
3132                        throw new NullPointerException("theValue must not be null");
3133                }
3134                getElement().add(theValue);
3135                return this;
3136        }
3137
3138        /**
3139         * Gets the first repetition for <b>element</b> (),
3140         * creating it if it does not already exist.
3141         *
3142     * <p>
3143     * <b>Definition:</b>
3144     * Captures constraints on each element within the resource
3145     * </p> 
3146         */
3147        public ElementDefinitionDt getElementFirstRep() {
3148                if (getElement().isEmpty()) {
3149                        return addElement();
3150                }
3151                return getElement().get(0); 
3152        }
3153  
3154
3155
3156        }
3157
3158
3159        /**
3160         * Block class for child element: <b>StructureDefinition.differential</b> ()
3161         *
3162     * <p>
3163     * <b>Definition:</b>
3164     * A differential view is expressed relative to the base StructureDefinition - a statement of differences that it applies
3165     * </p> 
3166         */
3167        @Block()        
3168        public static class Differential 
3169            extends  BaseIdentifiableElement        implements IResourceBlock {
3170        
3171        @Child(name="element", type=ElementDefinitionDt.class, order=0, min=1, max=Child.MAX_UNLIMITED, summary=false, modifier=false)  
3172        @Description(
3173                shortDefinition="",
3174                formalDefinition="Captures constraints on each element within the resource"
3175        )
3176        private java.util.List<ElementDefinitionDt> myElement;
3177        
3178
3179        @Override
3180        public boolean isEmpty() {
3181                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myElement);
3182        }
3183        
3184        @Override
3185        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
3186                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myElement);
3187        }
3188
3189        /**
3190         * Gets the value(s) for <b>element</b> ().
3191         * creating it if it does
3192         * not exist. Will not return <code>null</code>.
3193         *
3194     * <p>
3195     * <b>Definition:</b>
3196     * Captures constraints on each element within the resource
3197     * </p> 
3198         */
3199        public java.util.List<ElementDefinitionDt> getElement() {  
3200                if (myElement == null) {
3201                        myElement = new java.util.ArrayList<ElementDefinitionDt>();
3202                }
3203                return myElement;
3204        }
3205
3206        /**
3207         * Sets the value(s) for <b>element</b> ()
3208         *
3209     * <p>
3210     * <b>Definition:</b>
3211     * Captures constraints on each element within the resource
3212     * </p> 
3213         */
3214        public Differential setElement(java.util.List<ElementDefinitionDt> theValue) {
3215                myElement = theValue;
3216                return this;
3217        }
3218        
3219        
3220
3221        /**
3222         * Adds and returns a new value for <b>element</b> ()
3223         *
3224     * <p>
3225     * <b>Definition:</b>
3226     * Captures constraints on each element within the resource
3227     * </p> 
3228         */
3229        public ElementDefinitionDt addElement() {
3230                ElementDefinitionDt newType = new ElementDefinitionDt();
3231                getElement().add(newType);
3232                return newType; 
3233        }
3234
3235        /**
3236         * Adds a given new value for <b>element</b> ()
3237         *
3238         * <p>
3239         * <b>Definition:</b>
3240         * Captures constraints on each element within the resource
3241         * </p>
3242         * @param theValue The element to add (must not be <code>null</code>)
3243         */
3244        public Differential addElement(ElementDefinitionDt theValue) {
3245                if (theValue == null) {
3246                        throw new NullPointerException("theValue must not be null");
3247                }
3248                getElement().add(theValue);
3249                return this;
3250        }
3251
3252        /**
3253         * Gets the first repetition for <b>element</b> (),
3254         * creating it if it does not already exist.
3255         *
3256     * <p>
3257     * <b>Definition:</b>
3258     * Captures constraints on each element within the resource
3259     * </p> 
3260         */
3261        public ElementDefinitionDt getElementFirstRep() {
3262                if (getElement().isEmpty()) {
3263                        return addElement();
3264                }
3265                return getElement().get(0); 
3266        }
3267  
3268
3269
3270        }
3271
3272
3273
3274
3275    @Override
3276    public String getResourceName() {
3277        return "StructureDefinition";
3278    }
3279    
3280    public ca.uhn.fhir.context.FhirVersionEnum getStructureFhirVersionEnum() {
3281        return ca.uhn.fhir.context.FhirVersionEnum.DSTU2;
3282    }
3283
3284
3285}