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.valueset.AnimalSpeciesEnum;
042import ca.uhn.fhir.model.dstu2.composite.AnnotationDt;
043import ca.uhn.fhir.model.dstu2.valueset.AnswerFormatEnum;
044import ca.uhn.fhir.model.dstu2.resource.Appointment;
045import ca.uhn.fhir.model.dstu2.valueset.AppointmentStatusEnum;
046import ca.uhn.fhir.model.dstu2.valueset.AssertionDirectionTypeEnum;
047import ca.uhn.fhir.model.dstu2.valueset.AssertionOperatorTypeEnum;
048import ca.uhn.fhir.model.dstu2.valueset.AssertionResponseTypesEnum;
049import ca.uhn.fhir.model.dstu2.composite.AttachmentDt;
050import ca.uhn.fhir.model.dstu2.valueset.AuditEventActionEnum;
051import ca.uhn.fhir.model.dstu2.valueset.AuditEventObjectLifecycleEnum;
052import ca.uhn.fhir.model.dstu2.valueset.AuditEventObjectRoleEnum;
053import ca.uhn.fhir.model.dstu2.valueset.AuditEventObjectTypeEnum;
054import ca.uhn.fhir.model.dstu2.valueset.AuditEventOutcomeEnum;
055import ca.uhn.fhir.model.dstu2.valueset.AuditEventParticipantNetworkTypeEnum;
056import ca.uhn.fhir.model.dstu2.valueset.AuditEventSourceTypeEnum;
057import ca.uhn.fhir.model.dstu2.valueset.BindingStrengthEnum;
058import ca.uhn.fhir.model.dstu2.resource.BodySite;
059import ca.uhn.fhir.model.dstu2.valueset.BundleTypeEnum;
060import ca.uhn.fhir.model.dstu2.resource.CarePlan;
061import ca.uhn.fhir.model.dstu2.valueset.CarePlanActivityCategoryEnum;
062import ca.uhn.fhir.model.dstu2.valueset.CarePlanActivityStatusEnum;
063import ca.uhn.fhir.model.dstu2.valueset.CarePlanRelationshipEnum;
064import ca.uhn.fhir.model.dstu2.valueset.CarePlanStatusEnum;
065import ca.uhn.fhir.model.dstu2.resource.Claim;
066import ca.uhn.fhir.model.dstu2.resource.ClaimResponse;
067import ca.uhn.fhir.model.dstu2.valueset.ClaimTypeEnum;
068import ca.uhn.fhir.model.dstu2.resource.ClinicalImpression;
069import ca.uhn.fhir.model.dstu2.valueset.ClinicalImpressionStatusEnum;
070import ca.uhn.fhir.model.dstu2.composite.CodeableConceptDt;
071import ca.uhn.fhir.model.dstu2.composite.CodingDt;
072import ca.uhn.fhir.model.dstu2.resource.CommunicationRequest;
073import ca.uhn.fhir.model.dstu2.valueset.CommunicationRequestStatusEnum;
074import ca.uhn.fhir.model.dstu2.valueset.CommunicationStatusEnum;
075import ca.uhn.fhir.model.dstu2.resource.Composition;
076import ca.uhn.fhir.model.dstu2.valueset.CompositionAttestationModeEnum;
077import ca.uhn.fhir.model.dstu2.valueset.CompositionStatusEnum;
078import ca.uhn.fhir.model.dstu2.valueset.ConceptMapEquivalenceEnum;
079import ca.uhn.fhir.model.dstu2.resource.Condition;
080import ca.uhn.fhir.model.dstu2.valueset.ConditionCategoryCodesEnum;
081import ca.uhn.fhir.model.dstu2.valueset.ConditionClinicalStatusCodesEnum;
082import ca.uhn.fhir.model.dstu2.valueset.ConditionVerificationStatusEnum;
083import ca.uhn.fhir.model.dstu2.valueset.ConditionalDeleteStatusEnum;
084import ca.uhn.fhir.model.dstu2.valueset.ConditionsCodesEnum;
085import ca.uhn.fhir.model.dstu2.resource.Conformance;
086import ca.uhn.fhir.model.dstu2.valueset.ConformanceEventModeEnum;
087import ca.uhn.fhir.model.dstu2.valueset.ConformanceResourceStatusEnum;
088import ca.uhn.fhir.model.dstu2.valueset.ConformanceStatementKindEnum;
089import ca.uhn.fhir.model.dstu2.composite.ContactPointDt;
090import ca.uhn.fhir.model.dstu2.valueset.ContentTypeEnum;
091import ca.uhn.fhir.model.dstu2.resource.Contract;
092import ca.uhn.fhir.model.dstu2.valueset.ContractActionCodesEnum;
093import ca.uhn.fhir.model.dstu2.valueset.ContractActorRoleCodesEnum;
094import ca.uhn.fhir.model.dstu2.valueset.ContractSubtypeCodesEnum;
095import ca.uhn.fhir.model.dstu2.valueset.ContractTermTypeCodesEnum;
096import ca.uhn.fhir.model.dstu2.valueset.ContractTypeCodesEnum;
097import ca.uhn.fhir.model.dstu2.resource.Coverage;
098import ca.uhn.fhir.model.dstu2.valueset.DataElementStringencyEnum;
099import ca.uhn.fhir.model.dstu2.valueset.DaysOfWeekEnum;
100import ca.uhn.fhir.model.dstu2.valueset.DetectedIssueSeverityEnum;
101import ca.uhn.fhir.model.dstu2.resource.Device;
102import ca.uhn.fhir.model.dstu2.resource.DeviceComponent;
103import ca.uhn.fhir.model.dstu2.resource.DeviceMetric;
104import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricCalibrationStateEnum;
105import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricCalibrationTypeEnum;
106import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricCategoryEnum;
107import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricColorEnum;
108import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricOperationalStatusEnum;
109import ca.uhn.fhir.model.dstu2.valueset.DeviceStatusEnum;
110import ca.uhn.fhir.model.dstu2.resource.DeviceUseRequest;
111import ca.uhn.fhir.model.dstu2.valueset.DeviceUseRequestPriorityEnum;
112import ca.uhn.fhir.model.dstu2.valueset.DeviceUseRequestStatusEnum;
113import ca.uhn.fhir.model.dstu2.resource.DiagnosticOrder;
114import ca.uhn.fhir.model.dstu2.valueset.DiagnosticOrderPriorityEnum;
115import ca.uhn.fhir.model.dstu2.valueset.DiagnosticOrderStatusEnum;
116import ca.uhn.fhir.model.dstu2.resource.DiagnosticReport;
117import ca.uhn.fhir.model.dstu2.valueset.DiagnosticReportStatusEnum;
118import ca.uhn.fhir.model.dstu2.valueset.DigitalMediaTypeEnum;
119import ca.uhn.fhir.model.dstu2.valueset.DocumentModeEnum;
120import ca.uhn.fhir.model.dstu2.resource.DocumentReference;
121import ca.uhn.fhir.model.dstu2.valueset.DocumentReferenceStatusEnum;
122import ca.uhn.fhir.model.dstu2.valueset.DocumentRelationshipTypeEnum;
123import ca.uhn.fhir.model.dstu2.composite.ElementDefinitionDt;
124import ca.uhn.fhir.model.dstu2.resource.EligibilityRequest;
125import ca.uhn.fhir.model.dstu2.resource.Encounter;
126import ca.uhn.fhir.model.dstu2.valueset.EncounterClassEnum;
127import ca.uhn.fhir.model.dstu2.valueset.EncounterLocationStatusEnum;
128import ca.uhn.fhir.model.dstu2.valueset.EncounterStateEnum;
129import ca.uhn.fhir.model.dstu2.valueset.EncounterTypeEnum;
130import ca.uhn.fhir.model.dstu2.resource.EnrollmentRequest;
131import ca.uhn.fhir.model.dstu2.valueset.EnteralFormulaTypeCodesEnum;
132import ca.uhn.fhir.model.dstu2.resource.EpisodeOfCare;
133import ca.uhn.fhir.model.dstu2.valueset.EpisodeOfCareStatusEnum;
134import ca.uhn.fhir.model.dstu2.valueset.ExceptionCodesEnum;
135import ca.uhn.fhir.model.dstu2.valueset.ExtensionContextEnum;
136import ca.uhn.fhir.model.dstu2.valueset.FamilyHistoryStatusEnum;
137import ca.uhn.fhir.model.dstu2.resource.FamilyMemberHistory;
138import ca.uhn.fhir.model.dstu2.valueset.FilterOperatorEnum;
139import ca.uhn.fhir.model.dstu2.valueset.FlagCategoryCodesEnum;
140import ca.uhn.fhir.model.dstu2.valueset.FlagStatusEnum;
141import ca.uhn.fhir.model.dstu2.valueset.FluidConsistencyTypeCodesEnum;
142import ca.uhn.fhir.model.dstu2.resource.Goal;
143import ca.uhn.fhir.model.dstu2.valueset.GoalCategoryEnum;
144import ca.uhn.fhir.model.dstu2.valueset.GoalPriorityEnum;
145import ca.uhn.fhir.model.dstu2.valueset.GoalStartEventEnum;
146import ca.uhn.fhir.model.dstu2.valueset.GoalStatusEnum;
147import ca.uhn.fhir.model.dstu2.valueset.GoalStatusReasonEnum;
148import ca.uhn.fhir.model.dstu2.resource.Group;
149import ca.uhn.fhir.model.dstu2.valueset.GroupTypeEnum;
150import ca.uhn.fhir.model.dstu2.valueset.GuideDependencyTypeEnum;
151import ca.uhn.fhir.model.dstu2.valueset.GuidePageKindEnum;
152import ca.uhn.fhir.model.dstu2.valueset.GuideResourcePurposeEnum;
153import ca.uhn.fhir.model.dstu2.valueset.HTTPVerbEnum;
154import ca.uhn.fhir.model.dstu2.resource.HealthcareService;
155import ca.uhn.fhir.model.dstu2.composite.HumanNameDt;
156import ca.uhn.fhir.model.dstu2.composite.IdentifierDt;
157import ca.uhn.fhir.model.dstu2.valueset.IdentifierTypeCodesEnum;
158import ca.uhn.fhir.model.dstu2.valueset.IdentityAssuranceLevelEnum;
159import ca.uhn.fhir.model.dstu2.resource.ImagingObjectSelection;
160import ca.uhn.fhir.model.dstu2.resource.ImagingStudy;
161import ca.uhn.fhir.model.dstu2.resource.Immunization;
162import ca.uhn.fhir.model.dstu2.valueset.ImmunizationReasonCodesEnum;
163import ca.uhn.fhir.model.dstu2.valueset.ImmunizationRecommendationDateCriterionCodesEnum;
164import ca.uhn.fhir.model.dstu2.valueset.ImmunizationRecommendationStatusCodesEnum;
165import ca.uhn.fhir.model.dstu2.valueset.ImmunizationRouteCodesEnum;
166import ca.uhn.fhir.model.dstu2.valueset.InstanceAvailabilityEnum;
167import ca.uhn.fhir.model.dstu2.valueset.InterventionCodesEnum;
168import ca.uhn.fhir.model.dstu2.valueset.IssueSeverityEnum;
169import ca.uhn.fhir.model.dstu2.valueset.IssueTypeEnum;
170import ca.uhn.fhir.model.dstu2.valueset.KOStitleEnum;
171import ca.uhn.fhir.model.dstu2.valueset.LateralityEnum;
172import ca.uhn.fhir.model.dstu2.valueset.LinkTypeEnum;
173import ca.uhn.fhir.model.dstu2.valueset.ListModeEnum;
174import ca.uhn.fhir.model.dstu2.valueset.ListOrderCodesEnum;
175import ca.uhn.fhir.model.dstu2.valueset.ListStatusEnum;
176import ca.uhn.fhir.model.dstu2.resource.Location;
177import ca.uhn.fhir.model.dstu2.valueset.LocationModeEnum;
178import ca.uhn.fhir.model.dstu2.valueset.LocationStatusEnum;
179import ca.uhn.fhir.model.dstu2.valueset.LocationTypeEnum;
180import ca.uhn.fhir.model.dstu2.valueset.MaritalStatusCodesEnum;
181import ca.uhn.fhir.model.dstu2.valueset.MeasmntPrincipleEnum;
182import ca.uhn.fhir.model.dstu2.resource.Media;
183import ca.uhn.fhir.model.dstu2.resource.Medication;
184import ca.uhn.fhir.model.dstu2.valueset.MedicationAdministrationStatusEnum;
185import ca.uhn.fhir.model.dstu2.valueset.MedicationDispenseStatusEnum;
186import ca.uhn.fhir.model.dstu2.resource.MedicationOrder;
187import ca.uhn.fhir.model.dstu2.valueset.MedicationOrderStatusEnum;
188import ca.uhn.fhir.model.dstu2.resource.MedicationStatement;
189import ca.uhn.fhir.model.dstu2.valueset.MedicationStatementStatusEnum;
190import ca.uhn.fhir.model.dstu2.valueset.MessageEventEnum;
191import ca.uhn.fhir.model.dstu2.valueset.MessageSignificanceCategoryEnum;
192import ca.uhn.fhir.model.dstu2.valueset.MessageTransportEnum;
193import ca.uhn.fhir.model.dstu2.resource.NamingSystem;
194import ca.uhn.fhir.model.dstu2.valueset.NamingSystemIdentifierTypeEnum;
195import ca.uhn.fhir.model.dstu2.valueset.NamingSystemTypeEnum;
196import ca.uhn.fhir.model.dstu2.valueset.NoteTypeEnum;
197import ca.uhn.fhir.model.dstu2.valueset.NutrientModifierCodesEnum;
198import ca.uhn.fhir.model.dstu2.resource.NutritionOrder;
199import ca.uhn.fhir.model.dstu2.valueset.NutritionOrderStatusEnum;
200import ca.uhn.fhir.model.dstu2.resource.Observation;
201import ca.uhn.fhir.model.dstu2.valueset.ObservationCategoryCodesEnum;
202import ca.uhn.fhir.model.dstu2.valueset.ObservationRelationshipTypeEnum;
203import ca.uhn.fhir.model.dstu2.valueset.ObservationStatusEnum;
204import ca.uhn.fhir.model.dstu2.resource.OperationDefinition;
205import ca.uhn.fhir.model.dstu2.valueset.OperationKindEnum;
206import ca.uhn.fhir.model.dstu2.resource.OperationOutcome;
207import ca.uhn.fhir.model.dstu2.valueset.OperationParameterUseEnum;
208import ca.uhn.fhir.model.dstu2.resource.Order;
209import ca.uhn.fhir.model.dstu2.valueset.OrderStatusEnum;
210import ca.uhn.fhir.model.dstu2.resource.Organization;
211import ca.uhn.fhir.model.dstu2.valueset.OrganizationTypeEnum;
212import ca.uhn.fhir.model.dstu2.valueset.ParticipantRequiredEnum;
213import ca.uhn.fhir.model.dstu2.valueset.ParticipantStatusEnum;
214import ca.uhn.fhir.model.dstu2.valueset.ParticipantTypeEnum;
215import ca.uhn.fhir.model.dstu2.valueset.ParticipationStatusEnum;
216import ca.uhn.fhir.model.dstu2.resource.Patient;
217import ca.uhn.fhir.model.dstu2.valueset.PayeeTypeCodesEnum;
218import ca.uhn.fhir.model.dstu2.valueset.PaymentStatusCodesEnum;
219import ca.uhn.fhir.model.dstu2.valueset.PaymentTypeCodesEnum;
220import ca.uhn.fhir.model.dstu2.composite.PeriodDt;
221import ca.uhn.fhir.model.dstu2.resource.Person;
222import ca.uhn.fhir.model.dstu2.resource.Practitioner;
223import ca.uhn.fhir.model.dstu2.valueset.PractitionerRoleEnum;
224import ca.uhn.fhir.model.dstu2.valueset.PractitionerSpecialtyEnum;
225import ca.uhn.fhir.model.dstu2.valueset.PriorityCodesEnum;
226import ca.uhn.fhir.model.dstu2.resource.Procedure;
227import ca.uhn.fhir.model.dstu2.resource.ProcedureRequest;
228import ca.uhn.fhir.model.dstu2.valueset.ProcedureRequestPriorityEnum;
229import ca.uhn.fhir.model.dstu2.valueset.ProcedureRequestStatusEnum;
230import ca.uhn.fhir.model.dstu2.valueset.ProcedureStatusEnum;
231import ca.uhn.fhir.model.dstu2.resource.ProcessRequest;
232import ca.uhn.fhir.model.dstu2.valueset.ProvenanceEntityRoleEnum;
233import ca.uhn.fhir.model.dstu2.composite.QuantityDt;
234import ca.uhn.fhir.model.dstu2.resource.Questionnaire;
235import ca.uhn.fhir.model.dstu2.resource.QuestionnaireResponse;
236import ca.uhn.fhir.model.dstu2.valueset.QuestionnaireResponseStatusEnum;
237import ca.uhn.fhir.model.dstu2.valueset.QuestionnaireStatusEnum;
238import ca.uhn.fhir.model.dstu2.composite.RangeDt;
239import ca.uhn.fhir.model.dstu2.composite.RatioDt;
240import ca.uhn.fhir.model.dstu2.valueset.ReferralMethodEnum;
241import ca.uhn.fhir.model.dstu2.resource.ReferralRequest;
242import ca.uhn.fhir.model.dstu2.valueset.ReferralStatusEnum;
243import ca.uhn.fhir.model.dstu2.resource.RelatedPerson;
244import ca.uhn.fhir.model.dstu2.valueset.RemittanceOutcomeEnum;
245import ca.uhn.fhir.model.dstu2.valueset.ResourceTypeEnum;
246import ca.uhn.fhir.model.dstu2.valueset.ResourceVersionPolicyEnum;
247import ca.uhn.fhir.model.dstu2.valueset.ResponseTypeEnum;
248import ca.uhn.fhir.model.dstu2.valueset.RestfulConformanceModeEnum;
249import ca.uhn.fhir.model.dstu2.valueset.RestfulSecurityServiceEnum;
250import ca.uhn.fhir.model.dstu2.resource.RiskAssessment;
251import ca.uhn.fhir.model.dstu2.valueset.RulesetCodesEnum;
252import ca.uhn.fhir.model.dstu2.composite.SampledDataDt;
253import ca.uhn.fhir.model.dstu2.resource.Schedule;
254import ca.uhn.fhir.model.dstu2.valueset.SearchEntryModeEnum;
255import ca.uhn.fhir.model.dstu2.valueset.SearchModifierCodeEnum;
256import ca.uhn.fhir.model.dstu2.valueset.SearchParamTypeEnum;
257import ca.uhn.fhir.model.dstu2.valueset.ServiceProvisionConditionsEnum;
258import ca.uhn.fhir.model.dstu2.composite.SignatureDt;
259import ca.uhn.fhir.model.dstu2.resource.Slot;
260import ca.uhn.fhir.model.dstu2.valueset.SlotStatusEnum;
261import ca.uhn.fhir.model.dstu2.resource.Specimen;
262import ca.uhn.fhir.model.dstu2.valueset.SpecimenCollectionMethodEnum;
263import ca.uhn.fhir.model.dstu2.valueset.SpecimenStatusEnum;
264import ca.uhn.fhir.model.dstu2.resource.StructureDefinition;
265import ca.uhn.fhir.model.dstu2.valueset.StructureDefinitionKindEnum;
266import ca.uhn.fhir.model.dstu2.valueset.SubscriptionChannelTypeEnum;
267import ca.uhn.fhir.model.dstu2.valueset.SubscriptionStatusEnum;
268import ca.uhn.fhir.model.dstu2.valueset.SubscriptionTagEnum;
269import ca.uhn.fhir.model.dstu2.resource.Substance;
270import ca.uhn.fhir.model.dstu2.valueset.SubstanceCategoryCodesEnum;
271import ca.uhn.fhir.model.dstu2.valueset.SupplementTypeCodesEnum;
272import ca.uhn.fhir.model.dstu2.valueset.SupplyDeliveryStatusEnum;
273import ca.uhn.fhir.model.dstu2.resource.SupplyRequest;
274import ca.uhn.fhir.model.dstu2.valueset.SupplyRequestReasonEnum;
275import ca.uhn.fhir.model.dstu2.valueset.SupplyRequestStatusEnum;
276import ca.uhn.fhir.model.dstu2.valueset.SurfaceCodesEnum;
277import ca.uhn.fhir.model.dstu2.valueset.SystemRestfulInteractionEnum;
278import ca.uhn.fhir.model.api.TemporalPrecisionEnum;
279import ca.uhn.fhir.model.dstu2.valueset.TextureModifiedFoodTypeCodesEnum;
280import ca.uhn.fhir.model.dstu2.valueset.TextureModifierCodesEnum;
281import ca.uhn.fhir.model.dstu2.composite.TimingDt;
282import ca.uhn.fhir.model.dstu2.valueset.TransactionModeEnum;
283import ca.uhn.fhir.model.dstu2.valueset.TypeRestfulInteractionEnum;
284import ca.uhn.fhir.model.dstu2.valueset.UDICodesEnum;
285import ca.uhn.fhir.model.dstu2.valueset.UnknownContentCodeEnum;
286import ca.uhn.fhir.model.dstu2.valueset.UseEnum;
287import ca.uhn.fhir.model.dstu2.resource.ValueSet;
288import ca.uhn.fhir.model.dstu2.valueset.VisionBaseEnum;
289import ca.uhn.fhir.model.dstu2.valueset.VisionEyesEnum;
290import ca.uhn.fhir.model.dstu2.resource.VisionPrescription;
291import ca.uhn.fhir.model.dstu2.valueset.XPathUsageTypeEnum;
292import ca.uhn.fhir.model.api.IResource;
293import ca.uhn.fhir.model.dstu2.composite.AgeDt;
294import ca.uhn.fhir.model.dstu2.composite.BoundCodeableConceptDt;
295import ca.uhn.fhir.model.dstu2.composite.DurationDt;
296import ca.uhn.fhir.model.dstu2.composite.MoneyDt;
297import ca.uhn.fhir.model.dstu2.composite.NarrativeDt;
298import ca.uhn.fhir.model.dstu2.composite.ResourceReferenceDt;
299import ca.uhn.fhir.model.dstu2.composite.SimpleQuantityDt;
300import ca.uhn.fhir.model.primitive.Base64BinaryDt;
301import ca.uhn.fhir.model.primitive.BooleanDt;
302import ca.uhn.fhir.model.primitive.BoundCodeDt;
303import ca.uhn.fhir.model.primitive.CodeDt;
304import ca.uhn.fhir.model.primitive.DateDt;
305import ca.uhn.fhir.model.primitive.DateTimeDt;
306import ca.uhn.fhir.model.primitive.DecimalDt;
307import ca.uhn.fhir.model.primitive.IdDt;
308import ca.uhn.fhir.model.primitive.InstantDt;
309import ca.uhn.fhir.model.primitive.IntegerDt;
310import ca.uhn.fhir.model.primitive.OidDt;
311import ca.uhn.fhir.model.primitive.PositiveIntDt;
312import ca.uhn.fhir.model.primitive.StringDt;
313import ca.uhn.fhir.model.primitive.TimeDt;
314import ca.uhn.fhir.model.primitive.UnsignedIntDt;
315import ca.uhn.fhir.model.primitive.UriDt;
316
317
318/**
319 * HAPI/FHIR <b>Conformance</b> Resource
320 * ()
321 *
322 * <p>
323 * <b>Definition:</b>
324 * A conformance statement is a set of capabilities of a FHIR Server that may be used as a statement of actual server functionality or a statement of required or desired server implementation.
325 * </p> 
326 *
327 * <p>
328 * <b>Requirements:</b>
329 * 
330 * </p> 
331 *
332 * <p>
333 * <b>Profile Definition:</b>
334 * <a href="http://hl7.org/fhir/profiles/Conformance">http://hl7.org/fhir/profiles/Conformance</a> 
335 * </p>
336 *
337 */
338@ResourceDef(name="Conformance", profile="http://hl7.org/fhir/profiles/Conformance", id="conformance")
339public class Conformance extends ca.uhn.fhir.model.dstu2.resource.BaseResource
340    implements  ca.uhn.fhir.model.base.resource.BaseConformance     {
341
342        /**
343         * Search parameter constant for <b>url</b>
344         * <p>
345         * Description: <b>The uri that identifies the conformance statement</b><br>
346         * Type: <b>uri</b><br>
347         * Path: <b>Conformance.url</b><br>
348         * </p>
349         */
350        @SearchParamDefinition(name="url", path="Conformance.url", description="The uri that identifies the conformance statement", type="uri"  )
351        public static final String SP_URL = "url";
352
353        /**
354         * <b>Fluent Client</b> search parameter constant for <b>url</b>
355         * <p>
356         * Description: <b>The uri that identifies the conformance statement</b><br>
357         * Type: <b>uri</b><br>
358         * Path: <b>Conformance.url</b><br>
359         * </p>
360         */
361        public static final UriClientParam URL = new UriClientParam(SP_URL);
362
363        /**
364         * Search parameter constant for <b>version</b>
365         * <p>
366         * Description: <b>The version identifier of the conformance statement</b><br>
367         * Type: <b>token</b><br>
368         * Path: <b>Conformance.version</b><br>
369         * </p>
370         */
371        @SearchParamDefinition(name="version", path="Conformance.version", description="The version identifier of the conformance statement", type="token"  )
372        public static final String SP_VERSION = "version";
373
374        /**
375         * <b>Fluent Client</b> search parameter constant for <b>version</b>
376         * <p>
377         * Description: <b>The version identifier of the conformance statement</b><br>
378         * Type: <b>token</b><br>
379         * Path: <b>Conformance.version</b><br>
380         * </p>
381         */
382        public static final TokenClientParam VERSION = new TokenClientParam(SP_VERSION);
383
384        /**
385         * Search parameter constant for <b>name</b>
386         * <p>
387         * Description: <b>Name of the conformance statement</b><br>
388         * Type: <b>string</b><br>
389         * Path: <b>Conformance.name</b><br>
390         * </p>
391         */
392        @SearchParamDefinition(name="name", path="Conformance.name", description="Name of the conformance statement", type="string"  )
393        public static final String SP_NAME = "name";
394
395        /**
396         * <b>Fluent Client</b> search parameter constant for <b>name</b>
397         * <p>
398         * Description: <b>Name of the conformance statement</b><br>
399         * Type: <b>string</b><br>
400         * Path: <b>Conformance.name</b><br>
401         * </p>
402         */
403        public static final StringClientParam NAME = new StringClientParam(SP_NAME);
404
405        /**
406         * Search parameter constant for <b>publisher</b>
407         * <p>
408         * Description: <b>Name of the publisher of the conformance statement</b><br>
409         * Type: <b>string</b><br>
410         * Path: <b>Conformance.publisher</b><br>
411         * </p>
412         */
413        @SearchParamDefinition(name="publisher", path="Conformance.publisher", description="Name of the publisher of the conformance statement", type="string"  )
414        public static final String SP_PUBLISHER = "publisher";
415
416        /**
417         * <b>Fluent Client</b> search parameter constant for <b>publisher</b>
418         * <p>
419         * Description: <b>Name of the publisher of the conformance statement</b><br>
420         * Type: <b>string</b><br>
421         * Path: <b>Conformance.publisher</b><br>
422         * </p>
423         */
424        public static final StringClientParam PUBLISHER = new StringClientParam(SP_PUBLISHER);
425
426        /**
427         * Search parameter constant for <b>description</b>
428         * <p>
429         * Description: <b>Text search in the description of the conformance statement</b><br>
430         * Type: <b>string</b><br>
431         * Path: <b>Conformance.description</b><br>
432         * </p>
433         */
434        @SearchParamDefinition(name="description", path="Conformance.description", description="Text search in the description of the conformance statement", type="string"  )
435        public static final String SP_DESCRIPTION = "description";
436
437        /**
438         * <b>Fluent Client</b> search parameter constant for <b>description</b>
439         * <p>
440         * Description: <b>Text search in the description of the conformance statement</b><br>
441         * Type: <b>string</b><br>
442         * Path: <b>Conformance.description</b><br>
443         * </p>
444         */
445        public static final StringClientParam DESCRIPTION = new StringClientParam(SP_DESCRIPTION);
446
447        /**
448         * Search parameter constant for <b>status</b>
449         * <p>
450         * Description: <b>The current status of the conformance statement</b><br>
451         * Type: <b>token</b><br>
452         * Path: <b>Conformance.status</b><br>
453         * </p>
454         */
455        @SearchParamDefinition(name="status", path="Conformance.status", description="The current status of the conformance statement", type="token"  )
456        public static final String SP_STATUS = "status";
457
458        /**
459         * <b>Fluent Client</b> search parameter constant for <b>status</b>
460         * <p>
461         * Description: <b>The current status of the conformance statement</b><br>
462         * Type: <b>token</b><br>
463         * Path: <b>Conformance.status</b><br>
464         * </p>
465         */
466        public static final TokenClientParam STATUS = new TokenClientParam(SP_STATUS);
467
468        /**
469         * Search parameter constant for <b>date</b>
470         * <p>
471         * Description: <b>The conformance statement publication date</b><br>
472         * Type: <b>date</b><br>
473         * Path: <b>Conformance.date</b><br>
474         * </p>
475         */
476        @SearchParamDefinition(name="date", path="Conformance.date", description="The conformance statement publication date", type="date"  )
477        public static final String SP_DATE = "date";
478
479        /**
480         * <b>Fluent Client</b> search parameter constant for <b>date</b>
481         * <p>
482         * Description: <b>The conformance statement publication date</b><br>
483         * Type: <b>date</b><br>
484         * Path: <b>Conformance.date</b><br>
485         * </p>
486         */
487        public static final DateClientParam DATE = new DateClientParam(SP_DATE);
488
489        /**
490         * Search parameter constant for <b>software</b>
491         * <p>
492         * Description: <b>Part of a the name of a software application</b><br>
493         * Type: <b>string</b><br>
494         * Path: <b>Conformance.software.name</b><br>
495         * </p>
496         */
497        @SearchParamDefinition(name="software", path="Conformance.software.name", description="Part of a the name of a software application", type="string"  )
498        public static final String SP_SOFTWARE = "software";
499
500        /**
501         * <b>Fluent Client</b> search parameter constant for <b>software</b>
502         * <p>
503         * Description: <b>Part of a the name of a software application</b><br>
504         * Type: <b>string</b><br>
505         * Path: <b>Conformance.software.name</b><br>
506         * </p>
507         */
508        public static final StringClientParam SOFTWARE = new StringClientParam(SP_SOFTWARE);
509
510        /**
511         * Search parameter constant for <b>fhirversion</b>
512         * <p>
513         * Description: <b>The version of FHIR</b><br>
514         * Type: <b>token</b><br>
515         * Path: <b>Conformance.version</b><br>
516         * </p>
517         */
518        @SearchParamDefinition(name="fhirversion", path="Conformance.version", description="The version of FHIR", type="token"  )
519        public static final String SP_FHIRVERSION = "fhirversion";
520
521        /**
522         * <b>Fluent Client</b> search parameter constant for <b>fhirversion</b>
523         * <p>
524         * Description: <b>The version of FHIR</b><br>
525         * Type: <b>token</b><br>
526         * Path: <b>Conformance.version</b><br>
527         * </p>
528         */
529        public static final TokenClientParam FHIRVERSION = new TokenClientParam(SP_FHIRVERSION);
530
531        /**
532         * Search parameter constant for <b>resource</b>
533         * <p>
534         * Description: <b>Name of a resource mentioned in a conformance statement</b><br>
535         * Type: <b>token</b><br>
536         * Path: <b>Conformance.rest.resource.type</b><br>
537         * </p>
538         */
539        @SearchParamDefinition(name="resource", path="Conformance.rest.resource.type", description="Name of a resource mentioned in a conformance statement", type="token"  )
540        public static final String SP_RESOURCE = "resource";
541
542        /**
543         * <b>Fluent Client</b> search parameter constant for <b>resource</b>
544         * <p>
545         * Description: <b>Name of a resource mentioned in a conformance statement</b><br>
546         * Type: <b>token</b><br>
547         * Path: <b>Conformance.rest.resource.type</b><br>
548         * </p>
549         */
550        public static final TokenClientParam RESOURCE = new TokenClientParam(SP_RESOURCE);
551
552        /**
553         * Search parameter constant for <b>event</b>
554         * <p>
555         * Description: <b>Event code in a conformance statement</b><br>
556         * Type: <b>token</b><br>
557         * Path: <b>Conformance.messaging.event.code</b><br>
558         * </p>
559         */
560        @SearchParamDefinition(name="event", path="Conformance.messaging.event.code", description="Event code in a conformance statement", type="token"  )
561        public static final String SP_EVENT = "event";
562
563        /**
564         * <b>Fluent Client</b> search parameter constant for <b>event</b>
565         * <p>
566         * Description: <b>Event code in a conformance statement</b><br>
567         * Type: <b>token</b><br>
568         * Path: <b>Conformance.messaging.event.code</b><br>
569         * </p>
570         */
571        public static final TokenClientParam EVENT = new TokenClientParam(SP_EVENT);
572
573        /**
574         * Search parameter constant for <b>mode</b>
575         * <p>
576         * Description: <b>Mode - restful (server/client) or messaging (sender/receiver)</b><br>
577         * Type: <b>token</b><br>
578         * Path: <b>Conformance.rest.mode</b><br>
579         * </p>
580         */
581        @SearchParamDefinition(name="mode", path="Conformance.rest.mode", description="Mode - restful (server/client) or messaging (sender/receiver)", type="token"  )
582        public static final String SP_MODE = "mode";
583
584        /**
585         * <b>Fluent Client</b> search parameter constant for <b>mode</b>
586         * <p>
587         * Description: <b>Mode - restful (server/client) or messaging (sender/receiver)</b><br>
588         * Type: <b>token</b><br>
589         * Path: <b>Conformance.rest.mode</b><br>
590         * </p>
591         */
592        public static final TokenClientParam MODE = new TokenClientParam(SP_MODE);
593
594        /**
595         * Search parameter constant for <b>profile</b>
596         * <p>
597         * Description: <b>A profile id invoked in a conformance statement</b><br>
598         * Type: <b>reference</b><br>
599         * Path: <b>Conformance.rest.resource.profile</b><br>
600         * </p>
601         */
602        @SearchParamDefinition(name="profile", path="Conformance.rest.resource.profile", description="A profile id invoked in a conformance statement", type="reference"  )
603        public static final String SP_PROFILE = "profile";
604
605        /**
606         * <b>Fluent Client</b> search parameter constant for <b>profile</b>
607         * <p>
608         * Description: <b>A profile id invoked in a conformance statement</b><br>
609         * Type: <b>reference</b><br>
610         * Path: <b>Conformance.rest.resource.profile</b><br>
611         * </p>
612         */
613        public static final ReferenceClientParam PROFILE = new ReferenceClientParam(SP_PROFILE);
614
615        /**
616         * Search parameter constant for <b>format</b>
617         * <p>
618         * Description: <b></b><br>
619         * Type: <b>token</b><br>
620         * Path: <b>Conformance.format</b><br>
621         * </p>
622         */
623        @SearchParamDefinition(name="format", path="Conformance.format", description="", type="token"  )
624        public static final String SP_FORMAT = "format";
625
626        /**
627         * <b>Fluent Client</b> search parameter constant for <b>format</b>
628         * <p>
629         * Description: <b></b><br>
630         * Type: <b>token</b><br>
631         * Path: <b>Conformance.format</b><br>
632         * </p>
633         */
634        public static final TokenClientParam FORMAT = new TokenClientParam(SP_FORMAT);
635
636        /**
637         * Search parameter constant for <b>security</b>
638         * <p>
639         * Description: <b></b><br>
640         * Type: <b>token</b><br>
641         * Path: <b>Conformance.rest.security.service</b><br>
642         * </p>
643         */
644        @SearchParamDefinition(name="security", path="Conformance.rest.security.service", description="", type="token"  )
645        public static final String SP_SECURITY = "security";
646
647        /**
648         * <b>Fluent Client</b> search parameter constant for <b>security</b>
649         * <p>
650         * Description: <b></b><br>
651         * Type: <b>token</b><br>
652         * Path: <b>Conformance.rest.security.service</b><br>
653         * </p>
654         */
655        public static final TokenClientParam SECURITY = new TokenClientParam(SP_SECURITY);
656
657        /**
658         * Search parameter constant for <b>supported-profile</b>
659         * <p>
660         * Description: <b></b><br>
661         * Type: <b>reference</b><br>
662         * Path: <b>Conformance.profile</b><br>
663         * </p>
664         */
665        @SearchParamDefinition(name="supported-profile", path="Conformance.profile", description="", type="reference"  )
666        public static final String SP_SUPPORTED_PROFILE = "supported-profile";
667
668        /**
669         * <b>Fluent Client</b> search parameter constant for <b>supported-profile</b>
670         * <p>
671         * Description: <b></b><br>
672         * Type: <b>reference</b><br>
673         * Path: <b>Conformance.profile</b><br>
674         * </p>
675         */
676        public static final ReferenceClientParam SUPPORTED_PROFILE = new ReferenceClientParam(SP_SUPPORTED_PROFILE);
677
678
679        /**
680         * Constant for fluent queries to be used to add include statements. Specifies
681         * the path value of "<b>Conformance:profile</b>".
682         */
683        public static final Include INCLUDE_PROFILE = new Include("Conformance:profile");
684
685        /**
686         * Constant for fluent queries to be used to add include statements. Specifies
687         * the path value of "<b>Conformance:supported-profile</b>".
688         */
689        public static final Include INCLUDE_SUPPORTED_PROFILE = new Include("Conformance:supported-profile");
690
691
692        @Child(name="url", type=UriDt.class, order=0, min=0, max=1, summary=true, modifier=false)       
693        @Description(
694                shortDefinition="",
695                formalDefinition="An absolute URL that is used to identify this conformance statement 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 conformance statement is (or will be) published"
696        )
697        private UriDt myUrl;
698        
699        @Child(name="version", type=StringDt.class, order=1, min=0, max=1, summary=true, modifier=false)        
700        @Description(
701                shortDefinition="",
702                formalDefinition="The identifier that is used to identify this version of the conformance statement when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the profile author manually and the value should be a timestamp"
703        )
704        private StringDt myVersion;
705        
706        @Child(name="name", type=StringDt.class, order=2, min=0, max=1, summary=true, modifier=false)   
707        @Description(
708                shortDefinition="",
709                formalDefinition="A free text natural language name identifying the conformance statement"
710        )
711        private StringDt myName;
712        
713        @Child(name="status", type=CodeDt.class, order=3, min=0, max=1, summary=true, modifier=false)   
714        @Description(
715                shortDefinition="",
716                formalDefinition="The status of this conformance statement"
717        )
718        private BoundCodeDt<ConformanceResourceStatusEnum> myStatus;
719        
720        @Child(name="experimental", type=BooleanDt.class, order=4, min=0, max=1, summary=true, modifier=false)  
721        @Description(
722                shortDefinition="",
723                formalDefinition="A flag to indicate that this conformance statement is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage"
724        )
725        private BooleanDt myExperimental;
726        
727        @Child(name="publisher", type=StringDt.class, order=5, min=0, max=1, summary=true, modifier=false)      
728        @Description(
729                shortDefinition="",
730                formalDefinition="The name of the individual or organization that published the conformance"
731        )
732        private StringDt myPublisher;
733        
734        @Child(name="contact", order=6, min=0, max=Child.MAX_UNLIMITED, summary=true, modifier=false)   
735        @Description(
736                shortDefinition="",
737                formalDefinition="Contacts to assist a user in finding and communicating with the publisher"
738        )
739        private java.util.List<Contact> myContact;
740        
741        @Child(name="date", type=DateTimeDt.class, order=7, min=1, max=1, summary=true, modifier=false) 
742        @Description(
743                shortDefinition="",
744                formalDefinition="The date  (and optionally time) when the conformance statement 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 conformance statement changes"
745        )
746        private DateTimeDt myDate;
747        
748        @Child(name="description", type=StringDt.class, order=8, min=0, max=1, summary=true, modifier=false)    
749        @Description(
750                shortDefinition="",
751                formalDefinition="A free text natural language description of the conformance statement and its use. Typically, this is used when the conformance statement describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP"
752        )
753        private StringDt myDescription;
754        
755        @Child(name="requirements", type=StringDt.class, order=9, min=0, max=1, summary=false, modifier=false)  
756        @Description(
757                shortDefinition="",
758                formalDefinition="Explains why this conformance statement is needed and why it's been constrained as it has"
759        )
760        private StringDt myRequirements;
761        
762        @Child(name="copyright", type=StringDt.class, order=10, min=0, max=1, summary=false, modifier=false)    
763        @Description(
764                shortDefinition="",
765                formalDefinition="A copyright statement relating to the conformance statement and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the system described by the conformance statement"
766        )
767        private StringDt myCopyright;
768        
769        @Child(name="kind", type=CodeDt.class, order=11, min=1, max=1, summary=true, modifier=false)    
770        @Description(
771                shortDefinition="",
772                formalDefinition="The way that this statement is intended to be used, to describe an actual running instance of software, a particular product (kind not instance of software) or a class of implementation (e.g. a desired purchase)"
773        )
774        private BoundCodeDt<ConformanceStatementKindEnum> myKind;
775        
776        @Child(name="software", order=12, min=0, max=1, summary=true, modifier=false)   
777        @Description(
778                shortDefinition="",
779                formalDefinition="Software that is covered by this conformance statement.  It is used when the conformance statement describes the capabilities of a particular software version, independent of an installation."
780        )
781        private Software mySoftware;
782        
783        @Child(name="implementation", order=13, min=0, max=1, summary=true, modifier=false)     
784        @Description(
785                shortDefinition="",
786                formalDefinition="Identifies a specific implementation instance that is described by the conformance statement - i.e. a particular installation, rather than the capabilities of a software program"
787        )
788        private Implementation myImplementation;
789        
790        @Child(name="fhirVersion", type=IdDt.class, order=14, min=1, max=1, summary=true, modifier=false)       
791        @Description(
792                shortDefinition="",
793                formalDefinition="The version of the FHIR specification on which this conformance statement is based"
794        )
795        private IdDt myFhirVersion;
796        
797        @Child(name="acceptUnknown", type=CodeDt.class, order=15, min=1, max=1, summary=true, modifier=false)   
798        @Description(
799                shortDefinition="",
800                formalDefinition="A code that indicates whether the application accepts unknown elements or extensions when reading resources"
801        )
802        private BoundCodeDt<UnknownContentCodeEnum> myAcceptUnknown;
803        
804        @Child(name="format", type=CodeDt.class, order=16, min=1, max=Child.MAX_UNLIMITED, summary=true, modifier=false)        
805        @Description(
806                shortDefinition="",
807                formalDefinition="A list of the formats supported by this implementation using their content types"
808        )
809        private java.util.List<CodeDt> myFormat;
810        
811        @Child(name="profile", order=17, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false, type={
812                ca.uhn.fhir.model.dstu2.resource.StructureDefinition.class      })
813        @Description(
814                shortDefinition="",
815                formalDefinition="A list of profiles that represent different use cases supported by the system. For a server, \"supported by the system\" means the system hosts/produces a set of resources that are conformant to a particular profile, and allows clients that use its services to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile. See further discussion in [Using Profiles]{profiling.html#profile-uses}"
816        )
817        private java.util.List<ResourceReferenceDt> myProfile;
818        
819        @Child(name="rest", order=18, min=0, max=Child.MAX_UNLIMITED, summary=true, modifier=false)     
820        @Description(
821                shortDefinition="",
822                formalDefinition="A definition of the restful capabilities of the solution, if any"
823        )
824        private java.util.List<Rest> myRest;
825        
826        @Child(name="messaging", order=19, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)       
827        @Description(
828                shortDefinition="",
829                formalDefinition="A description of the messaging capabilities of the solution"
830        )
831        private java.util.List<Messaging> myMessaging;
832        
833        @Child(name="document", order=20, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)        
834        @Description(
835                shortDefinition="",
836                formalDefinition="A document definition"
837        )
838        private java.util.List<Document> myDocument;
839        
840
841        @Override
842        public boolean isEmpty() {
843                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myUrl,  myVersion,  myName,  myStatus,  myExperimental,  myPublisher,  myContact,  myDate,  myDescription,  myRequirements,  myCopyright,  myKind,  mySoftware,  myImplementation,  myFhirVersion,  myAcceptUnknown,  myFormat,  myProfile,  myRest,  myMessaging,  myDocument);
844        }
845        
846        @Override
847        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
848                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myUrl, myVersion, myName, myStatus, myExperimental, myPublisher, myContact, myDate, myDescription, myRequirements, myCopyright, myKind, mySoftware, myImplementation, myFhirVersion, myAcceptUnknown, myFormat, myProfile, myRest, myMessaging, myDocument);
849        }
850
851        /**
852         * Gets the value(s) for <b>url</b> ().
853         * creating it if it does
854         * not exist. Will not return <code>null</code>.
855         *
856     * <p>
857     * <b>Definition:</b>
858     * An absolute URL that is used to identify this conformance statement 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 conformance statement is (or will be) published
859     * </p> 
860         */
861        public UriDt getUrlElement() {  
862                if (myUrl == null) {
863                        myUrl = new UriDt();
864                }
865                return myUrl;
866        }
867
868        
869        /**
870         * Gets the value(s) for <b>url</b> ().
871         * creating it if it does
872         * not exist. Will not return <code>null</code>.
873         *
874     * <p>
875     * <b>Definition:</b>
876     * An absolute URL that is used to identify this conformance statement 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 conformance statement is (or will be) published
877     * </p> 
878         */
879        public String getUrl() {  
880                return getUrlElement().getValue();
881        }
882
883        /**
884         * Sets the value(s) for <b>url</b> ()
885         *
886     * <p>
887     * <b>Definition:</b>
888     * An absolute URL that is used to identify this conformance statement 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 conformance statement is (or will be) published
889     * </p> 
890         */
891        public Conformance setUrl(UriDt theValue) {
892                myUrl = theValue;
893                return this;
894        }
895        
896        
897
898        /**
899         * Sets the value for <b>url</b> ()
900         *
901     * <p>
902     * <b>Definition:</b>
903     * An absolute URL that is used to identify this conformance statement 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 conformance statement is (or will be) published
904     * </p> 
905         */
906        public Conformance setUrl( String theUri) {
907                myUrl = new UriDt(theUri); 
908                return this; 
909        }
910
911 
912        /**
913         * Gets the value(s) for <b>version</b> ().
914         * creating it if it does
915         * not exist. Will not return <code>null</code>.
916         *
917     * <p>
918     * <b>Definition:</b>
919     * The identifier that is used to identify this version of the conformance statement when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the profile author manually and the value should be a timestamp
920     * </p> 
921         */
922        public StringDt getVersionElement() {  
923                if (myVersion == null) {
924                        myVersion = new StringDt();
925                }
926                return myVersion;
927        }
928
929        
930        /**
931         * Gets the value(s) for <b>version</b> ().
932         * creating it if it does
933         * not exist. Will not return <code>null</code>.
934         *
935     * <p>
936     * <b>Definition:</b>
937     * The identifier that is used to identify this version of the conformance statement when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the profile author manually and the value should be a timestamp
938     * </p> 
939         */
940        public String getVersion() {  
941                return getVersionElement().getValue();
942        }
943
944        /**
945         * Sets the value(s) for <b>version</b> ()
946         *
947     * <p>
948     * <b>Definition:</b>
949     * The identifier that is used to identify this version of the conformance statement when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the profile author manually and the value should be a timestamp
950     * </p> 
951         */
952        public Conformance setVersion(StringDt theValue) {
953                myVersion = theValue;
954                return this;
955        }
956        
957        
958
959        /**
960         * Sets the value for <b>version</b> ()
961         *
962     * <p>
963     * <b>Definition:</b>
964     * The identifier that is used to identify this version of the conformance statement when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the profile author manually and the value should be a timestamp
965     * </p> 
966         */
967        public Conformance setVersion( String theString) {
968                myVersion = new StringDt(theString); 
969                return this; 
970        }
971
972 
973        /**
974         * Gets the value(s) for <b>name</b> ().
975         * creating it if it does
976         * not exist. Will not return <code>null</code>.
977         *
978     * <p>
979     * <b>Definition:</b>
980     * A free text natural language name identifying the conformance statement
981     * </p> 
982         */
983        public StringDt getNameElement() {  
984                if (myName == null) {
985                        myName = new StringDt();
986                }
987                return myName;
988        }
989
990        
991        /**
992         * Gets the value(s) for <b>name</b> ().
993         * creating it if it does
994         * not exist. Will not return <code>null</code>.
995         *
996     * <p>
997     * <b>Definition:</b>
998     * A free text natural language name identifying the conformance statement
999     * </p> 
1000         */
1001        public String getName() {  
1002                return getNameElement().getValue();
1003        }
1004
1005        /**
1006         * Sets the value(s) for <b>name</b> ()
1007         *
1008     * <p>
1009     * <b>Definition:</b>
1010     * A free text natural language name identifying the conformance statement
1011     * </p> 
1012         */
1013        public Conformance setName(StringDt theValue) {
1014                myName = theValue;
1015                return this;
1016        }
1017        
1018        
1019
1020        /**
1021         * Sets the value for <b>name</b> ()
1022         *
1023     * <p>
1024     * <b>Definition:</b>
1025     * A free text natural language name identifying the conformance statement
1026     * </p> 
1027         */
1028        public Conformance setName( String theString) {
1029                myName = new StringDt(theString); 
1030                return this; 
1031        }
1032
1033 
1034        /**
1035         * Gets the value(s) for <b>status</b> ().
1036         * creating it if it does
1037         * not exist. Will not return <code>null</code>.
1038         *
1039     * <p>
1040     * <b>Definition:</b>
1041     * The status of this conformance statement
1042     * </p> 
1043         */
1044        public BoundCodeDt<ConformanceResourceStatusEnum> getStatusElement() {  
1045                if (myStatus == null) {
1046                        myStatus = new BoundCodeDt<ConformanceResourceStatusEnum>(ConformanceResourceStatusEnum.VALUESET_BINDER);
1047                }
1048                return myStatus;
1049        }
1050
1051        
1052        /**
1053         * Gets the value(s) for <b>status</b> ().
1054         * creating it if it does
1055         * not exist. Will not return <code>null</code>.
1056         *
1057     * <p>
1058     * <b>Definition:</b>
1059     * The status of this conformance statement
1060     * </p> 
1061         */
1062        public String getStatus() {  
1063                return getStatusElement().getValue();
1064        }
1065
1066        /**
1067         * Sets the value(s) for <b>status</b> ()
1068         *
1069     * <p>
1070     * <b>Definition:</b>
1071     * The status of this conformance statement
1072     * </p> 
1073         */
1074        public Conformance setStatus(BoundCodeDt<ConformanceResourceStatusEnum> theValue) {
1075                myStatus = theValue;
1076                return this;
1077        }
1078        
1079        
1080
1081        /**
1082         * Sets the value(s) for <b>status</b> ()
1083         *
1084     * <p>
1085     * <b>Definition:</b>
1086     * The status of this conformance statement
1087     * </p> 
1088         */
1089        public Conformance setStatus(ConformanceResourceStatusEnum theValue) {
1090                setStatus(new BoundCodeDt<ConformanceResourceStatusEnum>(ConformanceResourceStatusEnum.VALUESET_BINDER, theValue));
1091                
1092/*
1093                getStatusElement().setValueAsEnum(theValue);
1094*/
1095                return this;
1096        }
1097
1098  
1099        /**
1100         * Gets the value(s) for <b>experimental</b> ().
1101         * creating it if it does
1102         * not exist. Will not return <code>null</code>.
1103         *
1104     * <p>
1105     * <b>Definition:</b>
1106     * A flag to indicate that this conformance statement is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage
1107     * </p> 
1108         */
1109        public BooleanDt getExperimentalElement() {  
1110                if (myExperimental == null) {
1111                        myExperimental = new BooleanDt();
1112                }
1113                return myExperimental;
1114        }
1115
1116        
1117        /**
1118         * Gets the value(s) for <b>experimental</b> ().
1119         * creating it if it does
1120         * not exist. Will not return <code>null</code>.
1121         *
1122     * <p>
1123     * <b>Definition:</b>
1124     * A flag to indicate that this conformance statement is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage
1125     * </p> 
1126         */
1127        public Boolean getExperimental() {  
1128                return getExperimentalElement().getValue();
1129        }
1130
1131        /**
1132         * Sets the value(s) for <b>experimental</b> ()
1133         *
1134     * <p>
1135     * <b>Definition:</b>
1136     * A flag to indicate that this conformance statement is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage
1137     * </p> 
1138         */
1139        public Conformance setExperimental(BooleanDt theValue) {
1140                myExperimental = theValue;
1141                return this;
1142        }
1143        
1144        
1145
1146        /**
1147         * Sets the value for <b>experimental</b> ()
1148         *
1149     * <p>
1150     * <b>Definition:</b>
1151     * A flag to indicate that this conformance statement is authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage
1152     * </p> 
1153         */
1154        public Conformance setExperimental( boolean theBoolean) {
1155                myExperimental = new BooleanDt(theBoolean); 
1156                return this; 
1157        }
1158
1159 
1160        /**
1161         * Gets the value(s) for <b>publisher</b> ().
1162         * creating it if it does
1163         * not exist. Will not return <code>null</code>.
1164         *
1165     * <p>
1166     * <b>Definition:</b>
1167     * The name of the individual or organization that published the conformance
1168     * </p> 
1169         */
1170        public StringDt getPublisherElement() {  
1171                if (myPublisher == null) {
1172                        myPublisher = new StringDt();
1173                }
1174                return myPublisher;
1175        }
1176
1177        
1178        /**
1179         * Gets the value(s) for <b>publisher</b> ().
1180         * creating it if it does
1181         * not exist. Will not return <code>null</code>.
1182         *
1183     * <p>
1184     * <b>Definition:</b>
1185     * The name of the individual or organization that published the conformance
1186     * </p> 
1187         */
1188        public String getPublisher() {  
1189                return getPublisherElement().getValue();
1190        }
1191
1192        /**
1193         * Sets the value(s) for <b>publisher</b> ()
1194         *
1195     * <p>
1196     * <b>Definition:</b>
1197     * The name of the individual or organization that published the conformance
1198     * </p> 
1199         */
1200        public Conformance setPublisher(StringDt theValue) {
1201                myPublisher = theValue;
1202                return this;
1203        }
1204        
1205        
1206
1207        /**
1208         * Sets the value for <b>publisher</b> ()
1209         *
1210     * <p>
1211     * <b>Definition:</b>
1212     * The name of the individual or organization that published the conformance
1213     * </p> 
1214         */
1215        public Conformance setPublisher( String theString) {
1216                myPublisher = new StringDt(theString); 
1217                return this; 
1218        }
1219
1220 
1221        /**
1222         * Gets the value(s) for <b>contact</b> ().
1223         * creating it if it does
1224         * not exist. Will not return <code>null</code>.
1225         *
1226     * <p>
1227     * <b>Definition:</b>
1228     * Contacts to assist a user in finding and communicating with the publisher
1229     * </p> 
1230         */
1231        public java.util.List<Contact> getContact() {  
1232                if (myContact == null) {
1233                        myContact = new java.util.ArrayList<Contact>();
1234                }
1235                return myContact;
1236        }
1237
1238        /**
1239         * Sets the value(s) for <b>contact</b> ()
1240         *
1241     * <p>
1242     * <b>Definition:</b>
1243     * Contacts to assist a user in finding and communicating with the publisher
1244     * </p> 
1245         */
1246        public Conformance setContact(java.util.List<Contact> theValue) {
1247                myContact = theValue;
1248                return this;
1249        }
1250        
1251        
1252
1253        /**
1254         * Adds and returns a new value for <b>contact</b> ()
1255         *
1256     * <p>
1257     * <b>Definition:</b>
1258     * Contacts to assist a user in finding and communicating with the publisher
1259     * </p> 
1260         */
1261        public Contact addContact() {
1262                Contact newType = new Contact();
1263                getContact().add(newType);
1264                return newType; 
1265        }
1266
1267        /**
1268         * Adds a given new value for <b>contact</b> ()
1269         *
1270         * <p>
1271         * <b>Definition:</b>
1272         * Contacts to assist a user in finding and communicating with the publisher
1273         * </p>
1274         * @param theValue The contact to add (must not be <code>null</code>)
1275         */
1276        public Conformance addContact(Contact theValue) {
1277                if (theValue == null) {
1278                        throw new NullPointerException("theValue must not be null");
1279                }
1280                getContact().add(theValue);
1281                return this;
1282        }
1283
1284        /**
1285         * Gets the first repetition for <b>contact</b> (),
1286         * creating it if it does not already exist.
1287         *
1288     * <p>
1289     * <b>Definition:</b>
1290     * Contacts to assist a user in finding and communicating with the publisher
1291     * </p> 
1292         */
1293        public Contact getContactFirstRep() {
1294                if (getContact().isEmpty()) {
1295                        return addContact();
1296                }
1297                return getContact().get(0); 
1298        }
1299  
1300        /**
1301         * Gets the value(s) for <b>date</b> ().
1302         * creating it if it does
1303         * not exist. Will not return <code>null</code>.
1304         *
1305     * <p>
1306     * <b>Definition:</b>
1307     * The date  (and optionally time) when the conformance statement 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 conformance statement changes
1308     * </p> 
1309         */
1310        public DateTimeDt getDateElement() {  
1311                if (myDate == null) {
1312                        myDate = new DateTimeDt();
1313                }
1314                return myDate;
1315        }
1316
1317        
1318        /**
1319         * Gets the value(s) for <b>date</b> ().
1320         * creating it if it does
1321         * not exist. Will not return <code>null</code>.
1322         *
1323     * <p>
1324     * <b>Definition:</b>
1325     * The date  (and optionally time) when the conformance statement 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 conformance statement changes
1326     * </p> 
1327         */
1328        public Date getDate() {  
1329                return getDateElement().getValue();
1330        }
1331
1332        /**
1333         * Sets the value(s) for <b>date</b> ()
1334         *
1335     * <p>
1336     * <b>Definition:</b>
1337     * The date  (and optionally time) when the conformance statement 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 conformance statement changes
1338     * </p> 
1339         */
1340        public Conformance setDate(DateTimeDt theValue) {
1341                myDate = theValue;
1342                return this;
1343        }
1344        
1345        
1346
1347        /**
1348         * Sets the value for <b>date</b> ()
1349         *
1350     * <p>
1351     * <b>Definition:</b>
1352     * The date  (and optionally time) when the conformance statement 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 conformance statement changes
1353     * </p> 
1354         */
1355        public Conformance setDate( Date theDate,  TemporalPrecisionEnum thePrecision) {
1356                myDate = new DateTimeDt(theDate, thePrecision); 
1357                return this; 
1358        }
1359
1360        /**
1361         * Sets the value for <b>date</b> ()
1362         *
1363     * <p>
1364     * <b>Definition:</b>
1365     * The date  (and optionally time) when the conformance statement 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 conformance statement changes
1366     * </p> 
1367         */
1368        public Conformance setDateWithSecondsPrecision( Date theDate) {
1369                myDate = new DateTimeDt(theDate); 
1370                return this; 
1371        }
1372
1373 
1374        /**
1375         * Gets the value(s) for <b>description</b> ().
1376         * creating it if it does
1377         * not exist. Will not return <code>null</code>.
1378         *
1379     * <p>
1380     * <b>Definition:</b>
1381     * A free text natural language description of the conformance statement and its use. Typically, this is used when the conformance statement describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP
1382     * </p> 
1383         */
1384        public StringDt getDescriptionElement() {  
1385                if (myDescription == null) {
1386                        myDescription = new StringDt();
1387                }
1388                return myDescription;
1389        }
1390
1391        
1392        /**
1393         * Gets the value(s) for <b>description</b> ().
1394         * creating it if it does
1395         * not exist. Will not return <code>null</code>.
1396         *
1397     * <p>
1398     * <b>Definition:</b>
1399     * A free text natural language description of the conformance statement and its use. Typically, this is used when the conformance statement describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP
1400     * </p> 
1401         */
1402        public String getDescription() {  
1403                return getDescriptionElement().getValue();
1404        }
1405
1406        /**
1407         * Sets the value(s) for <b>description</b> ()
1408         *
1409     * <p>
1410     * <b>Definition:</b>
1411     * A free text natural language description of the conformance statement and its use. Typically, this is used when the conformance statement describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP
1412     * </p> 
1413         */
1414        public Conformance setDescription(StringDt theValue) {
1415                myDescription = theValue;
1416                return this;
1417        }
1418        
1419        
1420
1421        /**
1422         * Sets the value for <b>description</b> ()
1423         *
1424     * <p>
1425     * <b>Definition:</b>
1426     * A free text natural language description of the conformance statement and its use. Typically, this is used when the conformance statement describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP
1427     * </p> 
1428         */
1429        public Conformance setDescription( String theString) {
1430                myDescription = new StringDt(theString); 
1431                return this; 
1432        }
1433
1434 
1435        /**
1436         * Gets the value(s) for <b>requirements</b> ().
1437         * creating it if it does
1438         * not exist. Will not return <code>null</code>.
1439         *
1440     * <p>
1441     * <b>Definition:</b>
1442     * Explains why this conformance statement is needed and why it's been constrained as it has
1443     * </p> 
1444         */
1445        public StringDt getRequirementsElement() {  
1446                if (myRequirements == null) {
1447                        myRequirements = new StringDt();
1448                }
1449                return myRequirements;
1450        }
1451
1452        
1453        /**
1454         * Gets the value(s) for <b>requirements</b> ().
1455         * creating it if it does
1456         * not exist. Will not return <code>null</code>.
1457         *
1458     * <p>
1459     * <b>Definition:</b>
1460     * Explains why this conformance statement is needed and why it's been constrained as it has
1461     * </p> 
1462         */
1463        public String getRequirements() {  
1464                return getRequirementsElement().getValue();
1465        }
1466
1467        /**
1468         * Sets the value(s) for <b>requirements</b> ()
1469         *
1470     * <p>
1471     * <b>Definition:</b>
1472     * Explains why this conformance statement is needed and why it's been constrained as it has
1473     * </p> 
1474         */
1475        public Conformance setRequirements(StringDt theValue) {
1476                myRequirements = theValue;
1477                return this;
1478        }
1479        
1480        
1481
1482        /**
1483         * Sets the value for <b>requirements</b> ()
1484         *
1485     * <p>
1486     * <b>Definition:</b>
1487     * Explains why this conformance statement is needed and why it's been constrained as it has
1488     * </p> 
1489         */
1490        public Conformance setRequirements( String theString) {
1491                myRequirements = new StringDt(theString); 
1492                return this; 
1493        }
1494
1495 
1496        /**
1497         * Gets the value(s) for <b>copyright</b> ().
1498         * creating it if it does
1499         * not exist. Will not return <code>null</code>.
1500         *
1501     * <p>
1502     * <b>Definition:</b>
1503     * A copyright statement relating to the conformance statement and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the system described by the conformance statement
1504     * </p> 
1505         */
1506        public StringDt getCopyrightElement() {  
1507                if (myCopyright == null) {
1508                        myCopyright = new StringDt();
1509                }
1510                return myCopyright;
1511        }
1512
1513        
1514        /**
1515         * Gets the value(s) for <b>copyright</b> ().
1516         * creating it if it does
1517         * not exist. Will not return <code>null</code>.
1518         *
1519     * <p>
1520     * <b>Definition:</b>
1521     * A copyright statement relating to the conformance statement and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the system described by the conformance statement
1522     * </p> 
1523         */
1524        public String getCopyright() {  
1525                return getCopyrightElement().getValue();
1526        }
1527
1528        /**
1529         * Sets the value(s) for <b>copyright</b> ()
1530         *
1531     * <p>
1532     * <b>Definition:</b>
1533     * A copyright statement relating to the conformance statement and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the system described by the conformance statement
1534     * </p> 
1535         */
1536        public Conformance setCopyright(StringDt theValue) {
1537                myCopyright = theValue;
1538                return this;
1539        }
1540        
1541        
1542
1543        /**
1544         * Sets the value for <b>copyright</b> ()
1545         *
1546     * <p>
1547     * <b>Definition:</b>
1548     * A copyright statement relating to the conformance statement and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the system described by the conformance statement
1549     * </p> 
1550         */
1551        public Conformance setCopyright( String theString) {
1552                myCopyright = new StringDt(theString); 
1553                return this; 
1554        }
1555
1556 
1557        /**
1558         * Gets the value(s) for <b>kind</b> ().
1559         * creating it if it does
1560         * not exist. Will not return <code>null</code>.
1561         *
1562     * <p>
1563     * <b>Definition:</b>
1564     * The way that this statement is intended to be used, to describe an actual running instance of software, a particular product (kind not instance of software) or a class of implementation (e.g. a desired purchase)
1565     * </p> 
1566         */
1567        public BoundCodeDt<ConformanceStatementKindEnum> getKindElement() {  
1568                if (myKind == null) {
1569                        myKind = new BoundCodeDt<ConformanceStatementKindEnum>(ConformanceStatementKindEnum.VALUESET_BINDER);
1570                }
1571                return myKind;
1572        }
1573
1574        
1575        /**
1576         * Gets the value(s) for <b>kind</b> ().
1577         * creating it if it does
1578         * not exist. Will not return <code>null</code>.
1579         *
1580     * <p>
1581     * <b>Definition:</b>
1582     * The way that this statement is intended to be used, to describe an actual running instance of software, a particular product (kind not instance of software) or a class of implementation (e.g. a desired purchase)
1583     * </p> 
1584         */
1585        public String getKind() {  
1586                return getKindElement().getValue();
1587        }
1588
1589        /**
1590         * Sets the value(s) for <b>kind</b> ()
1591         *
1592     * <p>
1593     * <b>Definition:</b>
1594     * The way that this statement is intended to be used, to describe an actual running instance of software, a particular product (kind not instance of software) or a class of implementation (e.g. a desired purchase)
1595     * </p> 
1596         */
1597        public Conformance setKind(BoundCodeDt<ConformanceStatementKindEnum> theValue) {
1598                myKind = theValue;
1599                return this;
1600        }
1601        
1602        
1603
1604        /**
1605         * Sets the value(s) for <b>kind</b> ()
1606         *
1607     * <p>
1608     * <b>Definition:</b>
1609     * The way that this statement is intended to be used, to describe an actual running instance of software, a particular product (kind not instance of software) or a class of implementation (e.g. a desired purchase)
1610     * </p> 
1611         */
1612        public Conformance setKind(ConformanceStatementKindEnum theValue) {
1613                setKind(new BoundCodeDt<ConformanceStatementKindEnum>(ConformanceStatementKindEnum.VALUESET_BINDER, theValue));
1614                
1615/*
1616                getKindElement().setValueAsEnum(theValue);
1617*/
1618                return this;
1619        }
1620
1621  
1622        /**
1623         * Gets the value(s) for <b>software</b> ().
1624         * creating it if it does
1625         * not exist. Will not return <code>null</code>.
1626         *
1627     * <p>
1628     * <b>Definition:</b>
1629     * Software that is covered by this conformance statement.  It is used when the conformance statement describes the capabilities of a particular software version, independent of an installation.
1630     * </p> 
1631         */
1632        public Software getSoftware() {  
1633                if (mySoftware == null) {
1634                        mySoftware = new Software();
1635                }
1636                return mySoftware;
1637        }
1638
1639        /**
1640         * Sets the value(s) for <b>software</b> ()
1641         *
1642     * <p>
1643     * <b>Definition:</b>
1644     * Software that is covered by this conformance statement.  It is used when the conformance statement describes the capabilities of a particular software version, independent of an installation.
1645     * </p> 
1646         */
1647        public Conformance setSoftware(Software theValue) {
1648                mySoftware = theValue;
1649                return this;
1650        }
1651        
1652        
1653
1654  
1655        /**
1656         * Gets the value(s) for <b>implementation</b> ().
1657         * creating it if it does
1658         * not exist. Will not return <code>null</code>.
1659         *
1660     * <p>
1661     * <b>Definition:</b>
1662     * Identifies a specific implementation instance that is described by the conformance statement - i.e. a particular installation, rather than the capabilities of a software program
1663     * </p> 
1664         */
1665        public Implementation getImplementation() {  
1666                if (myImplementation == null) {
1667                        myImplementation = new Implementation();
1668                }
1669                return myImplementation;
1670        }
1671
1672        /**
1673         * Sets the value(s) for <b>implementation</b> ()
1674         *
1675     * <p>
1676     * <b>Definition:</b>
1677     * Identifies a specific implementation instance that is described by the conformance statement - i.e. a particular installation, rather than the capabilities of a software program
1678     * </p> 
1679         */
1680        public Conformance setImplementation(Implementation theValue) {
1681                myImplementation = theValue;
1682                return this;
1683        }
1684        
1685        
1686
1687  
1688        /**
1689         * Gets the value(s) for <b>fhirVersion</b> ().
1690         * creating it if it does
1691         * not exist. Will not return <code>null</code>.
1692         *
1693     * <p>
1694     * <b>Definition:</b>
1695     * The version of the FHIR specification on which this conformance statement is based
1696     * </p> 
1697         */
1698        public IdDt getFhirVersionElement() {  
1699                if (myFhirVersion == null) {
1700                        myFhirVersion = new IdDt();
1701                }
1702                return myFhirVersion;
1703        }
1704
1705        
1706        /**
1707         * Gets the value(s) for <b>fhirVersion</b> ().
1708         * creating it if it does
1709         * not exist. Will not return <code>null</code>.
1710         *
1711     * <p>
1712     * <b>Definition:</b>
1713     * The version of the FHIR specification on which this conformance statement is based
1714     * </p> 
1715         */
1716        public String getFhirVersion() {  
1717                return getFhirVersionElement().getValue();
1718        }
1719
1720        /**
1721         * Sets the value(s) for <b>fhirVersion</b> ()
1722         *
1723     * <p>
1724     * <b>Definition:</b>
1725     * The version of the FHIR specification on which this conformance statement is based
1726     * </p> 
1727         */
1728        public Conformance setFhirVersion(IdDt theValue) {
1729                myFhirVersion = theValue;
1730                return this;
1731        }
1732        
1733        
1734
1735        /**
1736         * Sets the value for <b>fhirVersion</b> ()
1737         *
1738     * <p>
1739     * <b>Definition:</b>
1740     * The version of the FHIR specification on which this conformance statement is based
1741     * </p> 
1742         */
1743        public Conformance setFhirVersion( String theId) {
1744                myFhirVersion = new IdDt(theId); 
1745                return this; 
1746        }
1747
1748 
1749        /**
1750         * Gets the value(s) for <b>acceptUnknown</b> ().
1751         * creating it if it does
1752         * not exist. Will not return <code>null</code>.
1753         *
1754     * <p>
1755     * <b>Definition:</b>
1756     * A code that indicates whether the application accepts unknown elements or extensions when reading resources
1757     * </p> 
1758         */
1759        public BoundCodeDt<UnknownContentCodeEnum> getAcceptUnknownElement() {  
1760                if (myAcceptUnknown == null) {
1761                        myAcceptUnknown = new BoundCodeDt<UnknownContentCodeEnum>(UnknownContentCodeEnum.VALUESET_BINDER);
1762                }
1763                return myAcceptUnknown;
1764        }
1765
1766        
1767        /**
1768         * Gets the value(s) for <b>acceptUnknown</b> ().
1769         * creating it if it does
1770         * not exist. Will not return <code>null</code>.
1771         *
1772     * <p>
1773     * <b>Definition:</b>
1774     * A code that indicates whether the application accepts unknown elements or extensions when reading resources
1775     * </p> 
1776         */
1777        public String getAcceptUnknown() {  
1778                return getAcceptUnknownElement().getValue();
1779        }
1780
1781        /**
1782         * Sets the value(s) for <b>acceptUnknown</b> ()
1783         *
1784     * <p>
1785     * <b>Definition:</b>
1786     * A code that indicates whether the application accepts unknown elements or extensions when reading resources
1787     * </p> 
1788         */
1789        public Conformance setAcceptUnknown(BoundCodeDt<UnknownContentCodeEnum> theValue) {
1790                myAcceptUnknown = theValue;
1791                return this;
1792        }
1793        
1794        
1795
1796        /**
1797         * Sets the value(s) for <b>acceptUnknown</b> ()
1798         *
1799     * <p>
1800     * <b>Definition:</b>
1801     * A code that indicates whether the application accepts unknown elements or extensions when reading resources
1802     * </p> 
1803         */
1804        public Conformance setAcceptUnknown(UnknownContentCodeEnum theValue) {
1805                setAcceptUnknown(new BoundCodeDt<UnknownContentCodeEnum>(UnknownContentCodeEnum.VALUESET_BINDER, theValue));
1806                
1807/*
1808                getAcceptUnknownElement().setValueAsEnum(theValue);
1809*/
1810                return this;
1811        }
1812
1813  
1814        /**
1815         * Gets the value(s) for <b>format</b> ().
1816         * creating it if it does
1817         * not exist. Will not return <code>null</code>.
1818         *
1819     * <p>
1820     * <b>Definition:</b>
1821     * A list of the formats supported by this implementation using their content types
1822     * </p> 
1823         */
1824        public java.util.List<CodeDt> getFormat() {  
1825                if (myFormat == null) {
1826                        myFormat = new java.util.ArrayList<CodeDt>();
1827                }
1828                return myFormat;
1829        }
1830
1831        /**
1832         * Sets the value(s) for <b>format</b> ()
1833         *
1834     * <p>
1835     * <b>Definition:</b>
1836     * A list of the formats supported by this implementation using their content types
1837     * </p> 
1838         */
1839        public Conformance setFormat(java.util.List<CodeDt> theValue) {
1840                myFormat = theValue;
1841                return this;
1842        }
1843        
1844        
1845
1846        /**
1847         * Adds and returns a new value for <b>format</b> ()
1848         *
1849     * <p>
1850     * <b>Definition:</b>
1851     * A list of the formats supported by this implementation using their content types
1852     * </p> 
1853         */
1854        public CodeDt addFormat() {
1855                CodeDt newType = new CodeDt();
1856                getFormat().add(newType);
1857                return newType; 
1858        }
1859
1860        /**
1861         * Adds a given new value for <b>format</b> ()
1862         *
1863         * <p>
1864         * <b>Definition:</b>
1865         * A list of the formats supported by this implementation using their content types
1866         * </p>
1867         * @param theValue The format to add (must not be <code>null</code>)
1868         */
1869        public Conformance addFormat(CodeDt theValue) {
1870                if (theValue == null) {
1871                        throw new NullPointerException("theValue must not be null");
1872                }
1873                getFormat().add(theValue);
1874                return this;
1875        }
1876
1877        /**
1878         * Gets the first repetition for <b>format</b> (),
1879         * creating it if it does not already exist.
1880         *
1881     * <p>
1882     * <b>Definition:</b>
1883     * A list of the formats supported by this implementation using their content types
1884     * </p> 
1885         */
1886        public CodeDt getFormatFirstRep() {
1887                if (getFormat().isEmpty()) {
1888                        return addFormat();
1889                }
1890                return getFormat().get(0); 
1891        }
1892        /**
1893         * Adds a new value for <b>format</b> ()
1894         *
1895     * <p>
1896     * <b>Definition:</b>
1897     * A list of the formats supported by this implementation using their content types
1898     * </p> 
1899     *
1900     * @return Returns a reference to this object, to allow for simple chaining.
1901         */
1902        public Conformance addFormat( String theCode) {
1903                if (myFormat == null) {
1904                        myFormat = new java.util.ArrayList<CodeDt>();
1905                }
1906                myFormat.add(new CodeDt(theCode));
1907                return this; 
1908        }
1909
1910 
1911        /**
1912         * Gets the value(s) for <b>profile</b> ().
1913         * creating it if it does
1914         * not exist. Will not return <code>null</code>.
1915         *
1916     * <p>
1917     * <b>Definition:</b>
1918     * A list of profiles that represent different use cases supported by the system. For a server, \&quot;supported by the system\&quot; means the system hosts/produces a set of resources that are conformant to a particular profile, and allows clients that use its services to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile. See further discussion in [Using Profiles]{profiling.html#profile-uses}
1919     * </p> 
1920         */
1921        public java.util.List<ResourceReferenceDt> getProfile() {  
1922                if (myProfile == null) {
1923                        myProfile = new java.util.ArrayList<ResourceReferenceDt>();
1924                }
1925                return myProfile;
1926        }
1927
1928        /**
1929         * Sets the value(s) for <b>profile</b> ()
1930         *
1931     * <p>
1932     * <b>Definition:</b>
1933     * A list of profiles that represent different use cases supported by the system. For a server, \&quot;supported by the system\&quot; means the system hosts/produces a set of resources that are conformant to a particular profile, and allows clients that use its services to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile. See further discussion in [Using Profiles]{profiling.html#profile-uses}
1934     * </p> 
1935         */
1936        public Conformance setProfile(java.util.List<ResourceReferenceDt> theValue) {
1937                myProfile = theValue;
1938                return this;
1939        }
1940        
1941        
1942
1943        /**
1944         * Adds and returns a new value for <b>profile</b> ()
1945         *
1946     * <p>
1947     * <b>Definition:</b>
1948     * A list of profiles that represent different use cases supported by the system. For a server, \&quot;supported by the system\&quot; means the system hosts/produces a set of resources that are conformant to a particular profile, and allows clients that use its services to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile. See further discussion in [Using Profiles]{profiling.html#profile-uses}
1949     * </p> 
1950         */
1951        public ResourceReferenceDt addProfile() {
1952                ResourceReferenceDt newType = new ResourceReferenceDt();
1953                getProfile().add(newType);
1954                return newType; 
1955        }
1956  
1957        /**
1958         * Gets the value(s) for <b>rest</b> ().
1959         * creating it if it does
1960         * not exist. Will not return <code>null</code>.
1961         *
1962     * <p>
1963     * <b>Definition:</b>
1964     * A definition of the restful capabilities of the solution, if any
1965     * </p> 
1966         */
1967        public java.util.List<Rest> getRest() {  
1968                if (myRest == null) {
1969                        myRest = new java.util.ArrayList<Rest>();
1970                }
1971                return myRest;
1972        }
1973
1974        /**
1975         * Sets the value(s) for <b>rest</b> ()
1976         *
1977     * <p>
1978     * <b>Definition:</b>
1979     * A definition of the restful capabilities of the solution, if any
1980     * </p> 
1981         */
1982        public Conformance setRest(java.util.List<Rest> theValue) {
1983                myRest = theValue;
1984                return this;
1985        }
1986        
1987        
1988
1989        /**
1990         * Adds and returns a new value for <b>rest</b> ()
1991         *
1992     * <p>
1993     * <b>Definition:</b>
1994     * A definition of the restful capabilities of the solution, if any
1995     * </p> 
1996         */
1997        public Rest addRest() {
1998                Rest newType = new Rest();
1999                getRest().add(newType);
2000                return newType; 
2001        }
2002
2003        /**
2004         * Adds a given new value for <b>rest</b> ()
2005         *
2006         * <p>
2007         * <b>Definition:</b>
2008         * A definition of the restful capabilities of the solution, if any
2009         * </p>
2010         * @param theValue The rest to add (must not be <code>null</code>)
2011         */
2012        public Conformance addRest(Rest theValue) {
2013                if (theValue == null) {
2014                        throw new NullPointerException("theValue must not be null");
2015                }
2016                getRest().add(theValue);
2017                return this;
2018        }
2019
2020        /**
2021         * Gets the first repetition for <b>rest</b> (),
2022         * creating it if it does not already exist.
2023         *
2024     * <p>
2025     * <b>Definition:</b>
2026     * A definition of the restful capabilities of the solution, if any
2027     * </p> 
2028         */
2029        public Rest getRestFirstRep() {
2030                if (getRest().isEmpty()) {
2031                        return addRest();
2032                }
2033                return getRest().get(0); 
2034        }
2035  
2036        /**
2037         * Gets the value(s) for <b>messaging</b> ().
2038         * creating it if it does
2039         * not exist. Will not return <code>null</code>.
2040         *
2041     * <p>
2042     * <b>Definition:</b>
2043     * A description of the messaging capabilities of the solution
2044     * </p> 
2045         */
2046        public java.util.List<Messaging> getMessaging() {  
2047                if (myMessaging == null) {
2048                        myMessaging = new java.util.ArrayList<Messaging>();
2049                }
2050                return myMessaging;
2051        }
2052
2053        /**
2054         * Sets the value(s) for <b>messaging</b> ()
2055         *
2056     * <p>
2057     * <b>Definition:</b>
2058     * A description of the messaging capabilities of the solution
2059     * </p> 
2060         */
2061        public Conformance setMessaging(java.util.List<Messaging> theValue) {
2062                myMessaging = theValue;
2063                return this;
2064        }
2065        
2066        
2067
2068        /**
2069         * Adds and returns a new value for <b>messaging</b> ()
2070         *
2071     * <p>
2072     * <b>Definition:</b>
2073     * A description of the messaging capabilities of the solution
2074     * </p> 
2075         */
2076        public Messaging addMessaging() {
2077                Messaging newType = new Messaging();
2078                getMessaging().add(newType);
2079                return newType; 
2080        }
2081
2082        /**
2083         * Adds a given new value for <b>messaging</b> ()
2084         *
2085         * <p>
2086         * <b>Definition:</b>
2087         * A description of the messaging capabilities of the solution
2088         * </p>
2089         * @param theValue The messaging to add (must not be <code>null</code>)
2090         */
2091        public Conformance addMessaging(Messaging theValue) {
2092                if (theValue == null) {
2093                        throw new NullPointerException("theValue must not be null");
2094                }
2095                getMessaging().add(theValue);
2096                return this;
2097        }
2098
2099        /**
2100         * Gets the first repetition for <b>messaging</b> (),
2101         * creating it if it does not already exist.
2102         *
2103     * <p>
2104     * <b>Definition:</b>
2105     * A description of the messaging capabilities of the solution
2106     * </p> 
2107         */
2108        public Messaging getMessagingFirstRep() {
2109                if (getMessaging().isEmpty()) {
2110                        return addMessaging();
2111                }
2112                return getMessaging().get(0); 
2113        }
2114  
2115        /**
2116         * Gets the value(s) for <b>document</b> ().
2117         * creating it if it does
2118         * not exist. Will not return <code>null</code>.
2119         *
2120     * <p>
2121     * <b>Definition:</b>
2122     * A document definition
2123     * </p> 
2124         */
2125        public java.util.List<Document> getDocument() {  
2126                if (myDocument == null) {
2127                        myDocument = new java.util.ArrayList<Document>();
2128                }
2129                return myDocument;
2130        }
2131
2132        /**
2133         * Sets the value(s) for <b>document</b> ()
2134         *
2135     * <p>
2136     * <b>Definition:</b>
2137     * A document definition
2138     * </p> 
2139         */
2140        public Conformance setDocument(java.util.List<Document> theValue) {
2141                myDocument = theValue;
2142                return this;
2143        }
2144        
2145        
2146
2147        /**
2148         * Adds and returns a new value for <b>document</b> ()
2149         *
2150     * <p>
2151     * <b>Definition:</b>
2152     * A document definition
2153     * </p> 
2154         */
2155        public Document addDocument() {
2156                Document newType = new Document();
2157                getDocument().add(newType);
2158                return newType; 
2159        }
2160
2161        /**
2162         * Adds a given new value for <b>document</b> ()
2163         *
2164         * <p>
2165         * <b>Definition:</b>
2166         * A document definition
2167         * </p>
2168         * @param theValue The document to add (must not be <code>null</code>)
2169         */
2170        public Conformance addDocument(Document theValue) {
2171                if (theValue == null) {
2172                        throw new NullPointerException("theValue must not be null");
2173                }
2174                getDocument().add(theValue);
2175                return this;
2176        }
2177
2178        /**
2179         * Gets the first repetition for <b>document</b> (),
2180         * creating it if it does not already exist.
2181         *
2182     * <p>
2183     * <b>Definition:</b>
2184     * A document definition
2185     * </p> 
2186         */
2187        public Document getDocumentFirstRep() {
2188                if (getDocument().isEmpty()) {
2189                        return addDocument();
2190                }
2191                return getDocument().get(0); 
2192        }
2193  
2194        /**
2195         * Block class for child element: <b>Conformance.contact</b> ()
2196         *
2197     * <p>
2198     * <b>Definition:</b>
2199     * Contacts to assist a user in finding and communicating with the publisher
2200     * </p> 
2201         */
2202        @Block()        
2203        public static class Contact 
2204            extends  BaseIdentifiableElement        implements IResourceBlock {
2205        
2206        @Child(name="name", type=StringDt.class, order=0, min=0, max=1, summary=true, modifier=false)   
2207        @Description(
2208                shortDefinition="",
2209                formalDefinition="The name of an individual to contact regarding the conformance"
2210        )
2211        private StringDt myName;
2212        
2213        @Child(name="telecom", type=ContactPointDt.class, order=1, min=0, max=Child.MAX_UNLIMITED, summary=true, modifier=false)        
2214        @Description(
2215                shortDefinition="",
2216                formalDefinition="Contact details for individual (if a name was provided) or the publisher"
2217        )
2218        private java.util.List<ContactPointDt> myTelecom;
2219        
2220
2221        @Override
2222        public boolean isEmpty() {
2223                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myName,  myTelecom);
2224        }
2225        
2226        @Override
2227        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
2228                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myName, myTelecom);
2229        }
2230
2231        /**
2232         * Gets the value(s) for <b>name</b> ().
2233         * creating it if it does
2234         * not exist. Will not return <code>null</code>.
2235         *
2236     * <p>
2237     * <b>Definition:</b>
2238     * The name of an individual to contact regarding the conformance
2239     * </p> 
2240         */
2241        public StringDt getNameElement() {  
2242                if (myName == null) {
2243                        myName = new StringDt();
2244                }
2245                return myName;
2246        }
2247
2248        
2249        /**
2250         * Gets the value(s) for <b>name</b> ().
2251         * creating it if it does
2252         * not exist. Will not return <code>null</code>.
2253         *
2254     * <p>
2255     * <b>Definition:</b>
2256     * The name of an individual to contact regarding the conformance
2257     * </p> 
2258         */
2259        public String getName() {  
2260                return getNameElement().getValue();
2261        }
2262
2263        /**
2264         * Sets the value(s) for <b>name</b> ()
2265         *
2266     * <p>
2267     * <b>Definition:</b>
2268     * The name of an individual to contact regarding the conformance
2269     * </p> 
2270         */
2271        public Contact setName(StringDt theValue) {
2272                myName = theValue;
2273                return this;
2274        }
2275        
2276        
2277
2278        /**
2279         * Sets the value for <b>name</b> ()
2280         *
2281     * <p>
2282     * <b>Definition:</b>
2283     * The name of an individual to contact regarding the conformance
2284     * </p> 
2285         */
2286        public Contact setName( String theString) {
2287                myName = new StringDt(theString); 
2288                return this; 
2289        }
2290
2291 
2292        /**
2293         * Gets the value(s) for <b>telecom</b> ().
2294         * creating it if it does
2295         * not exist. Will not return <code>null</code>.
2296         *
2297     * <p>
2298     * <b>Definition:</b>
2299     * Contact details for individual (if a name was provided) or the publisher
2300     * </p> 
2301         */
2302        public java.util.List<ContactPointDt> getTelecom() {  
2303                if (myTelecom == null) {
2304                        myTelecom = new java.util.ArrayList<ContactPointDt>();
2305                }
2306                return myTelecom;
2307        }
2308
2309        /**
2310         * Sets the value(s) for <b>telecom</b> ()
2311         *
2312     * <p>
2313     * <b>Definition:</b>
2314     * Contact details for individual (if a name was provided) or the publisher
2315     * </p> 
2316         */
2317        public Contact setTelecom(java.util.List<ContactPointDt> theValue) {
2318                myTelecom = theValue;
2319                return this;
2320        }
2321        
2322        
2323
2324        /**
2325         * Adds and returns a new value for <b>telecom</b> ()
2326         *
2327     * <p>
2328     * <b>Definition:</b>
2329     * Contact details for individual (if a name was provided) or the publisher
2330     * </p> 
2331         */
2332        public ContactPointDt addTelecom() {
2333                ContactPointDt newType = new ContactPointDt();
2334                getTelecom().add(newType);
2335                return newType; 
2336        }
2337
2338        /**
2339         * Adds a given new value for <b>telecom</b> ()
2340         *
2341         * <p>
2342         * <b>Definition:</b>
2343         * Contact details for individual (if a name was provided) or the publisher
2344         * </p>
2345         * @param theValue The telecom to add (must not be <code>null</code>)
2346         */
2347        public Contact addTelecom(ContactPointDt theValue) {
2348                if (theValue == null) {
2349                        throw new NullPointerException("theValue must not be null");
2350                }
2351                getTelecom().add(theValue);
2352                return this;
2353        }
2354
2355        /**
2356         * Gets the first repetition for <b>telecom</b> (),
2357         * creating it if it does not already exist.
2358         *
2359     * <p>
2360     * <b>Definition:</b>
2361     * Contact details for individual (if a name was provided) or the publisher
2362     * </p> 
2363         */
2364        public ContactPointDt getTelecomFirstRep() {
2365                if (getTelecom().isEmpty()) {
2366                        return addTelecom();
2367                }
2368                return getTelecom().get(0); 
2369        }
2370  
2371
2372
2373        }
2374
2375
2376        /**
2377         * Block class for child element: <b>Conformance.software</b> ()
2378         *
2379     * <p>
2380     * <b>Definition:</b>
2381     * Software that is covered by this conformance statement.  It is used when the conformance statement describes the capabilities of a particular software version, independent of an installation.
2382     * </p> 
2383         */
2384        @Block()        
2385        public static class Software 
2386            extends  BaseIdentifiableElement        implements IResourceBlock {
2387        
2388        @Child(name="name", type=StringDt.class, order=0, min=1, max=1, summary=true, modifier=false)   
2389        @Description(
2390                shortDefinition="",
2391                formalDefinition="Name software is known by"
2392        )
2393        private StringDt myName;
2394        
2395        @Child(name="version", type=StringDt.class, order=1, min=0, max=1, summary=true, modifier=false)        
2396        @Description(
2397                shortDefinition="",
2398                formalDefinition="The version identifier for the software covered by this statement"
2399        )
2400        private StringDt myVersion;
2401        
2402        @Child(name="releaseDate", type=DateTimeDt.class, order=2, min=0, max=1, summary=true, modifier=false)  
2403        @Description(
2404                shortDefinition="",
2405                formalDefinition="Date this version of the software released"
2406        )
2407        private DateTimeDt myReleaseDate;
2408        
2409
2410        @Override
2411        public boolean isEmpty() {
2412                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myName,  myVersion,  myReleaseDate);
2413        }
2414        
2415        @Override
2416        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
2417                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myName, myVersion, myReleaseDate);
2418        }
2419
2420        /**
2421         * Gets the value(s) for <b>name</b> ().
2422         * creating it if it does
2423         * not exist. Will not return <code>null</code>.
2424         *
2425     * <p>
2426     * <b>Definition:</b>
2427     * Name software is known by
2428     * </p> 
2429         */
2430        public StringDt getNameElement() {  
2431                if (myName == null) {
2432                        myName = new StringDt();
2433                }
2434                return myName;
2435        }
2436
2437        
2438        /**
2439         * Gets the value(s) for <b>name</b> ().
2440         * creating it if it does
2441         * not exist. Will not return <code>null</code>.
2442         *
2443     * <p>
2444     * <b>Definition:</b>
2445     * Name software is known by
2446     * </p> 
2447         */
2448        public String getName() {  
2449                return getNameElement().getValue();
2450        }
2451
2452        /**
2453         * Sets the value(s) for <b>name</b> ()
2454         *
2455     * <p>
2456     * <b>Definition:</b>
2457     * Name software is known by
2458     * </p> 
2459         */
2460        public Software setName(StringDt theValue) {
2461                myName = theValue;
2462                return this;
2463        }
2464        
2465        
2466
2467        /**
2468         * Sets the value for <b>name</b> ()
2469         *
2470     * <p>
2471     * <b>Definition:</b>
2472     * Name software is known by
2473     * </p> 
2474         */
2475        public Software setName( String theString) {
2476                myName = new StringDt(theString); 
2477                return this; 
2478        }
2479
2480 
2481        /**
2482         * Gets the value(s) for <b>version</b> ().
2483         * creating it if it does
2484         * not exist. Will not return <code>null</code>.
2485         *
2486     * <p>
2487     * <b>Definition:</b>
2488     * The version identifier for the software covered by this statement
2489     * </p> 
2490         */
2491        public StringDt getVersionElement() {  
2492                if (myVersion == null) {
2493                        myVersion = new StringDt();
2494                }
2495                return myVersion;
2496        }
2497
2498        
2499        /**
2500         * Gets the value(s) for <b>version</b> ().
2501         * creating it if it does
2502         * not exist. Will not return <code>null</code>.
2503         *
2504     * <p>
2505     * <b>Definition:</b>
2506     * The version identifier for the software covered by this statement
2507     * </p> 
2508         */
2509        public String getVersion() {  
2510                return getVersionElement().getValue();
2511        }
2512
2513        /**
2514         * Sets the value(s) for <b>version</b> ()
2515         *
2516     * <p>
2517     * <b>Definition:</b>
2518     * The version identifier for the software covered by this statement
2519     * </p> 
2520         */
2521        public Software setVersion(StringDt theValue) {
2522                myVersion = theValue;
2523                return this;
2524        }
2525        
2526        
2527
2528        /**
2529         * Sets the value for <b>version</b> ()
2530         *
2531     * <p>
2532     * <b>Definition:</b>
2533     * The version identifier for the software covered by this statement
2534     * </p> 
2535         */
2536        public Software setVersion( String theString) {
2537                myVersion = new StringDt(theString); 
2538                return this; 
2539        }
2540
2541 
2542        /**
2543         * Gets the value(s) for <b>releaseDate</b> ().
2544         * creating it if it does
2545         * not exist. Will not return <code>null</code>.
2546         *
2547     * <p>
2548     * <b>Definition:</b>
2549     * Date this version of the software released
2550     * </p> 
2551         */
2552        public DateTimeDt getReleaseDateElement() {  
2553                if (myReleaseDate == null) {
2554                        myReleaseDate = new DateTimeDt();
2555                }
2556                return myReleaseDate;
2557        }
2558
2559        
2560        /**
2561         * Gets the value(s) for <b>releaseDate</b> ().
2562         * creating it if it does
2563         * not exist. Will not return <code>null</code>.
2564         *
2565     * <p>
2566     * <b>Definition:</b>
2567     * Date this version of the software released
2568     * </p> 
2569         */
2570        public Date getReleaseDate() {  
2571                return getReleaseDateElement().getValue();
2572        }
2573
2574        /**
2575         * Sets the value(s) for <b>releaseDate</b> ()
2576         *
2577     * <p>
2578     * <b>Definition:</b>
2579     * Date this version of the software released
2580     * </p> 
2581         */
2582        public Software setReleaseDate(DateTimeDt theValue) {
2583                myReleaseDate = theValue;
2584                return this;
2585        }
2586        
2587        
2588
2589        /**
2590         * Sets the value for <b>releaseDate</b> ()
2591         *
2592     * <p>
2593     * <b>Definition:</b>
2594     * Date this version of the software released
2595     * </p> 
2596         */
2597        public Software setReleaseDate( Date theDate,  TemporalPrecisionEnum thePrecision) {
2598                myReleaseDate = new DateTimeDt(theDate, thePrecision); 
2599                return this; 
2600        }
2601
2602        /**
2603         * Sets the value for <b>releaseDate</b> ()
2604         *
2605     * <p>
2606     * <b>Definition:</b>
2607     * Date this version of the software released
2608     * </p> 
2609         */
2610        public Software setReleaseDateWithSecondsPrecision( Date theDate) {
2611                myReleaseDate = new DateTimeDt(theDate); 
2612                return this; 
2613        }
2614
2615 
2616
2617
2618        }
2619
2620
2621        /**
2622         * Block class for child element: <b>Conformance.implementation</b> ()
2623         *
2624     * <p>
2625     * <b>Definition:</b>
2626     * Identifies a specific implementation instance that is described by the conformance statement - i.e. a particular installation, rather than the capabilities of a software program
2627     * </p> 
2628         */
2629        @Block()        
2630        public static class Implementation 
2631            extends  BaseIdentifiableElement        implements IResourceBlock {
2632        
2633        @Child(name="description", type=StringDt.class, order=0, min=1, max=1, summary=true, modifier=false)    
2634        @Description(
2635                shortDefinition="",
2636                formalDefinition="Information about the specific installation that this conformance statement relates to"
2637        )
2638        private StringDt myDescription;
2639        
2640        @Child(name="url", type=UriDt.class, order=1, min=0, max=1, summary=true, modifier=false)       
2641        @Description(
2642                shortDefinition="",
2643                formalDefinition="An absolute base URL for the implementation.  This forms the base for REST interfaces as well as the mailbox and document interfaces."
2644        )
2645        private UriDt myUrl;
2646        
2647
2648        @Override
2649        public boolean isEmpty() {
2650                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myDescription,  myUrl);
2651        }
2652        
2653        @Override
2654        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
2655                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myDescription, myUrl);
2656        }
2657
2658        /**
2659         * Gets the value(s) for <b>description</b> ().
2660         * creating it if it does
2661         * not exist. Will not return <code>null</code>.
2662         *
2663     * <p>
2664     * <b>Definition:</b>
2665     * Information about the specific installation that this conformance statement relates to
2666     * </p> 
2667         */
2668        public StringDt getDescriptionElement() {  
2669                if (myDescription == null) {
2670                        myDescription = new StringDt();
2671                }
2672                return myDescription;
2673        }
2674
2675        
2676        /**
2677         * Gets the value(s) for <b>description</b> ().
2678         * creating it if it does
2679         * not exist. Will not return <code>null</code>.
2680         *
2681     * <p>
2682     * <b>Definition:</b>
2683     * Information about the specific installation that this conformance statement relates to
2684     * </p> 
2685         */
2686        public String getDescription() {  
2687                return getDescriptionElement().getValue();
2688        }
2689
2690        /**
2691         * Sets the value(s) for <b>description</b> ()
2692         *
2693     * <p>
2694     * <b>Definition:</b>
2695     * Information about the specific installation that this conformance statement relates to
2696     * </p> 
2697         */
2698        public Implementation setDescription(StringDt theValue) {
2699                myDescription = theValue;
2700                return this;
2701        }
2702        
2703        
2704
2705        /**
2706         * Sets the value for <b>description</b> ()
2707         *
2708     * <p>
2709     * <b>Definition:</b>
2710     * Information about the specific installation that this conformance statement relates to
2711     * </p> 
2712         */
2713        public Implementation setDescription( String theString) {
2714                myDescription = new StringDt(theString); 
2715                return this; 
2716        }
2717
2718 
2719        /**
2720         * Gets the value(s) for <b>url</b> ().
2721         * creating it if it does
2722         * not exist. Will not return <code>null</code>.
2723         *
2724     * <p>
2725     * <b>Definition:</b>
2726     * An absolute base URL for the implementation.  This forms the base for REST interfaces as well as the mailbox and document interfaces.
2727     * </p> 
2728         */
2729        public UriDt getUrlElement() {  
2730                if (myUrl == null) {
2731                        myUrl = new UriDt();
2732                }
2733                return myUrl;
2734        }
2735
2736        
2737        /**
2738         * Gets the value(s) for <b>url</b> ().
2739         * creating it if it does
2740         * not exist. Will not return <code>null</code>.
2741         *
2742     * <p>
2743     * <b>Definition:</b>
2744     * An absolute base URL for the implementation.  This forms the base for REST interfaces as well as the mailbox and document interfaces.
2745     * </p> 
2746         */
2747        public String getUrl() {  
2748                return getUrlElement().getValue();
2749        }
2750
2751        /**
2752         * Sets the value(s) for <b>url</b> ()
2753         *
2754     * <p>
2755     * <b>Definition:</b>
2756     * An absolute base URL for the implementation.  This forms the base for REST interfaces as well as the mailbox and document interfaces.
2757     * </p> 
2758         */
2759        public Implementation setUrl(UriDt theValue) {
2760                myUrl = theValue;
2761                return this;
2762        }
2763        
2764        
2765
2766        /**
2767         * Sets the value for <b>url</b> ()
2768         *
2769     * <p>
2770     * <b>Definition:</b>
2771     * An absolute base URL for the implementation.  This forms the base for REST interfaces as well as the mailbox and document interfaces.
2772     * </p> 
2773         */
2774        public Implementation setUrl( String theUri) {
2775                myUrl = new UriDt(theUri); 
2776                return this; 
2777        }
2778
2779 
2780
2781
2782        }
2783
2784
2785        /**
2786         * Block class for child element: <b>Conformance.rest</b> ()
2787         *
2788     * <p>
2789     * <b>Definition:</b>
2790     * A definition of the restful capabilities of the solution, if any
2791     * </p> 
2792         */
2793        @Block()        
2794        public static class Rest 
2795            extends  BaseIdentifiableElement        implements IResourceBlock {
2796        
2797        @Child(name="mode", type=CodeDt.class, order=0, min=1, max=1, summary=true, modifier=false)     
2798        @Description(
2799                shortDefinition="",
2800                formalDefinition="Identifies whether this portion of the statement is describing ability to initiate or receive restful operations"
2801        )
2802        private BoundCodeDt<RestfulConformanceModeEnum> myMode;
2803        
2804        @Child(name="documentation", type=StringDt.class, order=1, min=0, max=1, summary=false, modifier=false) 
2805        @Description(
2806                shortDefinition="",
2807                formalDefinition="Information about the system's restful capabilities that apply across all applications, such as security"
2808        )
2809        private StringDt myDocumentation;
2810        
2811        @Child(name="security", order=2, min=0, max=1, summary=false, modifier=false)   
2812        @Description(
2813                shortDefinition="",
2814                formalDefinition="Information about security implementation from an interface perspective - what a client needs to know"
2815        )
2816        private RestSecurity mySecurity;
2817        
2818        @Child(name="resource", order=3, min=1, max=Child.MAX_UNLIMITED, summary=true, modifier=false)  
2819        @Description(
2820                shortDefinition="",
2821                formalDefinition="A specification of the restful capabilities of the solution for a specific resource type"
2822        )
2823        private java.util.List<RestResource> myResource;
2824        
2825        @Child(name="interaction", order=4, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)      
2826        @Description(
2827                shortDefinition="",
2828                formalDefinition="A specification of restful operations supported by the system"
2829        )
2830        private java.util.List<RestInteraction> myInteraction;
2831        
2832        @Child(name="transactionMode", type=CodeDt.class, order=5, min=0, max=1, summary=false, modifier=false) 
2833        @Description(
2834                shortDefinition="",
2835                formalDefinition="A code that indicates how transactions are supported"
2836        )
2837        private BoundCodeDt<TransactionModeEnum> myTransactionMode;
2838        
2839        @Child(name="searchParam", type=RestResourceSearchParam.class, order=6, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)  
2840        @Description(
2841                shortDefinition="",
2842                formalDefinition="Search parameters that are supported for searching all resources for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation"
2843        )
2844        private java.util.List<RestResourceSearchParam> mySearchParam;
2845        
2846        @Child(name="operation", order=7, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)        
2847        @Description(
2848                shortDefinition="",
2849                formalDefinition="Definition of an operation or a named query and with its parameters and their meaning and type"
2850        )
2851        private java.util.List<RestOperation> myOperation;
2852        
2853        @Child(name="compartment", type=UriDt.class, order=8, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)    
2854        @Description(
2855                shortDefinition="",
2856                formalDefinition="An absolute URI which is a reference to the definition of a compartment hosted by the system"
2857        )
2858        private java.util.List<UriDt> myCompartment;
2859        
2860
2861        @Override
2862        public boolean isEmpty() {
2863                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myMode,  myDocumentation,  mySecurity,  myResource,  myInteraction,  myTransactionMode,  mySearchParam,  myOperation,  myCompartment);
2864        }
2865        
2866        @Override
2867        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
2868                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myMode, myDocumentation, mySecurity, myResource, myInteraction, myTransactionMode, mySearchParam, myOperation, myCompartment);
2869        }
2870
2871        /**
2872         * Gets the value(s) for <b>mode</b> ().
2873         * creating it if it does
2874         * not exist. Will not return <code>null</code>.
2875         *
2876     * <p>
2877     * <b>Definition:</b>
2878     * Identifies whether this portion of the statement is describing ability to initiate or receive restful operations
2879     * </p> 
2880         */
2881        public BoundCodeDt<RestfulConformanceModeEnum> getModeElement() {  
2882                if (myMode == null) {
2883                        myMode = new BoundCodeDt<RestfulConformanceModeEnum>(RestfulConformanceModeEnum.VALUESET_BINDER);
2884                }
2885                return myMode;
2886        }
2887
2888        
2889        /**
2890         * Gets the value(s) for <b>mode</b> ().
2891         * creating it if it does
2892         * not exist. Will not return <code>null</code>.
2893         *
2894     * <p>
2895     * <b>Definition:</b>
2896     * Identifies whether this portion of the statement is describing ability to initiate or receive restful operations
2897     * </p> 
2898         */
2899        public String getMode() {  
2900                return getModeElement().getValue();
2901        }
2902
2903        /**
2904         * Sets the value(s) for <b>mode</b> ()
2905         *
2906     * <p>
2907     * <b>Definition:</b>
2908     * Identifies whether this portion of the statement is describing ability to initiate or receive restful operations
2909     * </p> 
2910         */
2911        public Rest setMode(BoundCodeDt<RestfulConformanceModeEnum> theValue) {
2912                myMode = theValue;
2913                return this;
2914        }
2915        
2916        
2917
2918        /**
2919         * Sets the value(s) for <b>mode</b> ()
2920         *
2921     * <p>
2922     * <b>Definition:</b>
2923     * Identifies whether this portion of the statement is describing ability to initiate or receive restful operations
2924     * </p> 
2925         */
2926        public Rest setMode(RestfulConformanceModeEnum theValue) {
2927                setMode(new BoundCodeDt<RestfulConformanceModeEnum>(RestfulConformanceModeEnum.VALUESET_BINDER, theValue));
2928                
2929/*
2930                getModeElement().setValueAsEnum(theValue);
2931*/
2932                return this;
2933        }
2934
2935  
2936        /**
2937         * Gets the value(s) for <b>documentation</b> ().
2938         * creating it if it does
2939         * not exist. Will not return <code>null</code>.
2940         *
2941     * <p>
2942     * <b>Definition:</b>
2943     * Information about the system's restful capabilities that apply across all applications, such as security
2944     * </p> 
2945         */
2946        public StringDt getDocumentationElement() {  
2947                if (myDocumentation == null) {
2948                        myDocumentation = new StringDt();
2949                }
2950                return myDocumentation;
2951        }
2952
2953        
2954        /**
2955         * Gets the value(s) for <b>documentation</b> ().
2956         * creating it if it does
2957         * not exist. Will not return <code>null</code>.
2958         *
2959     * <p>
2960     * <b>Definition:</b>
2961     * Information about the system's restful capabilities that apply across all applications, such as security
2962     * </p> 
2963         */
2964        public String getDocumentation() {  
2965                return getDocumentationElement().getValue();
2966        }
2967
2968        /**
2969         * Sets the value(s) for <b>documentation</b> ()
2970         *
2971     * <p>
2972     * <b>Definition:</b>
2973     * Information about the system's restful capabilities that apply across all applications, such as security
2974     * </p> 
2975         */
2976        public Rest setDocumentation(StringDt theValue) {
2977                myDocumentation = theValue;
2978                return this;
2979        }
2980        
2981        
2982
2983        /**
2984         * Sets the value for <b>documentation</b> ()
2985         *
2986     * <p>
2987     * <b>Definition:</b>
2988     * Information about the system's restful capabilities that apply across all applications, such as security
2989     * </p> 
2990         */
2991        public Rest setDocumentation( String theString) {
2992                myDocumentation = new StringDt(theString); 
2993                return this; 
2994        }
2995
2996 
2997        /**
2998         * Gets the value(s) for <b>security</b> ().
2999         * creating it if it does
3000         * not exist. Will not return <code>null</code>.
3001         *
3002     * <p>
3003     * <b>Definition:</b>
3004     * Information about security implementation from an interface perspective - what a client needs to know
3005     * </p> 
3006         */
3007        public RestSecurity getSecurity() {  
3008                if (mySecurity == null) {
3009                        mySecurity = new RestSecurity();
3010                }
3011                return mySecurity;
3012        }
3013
3014        /**
3015         * Sets the value(s) for <b>security</b> ()
3016         *
3017     * <p>
3018     * <b>Definition:</b>
3019     * Information about security implementation from an interface perspective - what a client needs to know
3020     * </p> 
3021         */
3022        public Rest setSecurity(RestSecurity theValue) {
3023                mySecurity = theValue;
3024                return this;
3025        }
3026        
3027        
3028
3029  
3030        /**
3031         * Gets the value(s) for <b>resource</b> ().
3032         * creating it if it does
3033         * not exist. Will not return <code>null</code>.
3034         *
3035     * <p>
3036     * <b>Definition:</b>
3037     * A specification of the restful capabilities of the solution for a specific resource type
3038     * </p> 
3039         */
3040        public java.util.List<RestResource> getResource() {  
3041                if (myResource == null) {
3042                        myResource = new java.util.ArrayList<RestResource>();
3043                }
3044                return myResource;
3045        }
3046
3047        /**
3048         * Sets the value(s) for <b>resource</b> ()
3049         *
3050     * <p>
3051     * <b>Definition:</b>
3052     * A specification of the restful capabilities of the solution for a specific resource type
3053     * </p> 
3054         */
3055        public Rest setResource(java.util.List<RestResource> theValue) {
3056                myResource = theValue;
3057                return this;
3058        }
3059        
3060        
3061
3062        /**
3063         * Adds and returns a new value for <b>resource</b> ()
3064         *
3065     * <p>
3066     * <b>Definition:</b>
3067     * A specification of the restful capabilities of the solution for a specific resource type
3068     * </p> 
3069         */
3070        public RestResource addResource() {
3071                RestResource newType = new RestResource();
3072                getResource().add(newType);
3073                return newType; 
3074        }
3075
3076        /**
3077         * Adds a given new value for <b>resource</b> ()
3078         *
3079         * <p>
3080         * <b>Definition:</b>
3081         * A specification of the restful capabilities of the solution for a specific resource type
3082         * </p>
3083         * @param theValue The resource to add (must not be <code>null</code>)
3084         */
3085        public Rest addResource(RestResource theValue) {
3086                if (theValue == null) {
3087                        throw new NullPointerException("theValue must not be null");
3088                }
3089                getResource().add(theValue);
3090                return this;
3091        }
3092
3093        /**
3094         * Gets the first repetition for <b>resource</b> (),
3095         * creating it if it does not already exist.
3096         *
3097     * <p>
3098     * <b>Definition:</b>
3099     * A specification of the restful capabilities of the solution for a specific resource type
3100     * </p> 
3101         */
3102        public RestResource getResourceFirstRep() {
3103                if (getResource().isEmpty()) {
3104                        return addResource();
3105                }
3106                return getResource().get(0); 
3107        }
3108  
3109        /**
3110         * Gets the value(s) for <b>interaction</b> ().
3111         * creating it if it does
3112         * not exist. Will not return <code>null</code>.
3113         *
3114     * <p>
3115     * <b>Definition:</b>
3116     * A specification of restful operations supported by the system
3117     * </p> 
3118         */
3119        public java.util.List<RestInteraction> getInteraction() {  
3120                if (myInteraction == null) {
3121                        myInteraction = new java.util.ArrayList<RestInteraction>();
3122                }
3123                return myInteraction;
3124        }
3125
3126        /**
3127         * Sets the value(s) for <b>interaction</b> ()
3128         *
3129     * <p>
3130     * <b>Definition:</b>
3131     * A specification of restful operations supported by the system
3132     * </p> 
3133         */
3134        public Rest setInteraction(java.util.List<RestInteraction> theValue) {
3135                myInteraction = theValue;
3136                return this;
3137        }
3138        
3139        
3140
3141        /**
3142         * Adds and returns a new value for <b>interaction</b> ()
3143         *
3144     * <p>
3145     * <b>Definition:</b>
3146     * A specification of restful operations supported by the system
3147     * </p> 
3148         */
3149        public RestInteraction addInteraction() {
3150                RestInteraction newType = new RestInteraction();
3151                getInteraction().add(newType);
3152                return newType; 
3153        }
3154
3155        /**
3156         * Adds a given new value for <b>interaction</b> ()
3157         *
3158         * <p>
3159         * <b>Definition:</b>
3160         * A specification of restful operations supported by the system
3161         * </p>
3162         * @param theValue The interaction to add (must not be <code>null</code>)
3163         */
3164        public Rest addInteraction(RestInteraction theValue) {
3165                if (theValue == null) {
3166                        throw new NullPointerException("theValue must not be null");
3167                }
3168                getInteraction().add(theValue);
3169                return this;
3170        }
3171
3172        /**
3173         * Gets the first repetition for <b>interaction</b> (),
3174         * creating it if it does not already exist.
3175         *
3176     * <p>
3177     * <b>Definition:</b>
3178     * A specification of restful operations supported by the system
3179     * </p> 
3180         */
3181        public RestInteraction getInteractionFirstRep() {
3182                if (getInteraction().isEmpty()) {
3183                        return addInteraction();
3184                }
3185                return getInteraction().get(0); 
3186        }
3187  
3188        /**
3189         * Gets the value(s) for <b>transactionMode</b> ().
3190         * creating it if it does
3191         * not exist. Will not return <code>null</code>.
3192         *
3193     * <p>
3194     * <b>Definition:</b>
3195     * A code that indicates how transactions are supported
3196     * </p> 
3197         */
3198        public BoundCodeDt<TransactionModeEnum> getTransactionModeElement() {  
3199                if (myTransactionMode == null) {
3200                        myTransactionMode = new BoundCodeDt<TransactionModeEnum>(TransactionModeEnum.VALUESET_BINDER);
3201                }
3202                return myTransactionMode;
3203        }
3204
3205        
3206        /**
3207         * Gets the value(s) for <b>transactionMode</b> ().
3208         * creating it if it does
3209         * not exist. Will not return <code>null</code>.
3210         *
3211     * <p>
3212     * <b>Definition:</b>
3213     * A code that indicates how transactions are supported
3214     * </p> 
3215         */
3216        public String getTransactionMode() {  
3217                return getTransactionModeElement().getValue();
3218        }
3219
3220        /**
3221         * Sets the value(s) for <b>transactionMode</b> ()
3222         *
3223     * <p>
3224     * <b>Definition:</b>
3225     * A code that indicates how transactions are supported
3226     * </p> 
3227         */
3228        public Rest setTransactionMode(BoundCodeDt<TransactionModeEnum> theValue) {
3229                myTransactionMode = theValue;
3230                return this;
3231        }
3232        
3233        
3234
3235        /**
3236         * Sets the value(s) for <b>transactionMode</b> ()
3237         *
3238     * <p>
3239     * <b>Definition:</b>
3240     * A code that indicates how transactions are supported
3241     * </p> 
3242         */
3243        public Rest setTransactionMode(TransactionModeEnum theValue) {
3244                setTransactionMode(new BoundCodeDt<TransactionModeEnum>(TransactionModeEnum.VALUESET_BINDER, theValue));
3245                
3246/*
3247                getTransactionModeElement().setValueAsEnum(theValue);
3248*/
3249                return this;
3250        }
3251
3252  
3253        /**
3254         * Gets the value(s) for <b>searchParam</b> ().
3255         * creating it if it does
3256         * not exist. Will not return <code>null</code>.
3257         *
3258     * <p>
3259     * <b>Definition:</b>
3260     * Search parameters that are supported for searching all resources for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation
3261     * </p> 
3262         */
3263        public java.util.List<RestResourceSearchParam> getSearchParam() {  
3264                if (mySearchParam == null) {
3265                        mySearchParam = new java.util.ArrayList<RestResourceSearchParam>();
3266                }
3267                return mySearchParam;
3268        }
3269
3270        /**
3271         * Sets the value(s) for <b>searchParam</b> ()
3272         *
3273     * <p>
3274     * <b>Definition:</b>
3275     * Search parameters that are supported for searching all resources for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation
3276     * </p> 
3277         */
3278        public Rest setSearchParam(java.util.List<RestResourceSearchParam> theValue) {
3279                mySearchParam = theValue;
3280                return this;
3281        }
3282        
3283        
3284
3285        /**
3286         * Adds and returns a new value for <b>searchParam</b> ()
3287         *
3288     * <p>
3289     * <b>Definition:</b>
3290     * Search parameters that are supported for searching all resources for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation
3291     * </p> 
3292         */
3293        public RestResourceSearchParam addSearchParam() {
3294                RestResourceSearchParam newType = new RestResourceSearchParam();
3295                getSearchParam().add(newType);
3296                return newType; 
3297        }
3298
3299        /**
3300         * Adds a given new value for <b>searchParam</b> ()
3301         *
3302         * <p>
3303         * <b>Definition:</b>
3304         * Search parameters that are supported for searching all resources for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation
3305         * </p>
3306         * @param theValue The searchParam to add (must not be <code>null</code>)
3307         */
3308        public Rest addSearchParam(RestResourceSearchParam theValue) {
3309                if (theValue == null) {
3310                        throw new NullPointerException("theValue must not be null");
3311                }
3312                getSearchParam().add(theValue);
3313                return this;
3314        }
3315
3316        /**
3317         * Gets the first repetition for <b>searchParam</b> (),
3318         * creating it if it does not already exist.
3319         *
3320     * <p>
3321     * <b>Definition:</b>
3322     * Search parameters that are supported for searching all resources for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation
3323     * </p> 
3324         */
3325        public RestResourceSearchParam getSearchParamFirstRep() {
3326                if (getSearchParam().isEmpty()) {
3327                        return addSearchParam();
3328                }
3329                return getSearchParam().get(0); 
3330        }
3331  
3332        /**
3333         * Gets the value(s) for <b>operation</b> ().
3334         * creating it if it does
3335         * not exist. Will not return <code>null</code>.
3336         *
3337     * <p>
3338     * <b>Definition:</b>
3339     * Definition of an operation or a named query and with its parameters and their meaning and type
3340     * </p> 
3341         */
3342        public java.util.List<RestOperation> getOperation() {  
3343                if (myOperation == null) {
3344                        myOperation = new java.util.ArrayList<RestOperation>();
3345                }
3346                return myOperation;
3347        }
3348
3349        /**
3350         * Sets the value(s) for <b>operation</b> ()
3351         *
3352     * <p>
3353     * <b>Definition:</b>
3354     * Definition of an operation or a named query and with its parameters and their meaning and type
3355     * </p> 
3356         */
3357        public Rest setOperation(java.util.List<RestOperation> theValue) {
3358                myOperation = theValue;
3359                return this;
3360        }
3361        
3362        
3363
3364        /**
3365         * Adds and returns a new value for <b>operation</b> ()
3366         *
3367     * <p>
3368     * <b>Definition:</b>
3369     * Definition of an operation or a named query and with its parameters and their meaning and type
3370     * </p> 
3371         */
3372        public RestOperation addOperation() {
3373                RestOperation newType = new RestOperation();
3374                getOperation().add(newType);
3375                return newType; 
3376        }
3377
3378        /**
3379         * Adds a given new value for <b>operation</b> ()
3380         *
3381         * <p>
3382         * <b>Definition:</b>
3383         * Definition of an operation or a named query and with its parameters and their meaning and type
3384         * </p>
3385         * @param theValue The operation to add (must not be <code>null</code>)
3386         */
3387        public Rest addOperation(RestOperation theValue) {
3388                if (theValue == null) {
3389                        throw new NullPointerException("theValue must not be null");
3390                }
3391                getOperation().add(theValue);
3392                return this;
3393        }
3394
3395        /**
3396         * Gets the first repetition for <b>operation</b> (),
3397         * creating it if it does not already exist.
3398         *
3399     * <p>
3400     * <b>Definition:</b>
3401     * Definition of an operation or a named query and with its parameters and their meaning and type
3402     * </p> 
3403         */
3404        public RestOperation getOperationFirstRep() {
3405                if (getOperation().isEmpty()) {
3406                        return addOperation();
3407                }
3408                return getOperation().get(0); 
3409        }
3410  
3411        /**
3412         * Gets the value(s) for <b>compartment</b> ().
3413         * creating it if it does
3414         * not exist. Will not return <code>null</code>.
3415         *
3416     * <p>
3417     * <b>Definition:</b>
3418     * An absolute URI which is a reference to the definition of a compartment hosted by the system
3419     * </p> 
3420         */
3421        public java.util.List<UriDt> getCompartment() {  
3422                if (myCompartment == null) {
3423                        myCompartment = new java.util.ArrayList<UriDt>();
3424                }
3425                return myCompartment;
3426        }
3427
3428        /**
3429         * Sets the value(s) for <b>compartment</b> ()
3430         *
3431     * <p>
3432     * <b>Definition:</b>
3433     * An absolute URI which is a reference to the definition of a compartment hosted by the system
3434     * </p> 
3435         */
3436        public Rest setCompartment(java.util.List<UriDt> theValue) {
3437                myCompartment = theValue;
3438                return this;
3439        }
3440        
3441        
3442
3443        /**
3444         * Adds and returns a new value for <b>compartment</b> ()
3445         *
3446     * <p>
3447     * <b>Definition:</b>
3448     * An absolute URI which is a reference to the definition of a compartment hosted by the system
3449     * </p> 
3450         */
3451        public UriDt addCompartment() {
3452                UriDt newType = new UriDt();
3453                getCompartment().add(newType);
3454                return newType; 
3455        }
3456
3457        /**
3458         * Adds a given new value for <b>compartment</b> ()
3459         *
3460         * <p>
3461         * <b>Definition:</b>
3462         * An absolute URI which is a reference to the definition of a compartment hosted by the system
3463         * </p>
3464         * @param theValue The compartment to add (must not be <code>null</code>)
3465         */
3466        public Rest addCompartment(UriDt theValue) {
3467                if (theValue == null) {
3468                        throw new NullPointerException("theValue must not be null");
3469                }
3470                getCompartment().add(theValue);
3471                return this;
3472        }
3473
3474        /**
3475         * Gets the first repetition for <b>compartment</b> (),
3476         * creating it if it does not already exist.
3477         *
3478     * <p>
3479     * <b>Definition:</b>
3480     * An absolute URI which is a reference to the definition of a compartment hosted by the system
3481     * </p> 
3482         */
3483        public UriDt getCompartmentFirstRep() {
3484                if (getCompartment().isEmpty()) {
3485                        return addCompartment();
3486                }
3487                return getCompartment().get(0); 
3488        }
3489        /**
3490         * Adds a new value for <b>compartment</b> ()
3491         *
3492     * <p>
3493     * <b>Definition:</b>
3494     * An absolute URI which is a reference to the definition of a compartment hosted by the system
3495     * </p> 
3496     *
3497     * @return Returns a reference to this object, to allow for simple chaining.
3498         */
3499        public Rest addCompartment( String theUri) {
3500                if (myCompartment == null) {
3501                        myCompartment = new java.util.ArrayList<UriDt>();
3502                }
3503                myCompartment.add(new UriDt(theUri));
3504                return this; 
3505        }
3506
3507 
3508
3509
3510        }
3511
3512        /**
3513         * Block class for child element: <b>Conformance.rest.security</b> ()
3514         *
3515     * <p>
3516     * <b>Definition:</b>
3517     * Information about security implementation from an interface perspective - what a client needs to know
3518     * </p> 
3519         */
3520        @Block()        
3521        public static class RestSecurity 
3522            extends  BaseIdentifiableElement        implements IResourceBlock {
3523        
3524        @Child(name="cors", type=BooleanDt.class, order=0, min=0, max=1, summary=false, modifier=false) 
3525        @Description(
3526                shortDefinition="",
3527                formalDefinition="Server adds CORS headers when responding to requests - this enables javascript applications to use the server"
3528        )
3529        private BooleanDt myCors;
3530        
3531        @Child(name="service", type=CodeableConceptDt.class, order=1, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)    
3532        @Description(
3533                shortDefinition="",
3534                formalDefinition="Types of security services are supported/required by the system"
3535        )
3536        private java.util.List<BoundCodeableConceptDt<RestfulSecurityServiceEnum>> myService;
3537        
3538        @Child(name="description", type=StringDt.class, order=2, min=0, max=1, summary=false, modifier=false)   
3539        @Description(
3540                shortDefinition="",
3541                formalDefinition="General description of how security works"
3542        )
3543        private StringDt myDescription;
3544        
3545        @Child(name="certificate", order=3, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)      
3546        @Description(
3547                shortDefinition="",
3548                formalDefinition="Certificates associated with security profiles"
3549        )
3550        private java.util.List<RestSecurityCertificate> myCertificate;
3551        
3552
3553        @Override
3554        public boolean isEmpty() {
3555                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myCors,  myService,  myDescription,  myCertificate);
3556        }
3557        
3558        @Override
3559        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
3560                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myCors, myService, myDescription, myCertificate);
3561        }
3562
3563        /**
3564         * Gets the value(s) for <b>cors</b> ().
3565         * creating it if it does
3566         * not exist. Will not return <code>null</code>.
3567         *
3568     * <p>
3569     * <b>Definition:</b>
3570     * Server adds CORS headers when responding to requests - this enables javascript applications to use the server
3571     * </p> 
3572         */
3573        public BooleanDt getCorsElement() {  
3574                if (myCors == null) {
3575                        myCors = new BooleanDt();
3576                }
3577                return myCors;
3578        }
3579
3580        
3581        /**
3582         * Gets the value(s) for <b>cors</b> ().
3583         * creating it if it does
3584         * not exist. Will not return <code>null</code>.
3585         *
3586     * <p>
3587     * <b>Definition:</b>
3588     * Server adds CORS headers when responding to requests - this enables javascript applications to use the server
3589     * </p> 
3590         */
3591        public Boolean getCors() {  
3592                return getCorsElement().getValue();
3593        }
3594
3595        /**
3596         * Sets the value(s) for <b>cors</b> ()
3597         *
3598     * <p>
3599     * <b>Definition:</b>
3600     * Server adds CORS headers when responding to requests - this enables javascript applications to use the server
3601     * </p> 
3602         */
3603        public RestSecurity setCors(BooleanDt theValue) {
3604                myCors = theValue;
3605                return this;
3606        }
3607        
3608        
3609
3610        /**
3611         * Sets the value for <b>cors</b> ()
3612         *
3613     * <p>
3614     * <b>Definition:</b>
3615     * Server adds CORS headers when responding to requests - this enables javascript applications to use the server
3616     * </p> 
3617         */
3618        public RestSecurity setCors( boolean theBoolean) {
3619                myCors = new BooleanDt(theBoolean); 
3620                return this; 
3621        }
3622
3623 
3624        /**
3625         * Gets the value(s) for <b>service</b> ().
3626         * creating it if it does
3627         * not exist. Will not return <code>null</code>.
3628         *
3629     * <p>
3630     * <b>Definition:</b>
3631     * Types of security services are supported/required by the system
3632     * </p> 
3633         */
3634        public java.util.List<BoundCodeableConceptDt<RestfulSecurityServiceEnum>> getService() {  
3635                if (myService == null) {
3636                        myService = new java.util.ArrayList<BoundCodeableConceptDt<RestfulSecurityServiceEnum>>();
3637                }
3638                return myService;
3639        }
3640
3641        /**
3642         * Sets the value(s) for <b>service</b> ()
3643         *
3644     * <p>
3645     * <b>Definition:</b>
3646     * Types of security services are supported/required by the system
3647     * </p> 
3648         */
3649        public RestSecurity setService(java.util.List<BoundCodeableConceptDt<RestfulSecurityServiceEnum>> theValue) {
3650                myService = theValue;
3651                return this;
3652        }
3653        
3654        
3655
3656        /**
3657         * Add a value for <b>service</b> () using an enumerated type. This
3658         * is intended as a convenience method for situations where the FHIR defined ValueSets are mandatory
3659         * or contain the desirable codes. If you wish to use codes other than those which are built-in, 
3660         * you may also use the {@link #addService()} method.
3661         *
3662     * <p>
3663     * <b>Definition:</b>
3664     * Types of security services are supported/required by the system
3665     * </p> 
3666         */
3667        public BoundCodeableConceptDt<RestfulSecurityServiceEnum> addService(RestfulSecurityServiceEnum theValue) {
3668                BoundCodeableConceptDt<RestfulSecurityServiceEnum> retVal = new BoundCodeableConceptDt<RestfulSecurityServiceEnum>(RestfulSecurityServiceEnum.VALUESET_BINDER, theValue);
3669                getService().add(retVal);
3670                return retVal;
3671        }
3672
3673        /**
3674         * Gets the first repetition for <b>service</b> (),
3675         * creating it if it does not already exist.
3676         *
3677     * <p>
3678     * <b>Definition:</b>
3679     * Types of security services are supported/required by the system
3680     * </p> 
3681         */
3682        public BoundCodeableConceptDt<RestfulSecurityServiceEnum> getServiceFirstRep() {
3683                if (getService().size() == 0) {
3684                        addService();
3685                }
3686                return getService().get(0);
3687        }
3688
3689        /**
3690         * Add a value for <b>service</b> ()
3691         *
3692     * <p>
3693     * <b>Definition:</b>
3694     * Types of security services are supported/required by the system
3695     * </p> 
3696         */
3697        public BoundCodeableConceptDt<RestfulSecurityServiceEnum> addService() {
3698                BoundCodeableConceptDt<RestfulSecurityServiceEnum> retVal = new BoundCodeableConceptDt<RestfulSecurityServiceEnum>(RestfulSecurityServiceEnum.VALUESET_BINDER);
3699                getService().add(retVal);
3700                return retVal;
3701        }
3702
3703        /**
3704         * Sets the value(s), and clears any existing value(s) for <b>service</b> ()
3705         *
3706     * <p>
3707     * <b>Definition:</b>
3708     * Types of security services are supported/required by the system
3709     * </p> 
3710         */
3711        public RestSecurity setService(RestfulSecurityServiceEnum theValue) {
3712                getService().clear();
3713                addService(theValue);
3714                return this;
3715        }
3716
3717  
3718        /**
3719         * Gets the value(s) for <b>description</b> ().
3720         * creating it if it does
3721         * not exist. Will not return <code>null</code>.
3722         *
3723     * <p>
3724     * <b>Definition:</b>
3725     * General description of how security works
3726     * </p> 
3727         */
3728        public StringDt getDescriptionElement() {  
3729                if (myDescription == null) {
3730                        myDescription = new StringDt();
3731                }
3732                return myDescription;
3733        }
3734
3735        
3736        /**
3737         * Gets the value(s) for <b>description</b> ().
3738         * creating it if it does
3739         * not exist. Will not return <code>null</code>.
3740         *
3741     * <p>
3742     * <b>Definition:</b>
3743     * General description of how security works
3744     * </p> 
3745         */
3746        public String getDescription() {  
3747                return getDescriptionElement().getValue();
3748        }
3749
3750        /**
3751         * Sets the value(s) for <b>description</b> ()
3752         *
3753     * <p>
3754     * <b>Definition:</b>
3755     * General description of how security works
3756     * </p> 
3757         */
3758        public RestSecurity setDescription(StringDt theValue) {
3759                myDescription = theValue;
3760                return this;
3761        }
3762        
3763        
3764
3765        /**
3766         * Sets the value for <b>description</b> ()
3767         *
3768     * <p>
3769     * <b>Definition:</b>
3770     * General description of how security works
3771     * </p> 
3772         */
3773        public RestSecurity setDescription( String theString) {
3774                myDescription = new StringDt(theString); 
3775                return this; 
3776        }
3777
3778 
3779        /**
3780         * Gets the value(s) for <b>certificate</b> ().
3781         * creating it if it does
3782         * not exist. Will not return <code>null</code>.
3783         *
3784     * <p>
3785     * <b>Definition:</b>
3786     * Certificates associated with security profiles
3787     * </p> 
3788         */
3789        public java.util.List<RestSecurityCertificate> getCertificate() {  
3790                if (myCertificate == null) {
3791                        myCertificate = new java.util.ArrayList<RestSecurityCertificate>();
3792                }
3793                return myCertificate;
3794        }
3795
3796        /**
3797         * Sets the value(s) for <b>certificate</b> ()
3798         *
3799     * <p>
3800     * <b>Definition:</b>
3801     * Certificates associated with security profiles
3802     * </p> 
3803         */
3804        public RestSecurity setCertificate(java.util.List<RestSecurityCertificate> theValue) {
3805                myCertificate = theValue;
3806                return this;
3807        }
3808        
3809        
3810
3811        /**
3812         * Adds and returns a new value for <b>certificate</b> ()
3813         *
3814     * <p>
3815     * <b>Definition:</b>
3816     * Certificates associated with security profiles
3817     * </p> 
3818         */
3819        public RestSecurityCertificate addCertificate() {
3820                RestSecurityCertificate newType = new RestSecurityCertificate();
3821                getCertificate().add(newType);
3822                return newType; 
3823        }
3824
3825        /**
3826         * Adds a given new value for <b>certificate</b> ()
3827         *
3828         * <p>
3829         * <b>Definition:</b>
3830         * Certificates associated with security profiles
3831         * </p>
3832         * @param theValue The certificate to add (must not be <code>null</code>)
3833         */
3834        public RestSecurity addCertificate(RestSecurityCertificate theValue) {
3835                if (theValue == null) {
3836                        throw new NullPointerException("theValue must not be null");
3837                }
3838                getCertificate().add(theValue);
3839                return this;
3840        }
3841
3842        /**
3843         * Gets the first repetition for <b>certificate</b> (),
3844         * creating it if it does not already exist.
3845         *
3846     * <p>
3847     * <b>Definition:</b>
3848     * Certificates associated with security profiles
3849     * </p> 
3850         */
3851        public RestSecurityCertificate getCertificateFirstRep() {
3852                if (getCertificate().isEmpty()) {
3853                        return addCertificate();
3854                }
3855                return getCertificate().get(0); 
3856        }
3857  
3858
3859
3860        }
3861
3862        /**
3863         * Block class for child element: <b>Conformance.rest.security.certificate</b> ()
3864         *
3865     * <p>
3866     * <b>Definition:</b>
3867     * Certificates associated with security profiles
3868     * </p> 
3869         */
3870        @Block()        
3871        public static class RestSecurityCertificate 
3872            extends  BaseIdentifiableElement        implements IResourceBlock {
3873        
3874        @Child(name="type", type=CodeDt.class, order=0, min=0, max=1, summary=false, modifier=false)    
3875        @Description(
3876                shortDefinition="",
3877                formalDefinition="Mime type for certificate"
3878        )
3879        private CodeDt myType;
3880        
3881        @Child(name="blob", type=Base64BinaryDt.class, order=1, min=0, max=1, summary=false, modifier=false)    
3882        @Description(
3883                shortDefinition="",
3884                formalDefinition="Actual certificate"
3885        )
3886        private Base64BinaryDt myBlob;
3887        
3888
3889        @Override
3890        public boolean isEmpty() {
3891                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myType,  myBlob);
3892        }
3893        
3894        @Override
3895        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
3896                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myType, myBlob);
3897        }
3898
3899        /**
3900         * Gets the value(s) for <b>type</b> ().
3901         * creating it if it does
3902         * not exist. Will not return <code>null</code>.
3903         *
3904     * <p>
3905     * <b>Definition:</b>
3906     * Mime type for certificate
3907     * </p> 
3908         */
3909        public CodeDt getTypeElement() {  
3910                if (myType == null) {
3911                        myType = new CodeDt();
3912                }
3913                return myType;
3914        }
3915
3916        
3917        /**
3918         * Gets the value(s) for <b>type</b> ().
3919         * creating it if it does
3920         * not exist. Will not return <code>null</code>.
3921         *
3922     * <p>
3923     * <b>Definition:</b>
3924     * Mime type for certificate
3925     * </p> 
3926         */
3927        public String getType() {  
3928                return getTypeElement().getValue();
3929        }
3930
3931        /**
3932         * Sets the value(s) for <b>type</b> ()
3933         *
3934     * <p>
3935     * <b>Definition:</b>
3936     * Mime type for certificate
3937     * </p> 
3938         */
3939        public RestSecurityCertificate setType(CodeDt theValue) {
3940                myType = theValue;
3941                return this;
3942        }
3943        
3944        
3945
3946        /**
3947         * Sets the value for <b>type</b> ()
3948         *
3949     * <p>
3950     * <b>Definition:</b>
3951     * Mime type for certificate
3952     * </p> 
3953         */
3954        public RestSecurityCertificate setType( String theCode) {
3955                myType = new CodeDt(theCode); 
3956                return this; 
3957        }
3958
3959 
3960        /**
3961         * Gets the value(s) for <b>blob</b> ().
3962         * creating it if it does
3963         * not exist. Will not return <code>null</code>.
3964         *
3965     * <p>
3966     * <b>Definition:</b>
3967     * Actual certificate
3968     * </p> 
3969         */
3970        public Base64BinaryDt getBlobElement() {  
3971                if (myBlob == null) {
3972                        myBlob = new Base64BinaryDt();
3973                }
3974                return myBlob;
3975        }
3976
3977        
3978        /**
3979         * Gets the value(s) for <b>blob</b> ().
3980         * creating it if it does
3981         * not exist. Will not return <code>null</code>.
3982         *
3983     * <p>
3984     * <b>Definition:</b>
3985     * Actual certificate
3986     * </p> 
3987         */
3988        public byte[] getBlob() {  
3989                return getBlobElement().getValue();
3990        }
3991
3992        /**
3993         * Sets the value(s) for <b>blob</b> ()
3994         *
3995     * <p>
3996     * <b>Definition:</b>
3997     * Actual certificate
3998     * </p> 
3999         */
4000        public RestSecurityCertificate setBlob(Base64BinaryDt theValue) {
4001                myBlob = theValue;
4002                return this;
4003        }
4004        
4005        
4006
4007        /**
4008         * Sets the value for <b>blob</b> ()
4009         *
4010     * <p>
4011     * <b>Definition:</b>
4012     * Actual certificate
4013     * </p> 
4014         */
4015        public RestSecurityCertificate setBlob( byte[] theBytes) {
4016                myBlob = new Base64BinaryDt(theBytes); 
4017                return this; 
4018        }
4019
4020 
4021
4022
4023        }
4024
4025
4026
4027        /**
4028         * Block class for child element: <b>Conformance.rest.resource</b> ()
4029         *
4030     * <p>
4031     * <b>Definition:</b>
4032     * A specification of the restful capabilities of the solution for a specific resource type
4033     * </p> 
4034         */
4035        @Block()        
4036        public static class RestResource 
4037            extends  BaseIdentifiableElement        implements IResourceBlock {
4038        
4039        @Child(name="type", type=CodeDt.class, order=0, min=1, max=1, summary=true, modifier=false)     
4040        @Description(
4041                shortDefinition="",
4042                formalDefinition="A type of resource exposed via the restful interface"
4043        )
4044        private BoundCodeDt<ResourceTypeEnum> myType;
4045        
4046        @Child(name="profile", order=1, min=0, max=1, summary=false, modifier=false, type={
4047                ca.uhn.fhir.model.dstu2.resource.StructureDefinition.class      })
4048        @Description(
4049                shortDefinition="",
4050                formalDefinition="A specification of the profile that describes the solution's overall support for the resource, including any constraints on cardinality, bindings, lengths or other limitations. See further discussion in [Using Profiles]{profiling.html#profile-uses}"
4051        )
4052        private ResourceReferenceDt myProfile;
4053        
4054        @Child(name="interaction", order=2, min=1, max=Child.MAX_UNLIMITED, summary=false, modifier=false)      
4055        @Description(
4056                shortDefinition="",
4057                formalDefinition="Identifies a restful operation supported by the solution"
4058        )
4059        private java.util.List<RestResourceInteraction> myInteraction;
4060        
4061        @Child(name="versioning", type=CodeDt.class, order=3, min=0, max=1, summary=false, modifier=false)      
4062        @Description(
4063                shortDefinition="",
4064                formalDefinition="This field is set to no-version to specify that the system does not support (server) or use (client) versioning for this resource type. If this has some other value, the server must at least correctly track and populate the versionId meta-property on resources. If the value is 'versioned-update', then the server supports all the versioning features, including using e-tags for version integrity in the API"
4065        )
4066        private BoundCodeDt<ResourceVersionPolicyEnum> myVersioning;
4067        
4068        @Child(name="readHistory", type=BooleanDt.class, order=4, min=0, max=1, summary=false, modifier=false)  
4069        @Description(
4070                shortDefinition="",
4071                formalDefinition="A flag for whether the server is able to return past versions as part of the vRead operation"
4072        )
4073        private BooleanDt myReadHistory;
4074        
4075        @Child(name="updateCreate", type=BooleanDt.class, order=5, min=0, max=1, summary=false, modifier=false) 
4076        @Description(
4077                shortDefinition="",
4078                formalDefinition="A flag to indicate that the server allows or needs to allow the client to create new identities on the server (e.g. that is, the client PUTs to a location where there is no existing resource). Allowing this operation means that the server allows the client to create new identities on the server"
4079        )
4080        private BooleanDt myUpdateCreate;
4081        
4082        @Child(name="conditionalCreate", type=BooleanDt.class, order=6, min=0, max=1, summary=false, modifier=false)    
4083        @Description(
4084                shortDefinition="",
4085                formalDefinition="A flag that indicates that the server supports conditional create"
4086        )
4087        private BooleanDt myConditionalCreate;
4088        
4089        @Child(name="conditionalUpdate", type=BooleanDt.class, order=7, min=0, max=1, summary=false, modifier=false)    
4090        @Description(
4091                shortDefinition="",
4092                formalDefinition="A flag that indicates that the server supports conditional update"
4093        )
4094        private BooleanDt myConditionalUpdate;
4095        
4096        @Child(name="conditionalDelete", type=CodeDt.class, order=8, min=0, max=1, summary=false, modifier=false)       
4097        @Description(
4098                shortDefinition="",
4099                formalDefinition="A code that indicates how the server supports conditional delete"
4100        )
4101        private BoundCodeDt<ConditionalDeleteStatusEnum> myConditionalDelete;
4102        
4103        @Child(name="searchInclude", type=StringDt.class, order=9, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)       
4104        @Description(
4105                shortDefinition="",
4106                formalDefinition="A list of _include values supported by the server"
4107        )
4108        private java.util.List<StringDt> mySearchInclude;
4109        
4110        @Child(name="searchRevInclude", type=StringDt.class, order=10, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)   
4111        @Description(
4112                shortDefinition="",
4113                formalDefinition="A list of _revinclude (reverse include) values supported by the server"
4114        )
4115        private java.util.List<StringDt> mySearchRevInclude;
4116        
4117        @Child(name="searchParam", order=11, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)     
4118        @Description(
4119                shortDefinition="",
4120                formalDefinition="Search parameters for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation"
4121        )
4122        private java.util.List<RestResourceSearchParam> mySearchParam;
4123        
4124
4125        @Override
4126        public boolean isEmpty() {
4127                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myType,  myProfile,  myInteraction,  myVersioning,  myReadHistory,  myUpdateCreate,  myConditionalCreate,  myConditionalUpdate,  myConditionalDelete,  mySearchInclude,  mySearchRevInclude,  mySearchParam);
4128        }
4129        
4130        @Override
4131        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
4132                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myType, myProfile, myInteraction, myVersioning, myReadHistory, myUpdateCreate, myConditionalCreate, myConditionalUpdate, myConditionalDelete, mySearchInclude, mySearchRevInclude, mySearchParam);
4133        }
4134
4135        /**
4136         * Gets the value(s) for <b>type</b> ().
4137         * creating it if it does
4138         * not exist. Will not return <code>null</code>.
4139         *
4140     * <p>
4141     * <b>Definition:</b>
4142     * A type of resource exposed via the restful interface
4143     * </p> 
4144         */
4145        public BoundCodeDt<ResourceTypeEnum> getTypeElement() {  
4146                if (myType == null) {
4147                        myType = new BoundCodeDt<ResourceTypeEnum>(ResourceTypeEnum.VALUESET_BINDER);
4148                }
4149                return myType;
4150        }
4151
4152        
4153        /**
4154         * Gets the value(s) for <b>type</b> ().
4155         * creating it if it does
4156         * not exist. Will not return <code>null</code>.
4157         *
4158     * <p>
4159     * <b>Definition:</b>
4160     * A type of resource exposed via the restful interface
4161     * </p> 
4162         */
4163        public String getType() {  
4164                return getTypeElement().getValue();
4165        }
4166
4167        /**
4168         * Sets the value(s) for <b>type</b> ()
4169         *
4170     * <p>
4171     * <b>Definition:</b>
4172     * A type of resource exposed via the restful interface
4173     * </p> 
4174         */
4175        public RestResource setType(BoundCodeDt<ResourceTypeEnum> theValue) {
4176                myType = theValue;
4177                return this;
4178        }
4179        
4180        
4181
4182        /**
4183         * Sets the value(s) for <b>type</b> ()
4184         *
4185     * <p>
4186     * <b>Definition:</b>
4187     * A type of resource exposed via the restful interface
4188     * </p> 
4189         */
4190        public RestResource setType(ResourceTypeEnum theValue) {
4191                setType(new BoundCodeDt<ResourceTypeEnum>(ResourceTypeEnum.VALUESET_BINDER, theValue));
4192                
4193/*
4194                getTypeElement().setValueAsEnum(theValue);
4195*/
4196                return this;
4197        }
4198
4199  
4200        /**
4201         * Gets the value(s) for <b>profile</b> ().
4202         * creating it if it does
4203         * not exist. Will not return <code>null</code>.
4204         *
4205     * <p>
4206     * <b>Definition:</b>
4207     * A specification of the profile that describes the solution's overall support for the resource, including any constraints on cardinality, bindings, lengths or other limitations. See further discussion in [Using Profiles]{profiling.html#profile-uses}
4208     * </p> 
4209         */
4210        public ResourceReferenceDt getProfile() {  
4211                if (myProfile == null) {
4212                        myProfile = new ResourceReferenceDt();
4213                }
4214                return myProfile;
4215        }
4216
4217        /**
4218         * Sets the value(s) for <b>profile</b> ()
4219         *
4220     * <p>
4221     * <b>Definition:</b>
4222     * A specification of the profile that describes the solution's overall support for the resource, including any constraints on cardinality, bindings, lengths or other limitations. See further discussion in [Using Profiles]{profiling.html#profile-uses}
4223     * </p> 
4224         */
4225        public RestResource setProfile(ResourceReferenceDt theValue) {
4226                myProfile = theValue;
4227                return this;
4228        }
4229        
4230        
4231
4232  
4233        /**
4234         * Gets the value(s) for <b>interaction</b> ().
4235         * creating it if it does
4236         * not exist. Will not return <code>null</code>.
4237         *
4238     * <p>
4239     * <b>Definition:</b>
4240     * Identifies a restful operation supported by the solution
4241     * </p> 
4242         */
4243        public java.util.List<RestResourceInteraction> getInteraction() {  
4244                if (myInteraction == null) {
4245                        myInteraction = new java.util.ArrayList<RestResourceInteraction>();
4246                }
4247                return myInteraction;
4248        }
4249
4250        /**
4251         * Sets the value(s) for <b>interaction</b> ()
4252         *
4253     * <p>
4254     * <b>Definition:</b>
4255     * Identifies a restful operation supported by the solution
4256     * </p> 
4257         */
4258        public RestResource setInteraction(java.util.List<RestResourceInteraction> theValue) {
4259                myInteraction = theValue;
4260                return this;
4261        }
4262        
4263        
4264
4265        /**
4266         * Adds and returns a new value for <b>interaction</b> ()
4267         *
4268     * <p>
4269     * <b>Definition:</b>
4270     * Identifies a restful operation supported by the solution
4271     * </p> 
4272         */
4273        public RestResourceInteraction addInteraction() {
4274                RestResourceInteraction newType = new RestResourceInteraction();
4275                getInteraction().add(newType);
4276                return newType; 
4277        }
4278
4279        /**
4280         * Adds a given new value for <b>interaction</b> ()
4281         *
4282         * <p>
4283         * <b>Definition:</b>
4284         * Identifies a restful operation supported by the solution
4285         * </p>
4286         * @param theValue The interaction to add (must not be <code>null</code>)
4287         */
4288        public RestResource addInteraction(RestResourceInteraction theValue) {
4289                if (theValue == null) {
4290                        throw new NullPointerException("theValue must not be null");
4291                }
4292                getInteraction().add(theValue);
4293                return this;
4294        }
4295
4296        /**
4297         * Gets the first repetition for <b>interaction</b> (),
4298         * creating it if it does not already exist.
4299         *
4300     * <p>
4301     * <b>Definition:</b>
4302     * Identifies a restful operation supported by the solution
4303     * </p> 
4304         */
4305        public RestResourceInteraction getInteractionFirstRep() {
4306                if (getInteraction().isEmpty()) {
4307                        return addInteraction();
4308                }
4309                return getInteraction().get(0); 
4310        }
4311  
4312        /**
4313         * Gets the value(s) for <b>versioning</b> ().
4314         * creating it if it does
4315         * not exist. Will not return <code>null</code>.
4316         *
4317     * <p>
4318     * <b>Definition:</b>
4319     * This field is set to no-version to specify that the system does not support (server) or use (client) versioning for this resource type. If this has some other value, the server must at least correctly track and populate the versionId meta-property on resources. If the value is 'versioned-update', then the server supports all the versioning features, including using e-tags for version integrity in the API
4320     * </p> 
4321         */
4322        public BoundCodeDt<ResourceVersionPolicyEnum> getVersioningElement() {  
4323                if (myVersioning == null) {
4324                        myVersioning = new BoundCodeDt<ResourceVersionPolicyEnum>(ResourceVersionPolicyEnum.VALUESET_BINDER);
4325                }
4326                return myVersioning;
4327        }
4328
4329        
4330        /**
4331         * Gets the value(s) for <b>versioning</b> ().
4332         * creating it if it does
4333         * not exist. Will not return <code>null</code>.
4334         *
4335     * <p>
4336     * <b>Definition:</b>
4337     * This field is set to no-version to specify that the system does not support (server) or use (client) versioning for this resource type. If this has some other value, the server must at least correctly track and populate the versionId meta-property on resources. If the value is 'versioned-update', then the server supports all the versioning features, including using e-tags for version integrity in the API
4338     * </p> 
4339         */
4340        public String getVersioning() {  
4341                return getVersioningElement().getValue();
4342        }
4343
4344        /**
4345         * Sets the value(s) for <b>versioning</b> ()
4346         *
4347     * <p>
4348     * <b>Definition:</b>
4349     * This field is set to no-version to specify that the system does not support (server) or use (client) versioning for this resource type. If this has some other value, the server must at least correctly track and populate the versionId meta-property on resources. If the value is 'versioned-update', then the server supports all the versioning features, including using e-tags for version integrity in the API
4350     * </p> 
4351         */
4352        public RestResource setVersioning(BoundCodeDt<ResourceVersionPolicyEnum> theValue) {
4353                myVersioning = theValue;
4354                return this;
4355        }
4356        
4357        
4358
4359        /**
4360         * Sets the value(s) for <b>versioning</b> ()
4361         *
4362     * <p>
4363     * <b>Definition:</b>
4364     * This field is set to no-version to specify that the system does not support (server) or use (client) versioning for this resource type. If this has some other value, the server must at least correctly track and populate the versionId meta-property on resources. If the value is 'versioned-update', then the server supports all the versioning features, including using e-tags for version integrity in the API
4365     * </p> 
4366         */
4367        public RestResource setVersioning(ResourceVersionPolicyEnum theValue) {
4368                setVersioning(new BoundCodeDt<ResourceVersionPolicyEnum>(ResourceVersionPolicyEnum.VALUESET_BINDER, theValue));
4369                
4370/*
4371                getVersioningElement().setValueAsEnum(theValue);
4372*/
4373                return this;
4374        }
4375
4376  
4377        /**
4378         * Gets the value(s) for <b>readHistory</b> ().
4379         * creating it if it does
4380         * not exist. Will not return <code>null</code>.
4381         *
4382     * <p>
4383     * <b>Definition:</b>
4384     * A flag for whether the server is able to return past versions as part of the vRead operation
4385     * </p> 
4386         */
4387        public BooleanDt getReadHistoryElement() {  
4388                if (myReadHistory == null) {
4389                        myReadHistory = new BooleanDt();
4390                }
4391                return myReadHistory;
4392        }
4393
4394        
4395        /**
4396         * Gets the value(s) for <b>readHistory</b> ().
4397         * creating it if it does
4398         * not exist. Will not return <code>null</code>.
4399         *
4400     * <p>
4401     * <b>Definition:</b>
4402     * A flag for whether the server is able to return past versions as part of the vRead operation
4403     * </p> 
4404         */
4405        public Boolean getReadHistory() {  
4406                return getReadHistoryElement().getValue();
4407        }
4408
4409        /**
4410         * Sets the value(s) for <b>readHistory</b> ()
4411         *
4412     * <p>
4413     * <b>Definition:</b>
4414     * A flag for whether the server is able to return past versions as part of the vRead operation
4415     * </p> 
4416         */
4417        public RestResource setReadHistory(BooleanDt theValue) {
4418                myReadHistory = theValue;
4419                return this;
4420        }
4421        
4422        
4423
4424        /**
4425         * Sets the value for <b>readHistory</b> ()
4426         *
4427     * <p>
4428     * <b>Definition:</b>
4429     * A flag for whether the server is able to return past versions as part of the vRead operation
4430     * </p> 
4431         */
4432        public RestResource setReadHistory( boolean theBoolean) {
4433                myReadHistory = new BooleanDt(theBoolean); 
4434                return this; 
4435        }
4436
4437 
4438        /**
4439         * Gets the value(s) for <b>updateCreate</b> ().
4440         * creating it if it does
4441         * not exist. Will not return <code>null</code>.
4442         *
4443     * <p>
4444     * <b>Definition:</b>
4445     * A flag to indicate that the server allows or needs to allow the client to create new identities on the server (e.g. that is, the client PUTs to a location where there is no existing resource). Allowing this operation means that the server allows the client to create new identities on the server
4446     * </p> 
4447         */
4448        public BooleanDt getUpdateCreateElement() {  
4449                if (myUpdateCreate == null) {
4450                        myUpdateCreate = new BooleanDt();
4451                }
4452                return myUpdateCreate;
4453        }
4454
4455        
4456        /**
4457         * Gets the value(s) for <b>updateCreate</b> ().
4458         * creating it if it does
4459         * not exist. Will not return <code>null</code>.
4460         *
4461     * <p>
4462     * <b>Definition:</b>
4463     * A flag to indicate that the server allows or needs to allow the client to create new identities on the server (e.g. that is, the client PUTs to a location where there is no existing resource). Allowing this operation means that the server allows the client to create new identities on the server
4464     * </p> 
4465         */
4466        public Boolean getUpdateCreate() {  
4467                return getUpdateCreateElement().getValue();
4468        }
4469
4470        /**
4471         * Sets the value(s) for <b>updateCreate</b> ()
4472         *
4473     * <p>
4474     * <b>Definition:</b>
4475     * A flag to indicate that the server allows or needs to allow the client to create new identities on the server (e.g. that is, the client PUTs to a location where there is no existing resource). Allowing this operation means that the server allows the client to create new identities on the server
4476     * </p> 
4477         */
4478        public RestResource setUpdateCreate(BooleanDt theValue) {
4479                myUpdateCreate = theValue;
4480                return this;
4481        }
4482        
4483        
4484
4485        /**
4486         * Sets the value for <b>updateCreate</b> ()
4487         *
4488     * <p>
4489     * <b>Definition:</b>
4490     * A flag to indicate that the server allows or needs to allow the client to create new identities on the server (e.g. that is, the client PUTs to a location where there is no existing resource). Allowing this operation means that the server allows the client to create new identities on the server
4491     * </p> 
4492         */
4493        public RestResource setUpdateCreate( boolean theBoolean) {
4494                myUpdateCreate = new BooleanDt(theBoolean); 
4495                return this; 
4496        }
4497
4498 
4499        /**
4500         * Gets the value(s) for <b>conditionalCreate</b> ().
4501         * creating it if it does
4502         * not exist. Will not return <code>null</code>.
4503         *
4504     * <p>
4505     * <b>Definition:</b>
4506     * A flag that indicates that the server supports conditional create
4507     * </p> 
4508         */
4509        public BooleanDt getConditionalCreateElement() {  
4510                if (myConditionalCreate == null) {
4511                        myConditionalCreate = new BooleanDt();
4512                }
4513                return myConditionalCreate;
4514        }
4515
4516        
4517        /**
4518         * Gets the value(s) for <b>conditionalCreate</b> ().
4519         * creating it if it does
4520         * not exist. Will not return <code>null</code>.
4521         *
4522     * <p>
4523     * <b>Definition:</b>
4524     * A flag that indicates that the server supports conditional create
4525     * </p> 
4526         */
4527        public Boolean getConditionalCreate() {  
4528                return getConditionalCreateElement().getValue();
4529        }
4530
4531        /**
4532         * Sets the value(s) for <b>conditionalCreate</b> ()
4533         *
4534     * <p>
4535     * <b>Definition:</b>
4536     * A flag that indicates that the server supports conditional create
4537     * </p> 
4538         */
4539        public RestResource setConditionalCreate(BooleanDt theValue) {
4540                myConditionalCreate = theValue;
4541                return this;
4542        }
4543        
4544        
4545
4546        /**
4547         * Sets the value for <b>conditionalCreate</b> ()
4548         *
4549     * <p>
4550     * <b>Definition:</b>
4551     * A flag that indicates that the server supports conditional create
4552     * </p> 
4553         */
4554        public RestResource setConditionalCreate( boolean theBoolean) {
4555                myConditionalCreate = new BooleanDt(theBoolean); 
4556                return this; 
4557        }
4558
4559 
4560        /**
4561         * Gets the value(s) for <b>conditionalUpdate</b> ().
4562         * creating it if it does
4563         * not exist. Will not return <code>null</code>.
4564         *
4565     * <p>
4566     * <b>Definition:</b>
4567     * A flag that indicates that the server supports conditional update
4568     * </p> 
4569         */
4570        public BooleanDt getConditionalUpdateElement() {  
4571                if (myConditionalUpdate == null) {
4572                        myConditionalUpdate = new BooleanDt();
4573                }
4574                return myConditionalUpdate;
4575        }
4576
4577        
4578        /**
4579         * Gets the value(s) for <b>conditionalUpdate</b> ().
4580         * creating it if it does
4581         * not exist. Will not return <code>null</code>.
4582         *
4583     * <p>
4584     * <b>Definition:</b>
4585     * A flag that indicates that the server supports conditional update
4586     * </p> 
4587         */
4588        public Boolean getConditionalUpdate() {  
4589                return getConditionalUpdateElement().getValue();
4590        }
4591
4592        /**
4593         * Sets the value(s) for <b>conditionalUpdate</b> ()
4594         *
4595     * <p>
4596     * <b>Definition:</b>
4597     * A flag that indicates that the server supports conditional update
4598     * </p> 
4599         */
4600        public RestResource setConditionalUpdate(BooleanDt theValue) {
4601                myConditionalUpdate = theValue;
4602                return this;
4603        }
4604        
4605        
4606
4607        /**
4608         * Sets the value for <b>conditionalUpdate</b> ()
4609         *
4610     * <p>
4611     * <b>Definition:</b>
4612     * A flag that indicates that the server supports conditional update
4613     * </p> 
4614         */
4615        public RestResource setConditionalUpdate( boolean theBoolean) {
4616                myConditionalUpdate = new BooleanDt(theBoolean); 
4617                return this; 
4618        }
4619
4620 
4621        /**
4622         * Gets the value(s) for <b>conditionalDelete</b> ().
4623         * creating it if it does
4624         * not exist. Will not return <code>null</code>.
4625         *
4626     * <p>
4627     * <b>Definition:</b>
4628     * A code that indicates how the server supports conditional delete
4629     * </p> 
4630         */
4631        public BoundCodeDt<ConditionalDeleteStatusEnum> getConditionalDeleteElement() {  
4632                if (myConditionalDelete == null) {
4633                        myConditionalDelete = new BoundCodeDt<ConditionalDeleteStatusEnum>(ConditionalDeleteStatusEnum.VALUESET_BINDER);
4634                }
4635                return myConditionalDelete;
4636        }
4637
4638        
4639        /**
4640         * Gets the value(s) for <b>conditionalDelete</b> ().
4641         * creating it if it does
4642         * not exist. Will not return <code>null</code>.
4643         *
4644     * <p>
4645     * <b>Definition:</b>
4646     * A code that indicates how the server supports conditional delete
4647     * </p> 
4648         */
4649        public String getConditionalDelete() {  
4650                return getConditionalDeleteElement().getValue();
4651        }
4652
4653        /**
4654         * Sets the value(s) for <b>conditionalDelete</b> ()
4655         *
4656     * <p>
4657     * <b>Definition:</b>
4658     * A code that indicates how the server supports conditional delete
4659     * </p> 
4660         */
4661        public RestResource setConditionalDelete(BoundCodeDt<ConditionalDeleteStatusEnum> theValue) {
4662                myConditionalDelete = theValue;
4663                return this;
4664        }
4665        
4666        
4667
4668        /**
4669         * Sets the value(s) for <b>conditionalDelete</b> ()
4670         *
4671     * <p>
4672     * <b>Definition:</b>
4673     * A code that indicates how the server supports conditional delete
4674     * </p> 
4675         */
4676        public RestResource setConditionalDelete(ConditionalDeleteStatusEnum theValue) {
4677                setConditionalDelete(new BoundCodeDt<ConditionalDeleteStatusEnum>(ConditionalDeleteStatusEnum.VALUESET_BINDER, theValue));
4678                
4679/*
4680                getConditionalDeleteElement().setValueAsEnum(theValue);
4681*/
4682                return this;
4683        }
4684
4685  
4686        /**
4687         * Gets the value(s) for <b>searchInclude</b> ().
4688         * creating it if it does
4689         * not exist. Will not return <code>null</code>.
4690         *
4691     * <p>
4692     * <b>Definition:</b>
4693     * A list of _include values supported by the server
4694     * </p> 
4695         */
4696        public java.util.List<StringDt> getSearchInclude() {  
4697                if (mySearchInclude == null) {
4698                        mySearchInclude = new java.util.ArrayList<StringDt>();
4699                }
4700                return mySearchInclude;
4701        }
4702
4703        /**
4704         * Sets the value(s) for <b>searchInclude</b> ()
4705         *
4706     * <p>
4707     * <b>Definition:</b>
4708     * A list of _include values supported by the server
4709     * </p> 
4710         */
4711        public RestResource setSearchInclude(java.util.List<StringDt> theValue) {
4712                mySearchInclude = theValue;
4713                return this;
4714        }
4715        
4716        
4717
4718        /**
4719         * Adds and returns a new value for <b>searchInclude</b> ()
4720         *
4721     * <p>
4722     * <b>Definition:</b>
4723     * A list of _include values supported by the server
4724     * </p> 
4725         */
4726        public StringDt addSearchInclude() {
4727                StringDt newType = new StringDt();
4728                getSearchInclude().add(newType);
4729                return newType; 
4730        }
4731
4732        /**
4733         * Adds a given new value for <b>searchInclude</b> ()
4734         *
4735         * <p>
4736         * <b>Definition:</b>
4737         * A list of _include values supported by the server
4738         * </p>
4739         * @param theValue The searchInclude to add (must not be <code>null</code>)
4740         */
4741        public RestResource addSearchInclude(StringDt theValue) {
4742                if (theValue == null) {
4743                        throw new NullPointerException("theValue must not be null");
4744                }
4745                getSearchInclude().add(theValue);
4746                return this;
4747        }
4748
4749        /**
4750         * Gets the first repetition for <b>searchInclude</b> (),
4751         * creating it if it does not already exist.
4752         *
4753     * <p>
4754     * <b>Definition:</b>
4755     * A list of _include values supported by the server
4756     * </p> 
4757         */
4758        public StringDt getSearchIncludeFirstRep() {
4759                if (getSearchInclude().isEmpty()) {
4760                        return addSearchInclude();
4761                }
4762                return getSearchInclude().get(0); 
4763        }
4764        /**
4765         * Adds a new value for <b>searchInclude</b> ()
4766         *
4767     * <p>
4768     * <b>Definition:</b>
4769     * A list of _include values supported by the server
4770     * </p> 
4771     *
4772     * @return Returns a reference to this object, to allow for simple chaining.
4773         */
4774        public RestResource addSearchInclude( String theString) {
4775                if (mySearchInclude == null) {
4776                        mySearchInclude = new java.util.ArrayList<StringDt>();
4777                }
4778                mySearchInclude.add(new StringDt(theString));
4779                return this; 
4780        }
4781
4782 
4783        /**
4784         * Gets the value(s) for <b>searchRevInclude</b> ().
4785         * creating it if it does
4786         * not exist. Will not return <code>null</code>.
4787         *
4788     * <p>
4789     * <b>Definition:</b>
4790     * A list of _revinclude (reverse include) values supported by the server
4791     * </p> 
4792         */
4793        public java.util.List<StringDt> getSearchRevInclude() {  
4794                if (mySearchRevInclude == null) {
4795                        mySearchRevInclude = new java.util.ArrayList<StringDt>();
4796                }
4797                return mySearchRevInclude;
4798        }
4799
4800        /**
4801         * Sets the value(s) for <b>searchRevInclude</b> ()
4802         *
4803     * <p>
4804     * <b>Definition:</b>
4805     * A list of _revinclude (reverse include) values supported by the server
4806     * </p> 
4807         */
4808        public RestResource setSearchRevInclude(java.util.List<StringDt> theValue) {
4809                mySearchRevInclude = theValue;
4810                return this;
4811        }
4812        
4813        
4814
4815        /**
4816         * Adds and returns a new value for <b>searchRevInclude</b> ()
4817         *
4818     * <p>
4819     * <b>Definition:</b>
4820     * A list of _revinclude (reverse include) values supported by the server
4821     * </p> 
4822         */
4823        public StringDt addSearchRevInclude() {
4824                StringDt newType = new StringDt();
4825                getSearchRevInclude().add(newType);
4826                return newType; 
4827        }
4828
4829        /**
4830         * Adds a given new value for <b>searchRevInclude</b> ()
4831         *
4832         * <p>
4833         * <b>Definition:</b>
4834         * A list of _revinclude (reverse include) values supported by the server
4835         * </p>
4836         * @param theValue The searchRevInclude to add (must not be <code>null</code>)
4837         */
4838        public RestResource addSearchRevInclude(StringDt theValue) {
4839                if (theValue == null) {
4840                        throw new NullPointerException("theValue must not be null");
4841                }
4842                getSearchRevInclude().add(theValue);
4843                return this;
4844        }
4845
4846        /**
4847         * Gets the first repetition for <b>searchRevInclude</b> (),
4848         * creating it if it does not already exist.
4849         *
4850     * <p>
4851     * <b>Definition:</b>
4852     * A list of _revinclude (reverse include) values supported by the server
4853     * </p> 
4854         */
4855        public StringDt getSearchRevIncludeFirstRep() {
4856                if (getSearchRevInclude().isEmpty()) {
4857                        return addSearchRevInclude();
4858                }
4859                return getSearchRevInclude().get(0); 
4860        }
4861        /**
4862         * Adds a new value for <b>searchRevInclude</b> ()
4863         *
4864     * <p>
4865     * <b>Definition:</b>
4866     * A list of _revinclude (reverse include) values supported by the server
4867     * </p> 
4868     *
4869     * @return Returns a reference to this object, to allow for simple chaining.
4870         */
4871        public RestResource addSearchRevInclude( String theString) {
4872                if (mySearchRevInclude == null) {
4873                        mySearchRevInclude = new java.util.ArrayList<StringDt>();
4874                }
4875                mySearchRevInclude.add(new StringDt(theString));
4876                return this; 
4877        }
4878
4879 
4880        /**
4881         * Gets the value(s) for <b>searchParam</b> ().
4882         * creating it if it does
4883         * not exist. Will not return <code>null</code>.
4884         *
4885     * <p>
4886     * <b>Definition:</b>
4887     * Search parameters for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation
4888     * </p> 
4889         */
4890        public java.util.List<RestResourceSearchParam> getSearchParam() {  
4891                if (mySearchParam == null) {
4892                        mySearchParam = new java.util.ArrayList<RestResourceSearchParam>();
4893                }
4894                return mySearchParam;
4895        }
4896
4897        /**
4898         * Sets the value(s) for <b>searchParam</b> ()
4899         *
4900     * <p>
4901     * <b>Definition:</b>
4902     * Search parameters for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation
4903     * </p> 
4904         */
4905        public RestResource setSearchParam(java.util.List<RestResourceSearchParam> theValue) {
4906                mySearchParam = theValue;
4907                return this;
4908        }
4909        
4910        
4911
4912        /**
4913         * Adds and returns a new value for <b>searchParam</b> ()
4914         *
4915     * <p>
4916     * <b>Definition:</b>
4917     * Search parameters for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation
4918     * </p> 
4919         */
4920        public RestResourceSearchParam addSearchParam() {
4921                RestResourceSearchParam newType = new RestResourceSearchParam();
4922                getSearchParam().add(newType);
4923                return newType; 
4924        }
4925
4926        /**
4927         * Adds a given new value for <b>searchParam</b> ()
4928         *
4929         * <p>
4930         * <b>Definition:</b>
4931         * Search parameters for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation
4932         * </p>
4933         * @param theValue The searchParam to add (must not be <code>null</code>)
4934         */
4935        public RestResource addSearchParam(RestResourceSearchParam theValue) {
4936                if (theValue == null) {
4937                        throw new NullPointerException("theValue must not be null");
4938                }
4939                getSearchParam().add(theValue);
4940                return this;
4941        }
4942
4943        /**
4944         * Gets the first repetition for <b>searchParam</b> (),
4945         * creating it if it does not already exist.
4946         *
4947     * <p>
4948     * <b>Definition:</b>
4949     * Search parameters for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation
4950     * </p> 
4951         */
4952        public RestResourceSearchParam getSearchParamFirstRep() {
4953                if (getSearchParam().isEmpty()) {
4954                        return addSearchParam();
4955                }
4956                return getSearchParam().get(0); 
4957        }
4958  
4959
4960
4961        }
4962
4963        /**
4964         * Block class for child element: <b>Conformance.rest.resource.interaction</b> ()
4965         *
4966     * <p>
4967     * <b>Definition:</b>
4968     * Identifies a restful operation supported by the solution
4969     * </p> 
4970         */
4971        @Block()        
4972        public static class RestResourceInteraction 
4973            extends  BaseIdentifiableElement        implements IResourceBlock {
4974        
4975        @Child(name="code", type=CodeDt.class, order=0, min=1, max=1, summary=false, modifier=false)    
4976        @Description(
4977                shortDefinition="",
4978                formalDefinition="Coded identifier of the operation, supported by the system resource"
4979        )
4980        private BoundCodeDt<TypeRestfulInteractionEnum> myCode;
4981        
4982        @Child(name="documentation", type=StringDt.class, order=1, min=0, max=1, summary=false, modifier=false) 
4983        @Description(
4984                shortDefinition="",
4985                formalDefinition="Guidance specific to the implementation of this operation, such as 'delete is a logical delete' or 'updates are only allowed with version id' or 'creates permitted from pre-authorized certificates only'"
4986        )
4987        private StringDt myDocumentation;
4988        
4989
4990        @Override
4991        public boolean isEmpty() {
4992                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myCode,  myDocumentation);
4993        }
4994        
4995        @Override
4996        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
4997                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myCode, myDocumentation);
4998        }
4999
5000        /**
5001         * Gets the value(s) for <b>code</b> ().
5002         * creating it if it does
5003         * not exist. Will not return <code>null</code>.
5004         *
5005     * <p>
5006     * <b>Definition:</b>
5007     * Coded identifier of the operation, supported by the system resource
5008     * </p> 
5009         */
5010        public BoundCodeDt<TypeRestfulInteractionEnum> getCodeElement() {  
5011                if (myCode == null) {
5012                        myCode = new BoundCodeDt<TypeRestfulInteractionEnum>(TypeRestfulInteractionEnum.VALUESET_BINDER);
5013                }
5014                return myCode;
5015        }
5016
5017        
5018        /**
5019         * Gets the value(s) for <b>code</b> ().
5020         * creating it if it does
5021         * not exist. Will not return <code>null</code>.
5022         *
5023     * <p>
5024     * <b>Definition:</b>
5025     * Coded identifier of the operation, supported by the system resource
5026     * </p> 
5027         */
5028        public String getCode() {  
5029                return getCodeElement().getValue();
5030        }
5031
5032        /**
5033         * Sets the value(s) for <b>code</b> ()
5034         *
5035     * <p>
5036     * <b>Definition:</b>
5037     * Coded identifier of the operation, supported by the system resource
5038     * </p> 
5039         */
5040        public RestResourceInteraction setCode(BoundCodeDt<TypeRestfulInteractionEnum> theValue) {
5041                myCode = theValue;
5042                return this;
5043        }
5044        
5045        
5046
5047        /**
5048         * Sets the value(s) for <b>code</b> ()
5049         *
5050     * <p>
5051     * <b>Definition:</b>
5052     * Coded identifier of the operation, supported by the system resource
5053     * </p> 
5054         */
5055        public RestResourceInteraction setCode(TypeRestfulInteractionEnum theValue) {
5056                setCode(new BoundCodeDt<TypeRestfulInteractionEnum>(TypeRestfulInteractionEnum.VALUESET_BINDER, theValue));
5057                
5058/*
5059                getCodeElement().setValueAsEnum(theValue);
5060*/
5061                return this;
5062        }
5063
5064  
5065        /**
5066         * Gets the value(s) for <b>documentation</b> ().
5067         * creating it if it does
5068         * not exist. Will not return <code>null</code>.
5069         *
5070     * <p>
5071     * <b>Definition:</b>
5072     * Guidance specific to the implementation of this operation, such as 'delete is a logical delete' or 'updates are only allowed with version id' or 'creates permitted from pre-authorized certificates only'
5073     * </p> 
5074         */
5075        public StringDt getDocumentationElement() {  
5076                if (myDocumentation == null) {
5077                        myDocumentation = new StringDt();
5078                }
5079                return myDocumentation;
5080        }
5081
5082        
5083        /**
5084         * Gets the value(s) for <b>documentation</b> ().
5085         * creating it if it does
5086         * not exist. Will not return <code>null</code>.
5087         *
5088     * <p>
5089     * <b>Definition:</b>
5090     * Guidance specific to the implementation of this operation, such as 'delete is a logical delete' or 'updates are only allowed with version id' or 'creates permitted from pre-authorized certificates only'
5091     * </p> 
5092         */
5093        public String getDocumentation() {  
5094                return getDocumentationElement().getValue();
5095        }
5096
5097        /**
5098         * Sets the value(s) for <b>documentation</b> ()
5099         *
5100     * <p>
5101     * <b>Definition:</b>
5102     * Guidance specific to the implementation of this operation, such as 'delete is a logical delete' or 'updates are only allowed with version id' or 'creates permitted from pre-authorized certificates only'
5103     * </p> 
5104         */
5105        public RestResourceInteraction setDocumentation(StringDt theValue) {
5106                myDocumentation = theValue;
5107                return this;
5108        }
5109        
5110        
5111
5112        /**
5113         * Sets the value for <b>documentation</b> ()
5114         *
5115     * <p>
5116     * <b>Definition:</b>
5117     * Guidance specific to the implementation of this operation, such as 'delete is a logical delete' or 'updates are only allowed with version id' or 'creates permitted from pre-authorized certificates only'
5118     * </p> 
5119         */
5120        public RestResourceInteraction setDocumentation( String theString) {
5121                myDocumentation = new StringDt(theString); 
5122                return this; 
5123        }
5124
5125 
5126
5127
5128        }
5129
5130
5131        /**
5132         * Block class for child element: <b>Conformance.rest.resource.searchParam</b> ()
5133         *
5134     * <p>
5135     * <b>Definition:</b>
5136     * Search parameters for implementations to support and/or make use of - either references to ones defined in the specification, or additional ones defined for/by the implementation
5137     * </p> 
5138         */
5139        @Block()        
5140        public static class RestResourceSearchParam 
5141            extends  BaseIdentifiableElement        implements IResourceBlock {
5142        
5143        @Child(name="name", type=StringDt.class, order=0, min=1, max=1, summary=false, modifier=false)  
5144        @Description(
5145                shortDefinition="",
5146                formalDefinition="The name of the search parameter used in the interface"
5147        )
5148        private StringDt myName;
5149        
5150        @Child(name="definition", type=UriDt.class, order=1, min=0, max=1, summary=false, modifier=false)       
5151        @Description(
5152                shortDefinition="",
5153                formalDefinition="An absolute URI that is a formal reference to where this parameter was first defined, so that a client can be confident of the meaning of the search parameter (a reference to [[[SearchParameter.url]]])"
5154        )
5155        private UriDt myDefinition;
5156        
5157        @Child(name="type", type=CodeDt.class, order=2, min=1, max=1, summary=false, modifier=false)    
5158        @Description(
5159                shortDefinition="",
5160                formalDefinition="The type of value a search parameter refers to, and how the content is interpreted"
5161        )
5162        private BoundCodeDt<SearchParamTypeEnum> myType;
5163        
5164        @Child(name="documentation", type=StringDt.class, order=3, min=0, max=1, summary=false, modifier=false) 
5165        @Description(
5166                shortDefinition="",
5167                formalDefinition="This allows documentation of any distinct behaviors about how the search parameter is used.  For example, text matching algorithms."
5168        )
5169        private StringDt myDocumentation;
5170        
5171        @Child(name="target", type=CodeDt.class, order=4, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)        
5172        @Description(
5173                shortDefinition="",
5174                formalDefinition="Types of resource (if a resource is referenced)"
5175        )
5176        private java.util.List<BoundCodeDt<ResourceTypeEnum>> myTarget;
5177        
5178        @Child(name="modifier", type=CodeDt.class, order=5, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)      
5179        @Description(
5180                shortDefinition="",
5181                formalDefinition="A modifier supported for the search parameter"
5182        )
5183        private java.util.List<BoundCodeDt<SearchModifierCodeEnum>> myModifier;
5184        
5185        @Child(name="chain", type=StringDt.class, order=6, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)       
5186        @Description(
5187                shortDefinition="",
5188                formalDefinition="Contains the names of any search parameters which may be chained to the containing search parameter. Chained parameters may be added to search parameters of type reference, and specify that resources will only be returned if they contain a reference to a resource which matches the chained parameter value. Values for this field should be drawn from Conformance.rest.resource.searchParam.name on the target resource type"
5189        )
5190        private java.util.List<StringDt> myChain;
5191        
5192
5193        @Override
5194        public boolean isEmpty() {
5195                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myName,  myDefinition,  myType,  myDocumentation,  myTarget,  myModifier,  myChain);
5196        }
5197        
5198        @Override
5199        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
5200                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myName, myDefinition, myType, myDocumentation, myTarget, myModifier, myChain);
5201        }
5202
5203        /**
5204         * Gets the value(s) for <b>name</b> ().
5205         * creating it if it does
5206         * not exist. Will not return <code>null</code>.
5207         *
5208     * <p>
5209     * <b>Definition:</b>
5210     * The name of the search parameter used in the interface
5211     * </p> 
5212         */
5213        public StringDt getNameElement() {  
5214                if (myName == null) {
5215                        myName = new StringDt();
5216                }
5217                return myName;
5218        }
5219
5220        
5221        /**
5222         * Gets the value(s) for <b>name</b> ().
5223         * creating it if it does
5224         * not exist. Will not return <code>null</code>.
5225         *
5226     * <p>
5227     * <b>Definition:</b>
5228     * The name of the search parameter used in the interface
5229     * </p> 
5230         */
5231        public String getName() {  
5232                return getNameElement().getValue();
5233        }
5234
5235        /**
5236         * Sets the value(s) for <b>name</b> ()
5237         *
5238     * <p>
5239     * <b>Definition:</b>
5240     * The name of the search parameter used in the interface
5241     * </p> 
5242         */
5243        public RestResourceSearchParam setName(StringDt theValue) {
5244                myName = theValue;
5245                return this;
5246        }
5247        
5248        
5249
5250        /**
5251         * Sets the value for <b>name</b> ()
5252         *
5253     * <p>
5254     * <b>Definition:</b>
5255     * The name of the search parameter used in the interface
5256     * </p> 
5257         */
5258        public RestResourceSearchParam setName( String theString) {
5259                myName = new StringDt(theString); 
5260                return this; 
5261        }
5262
5263 
5264        /**
5265         * Gets the value(s) for <b>definition</b> ().
5266         * creating it if it does
5267         * not exist. Will not return <code>null</code>.
5268         *
5269     * <p>
5270     * <b>Definition:</b>
5271     * An absolute URI that is a formal reference to where this parameter was first defined, so that a client can be confident of the meaning of the search parameter (a reference to [[[SearchParameter.url]]])
5272     * </p> 
5273         */
5274        public UriDt getDefinitionElement() {  
5275                if (myDefinition == null) {
5276                        myDefinition = new UriDt();
5277                }
5278                return myDefinition;
5279        }
5280
5281        
5282        /**
5283         * Gets the value(s) for <b>definition</b> ().
5284         * creating it if it does
5285         * not exist. Will not return <code>null</code>.
5286         *
5287     * <p>
5288     * <b>Definition:</b>
5289     * An absolute URI that is a formal reference to where this parameter was first defined, so that a client can be confident of the meaning of the search parameter (a reference to [[[SearchParameter.url]]])
5290     * </p> 
5291         */
5292        public String getDefinition() {  
5293                return getDefinitionElement().getValue();
5294        }
5295
5296        /**
5297         * Sets the value(s) for <b>definition</b> ()
5298         *
5299     * <p>
5300     * <b>Definition:</b>
5301     * An absolute URI that is a formal reference to where this parameter was first defined, so that a client can be confident of the meaning of the search parameter (a reference to [[[SearchParameter.url]]])
5302     * </p> 
5303         */
5304        public RestResourceSearchParam setDefinition(UriDt theValue) {
5305                myDefinition = theValue;
5306                return this;
5307        }
5308        
5309        
5310
5311        /**
5312         * Sets the value for <b>definition</b> ()
5313         *
5314     * <p>
5315     * <b>Definition:</b>
5316     * An absolute URI that is a formal reference to where this parameter was first defined, so that a client can be confident of the meaning of the search parameter (a reference to [[[SearchParameter.url]]])
5317     * </p> 
5318         */
5319        public RestResourceSearchParam setDefinition( String theUri) {
5320                myDefinition = new UriDt(theUri); 
5321                return this; 
5322        }
5323
5324 
5325        /**
5326         * Gets the value(s) for <b>type</b> ().
5327         * creating it if it does
5328         * not exist. Will not return <code>null</code>.
5329         *
5330     * <p>
5331     * <b>Definition:</b>
5332     * The type of value a search parameter refers to, and how the content is interpreted
5333     * </p> 
5334         */
5335        public BoundCodeDt<SearchParamTypeEnum> getTypeElement() {  
5336                if (myType == null) {
5337                        myType = new BoundCodeDt<SearchParamTypeEnum>(SearchParamTypeEnum.VALUESET_BINDER);
5338                }
5339                return myType;
5340        }
5341
5342        
5343        /**
5344         * Gets the value(s) for <b>type</b> ().
5345         * creating it if it does
5346         * not exist. Will not return <code>null</code>.
5347         *
5348     * <p>
5349     * <b>Definition:</b>
5350     * The type of value a search parameter refers to, and how the content is interpreted
5351     * </p> 
5352         */
5353        public String getType() {  
5354                return getTypeElement().getValue();
5355        }
5356
5357        /**
5358         * Sets the value(s) for <b>type</b> ()
5359         *
5360     * <p>
5361     * <b>Definition:</b>
5362     * The type of value a search parameter refers to, and how the content is interpreted
5363     * </p> 
5364         */
5365        public RestResourceSearchParam setType(BoundCodeDt<SearchParamTypeEnum> theValue) {
5366                myType = theValue;
5367                return this;
5368        }
5369        
5370        
5371
5372        /**
5373         * Sets the value(s) for <b>type</b> ()
5374         *
5375     * <p>
5376     * <b>Definition:</b>
5377     * The type of value a search parameter refers to, and how the content is interpreted
5378     * </p> 
5379         */
5380        public RestResourceSearchParam setType(SearchParamTypeEnum theValue) {
5381                setType(new BoundCodeDt<SearchParamTypeEnum>(SearchParamTypeEnum.VALUESET_BINDER, theValue));
5382                
5383/*
5384                getTypeElement().setValueAsEnum(theValue);
5385*/
5386                return this;
5387        }
5388
5389  
5390        /**
5391         * Gets the value(s) for <b>documentation</b> ().
5392         * creating it if it does
5393         * not exist. Will not return <code>null</code>.
5394         *
5395     * <p>
5396     * <b>Definition:</b>
5397     * This allows documentation of any distinct behaviors about how the search parameter is used.  For example, text matching algorithms.
5398     * </p> 
5399         */
5400        public StringDt getDocumentationElement() {  
5401                if (myDocumentation == null) {
5402                        myDocumentation = new StringDt();
5403                }
5404                return myDocumentation;
5405        }
5406
5407        
5408        /**
5409         * Gets the value(s) for <b>documentation</b> ().
5410         * creating it if it does
5411         * not exist. Will not return <code>null</code>.
5412         *
5413     * <p>
5414     * <b>Definition:</b>
5415     * This allows documentation of any distinct behaviors about how the search parameter is used.  For example, text matching algorithms.
5416     * </p> 
5417         */
5418        public String getDocumentation() {  
5419                return getDocumentationElement().getValue();
5420        }
5421
5422        /**
5423         * Sets the value(s) for <b>documentation</b> ()
5424         *
5425     * <p>
5426     * <b>Definition:</b>
5427     * This allows documentation of any distinct behaviors about how the search parameter is used.  For example, text matching algorithms.
5428     * </p> 
5429         */
5430        public RestResourceSearchParam setDocumentation(StringDt theValue) {
5431                myDocumentation = theValue;
5432                return this;
5433        }
5434        
5435        
5436
5437        /**
5438         * Sets the value for <b>documentation</b> ()
5439         *
5440     * <p>
5441     * <b>Definition:</b>
5442     * This allows documentation of any distinct behaviors about how the search parameter is used.  For example, text matching algorithms.
5443     * </p> 
5444         */
5445        public RestResourceSearchParam setDocumentation( String theString) {
5446                myDocumentation = new StringDt(theString); 
5447                return this; 
5448        }
5449
5450 
5451        /**
5452         * Gets the value(s) for <b>target</b> ().
5453         * creating it if it does
5454         * not exist. Will not return <code>null</code>.
5455         *
5456     * <p>
5457     * <b>Definition:</b>
5458     * Types of resource (if a resource is referenced)
5459     * </p> 
5460         */
5461        public java.util.List<BoundCodeDt<ResourceTypeEnum>> getTarget() {  
5462                if (myTarget == null) {
5463                        myTarget = new java.util.ArrayList<BoundCodeDt<ResourceTypeEnum>>();
5464                }
5465                return myTarget;
5466        }
5467
5468        /**
5469         * Sets the value(s) for <b>target</b> ()
5470         *
5471     * <p>
5472     * <b>Definition:</b>
5473     * Types of resource (if a resource is referenced)
5474     * </p> 
5475         */
5476        public RestResourceSearchParam setTarget(java.util.List<BoundCodeDt<ResourceTypeEnum>> theValue) {
5477                myTarget = theValue;
5478                return this;
5479        }
5480        
5481        
5482
5483        /**
5484         * Add a value for <b>target</b> () using an enumerated type. This
5485         * is intended as a convenience method for situations where the FHIR defined ValueSets are mandatory
5486         * or contain the desirable codes. If you wish to use codes other than those which are built-in, 
5487         * you may also use the {@link #addTarget()} method.
5488         *
5489     * <p>
5490     * <b>Definition:</b>
5491     * Types of resource (if a resource is referenced)
5492     * </p> 
5493         */
5494        public BoundCodeDt<ResourceTypeEnum> addTarget(ResourceTypeEnum theValue) {
5495                BoundCodeDt<ResourceTypeEnum> retVal = new BoundCodeDt<ResourceTypeEnum>(ResourceTypeEnum.VALUESET_BINDER, theValue);
5496                getTarget().add(retVal);
5497                return retVal;
5498        }
5499
5500        /**
5501         * Gets the first repetition for <b>target</b> (),
5502         * creating it if it does not already exist.
5503         *
5504     * <p>
5505     * <b>Definition:</b>
5506     * Types of resource (if a resource is referenced)
5507     * </p> 
5508         */
5509        public BoundCodeDt<ResourceTypeEnum> getTargetFirstRep() {
5510                if (getTarget().size() == 0) {
5511                        addTarget();
5512                }
5513                return getTarget().get(0);
5514        }
5515
5516        /**
5517         * Add a value for <b>target</b> ()
5518         *
5519     * <p>
5520     * <b>Definition:</b>
5521     * Types of resource (if a resource is referenced)
5522     * </p> 
5523         */
5524        public BoundCodeDt<ResourceTypeEnum> addTarget() {
5525                BoundCodeDt<ResourceTypeEnum> retVal = new BoundCodeDt<ResourceTypeEnum>(ResourceTypeEnum.VALUESET_BINDER);
5526                getTarget().add(retVal);
5527                return retVal;
5528        }
5529
5530        /**
5531         * Sets the value(s), and clears any existing value(s) for <b>target</b> ()
5532         *
5533     * <p>
5534     * <b>Definition:</b>
5535     * Types of resource (if a resource is referenced)
5536     * </p> 
5537         */
5538        public RestResourceSearchParam setTarget(ResourceTypeEnum theValue) {
5539                getTarget().clear();
5540                addTarget(theValue);
5541                return this;
5542        }
5543
5544  
5545        /**
5546         * Gets the value(s) for <b>modifier</b> ().
5547         * creating it if it does
5548         * not exist. Will not return <code>null</code>.
5549         *
5550     * <p>
5551     * <b>Definition:</b>
5552     * A modifier supported for the search parameter
5553     * </p> 
5554         */
5555        public java.util.List<BoundCodeDt<SearchModifierCodeEnum>> getModifier() {  
5556                if (myModifier == null) {
5557                        myModifier = new java.util.ArrayList<BoundCodeDt<SearchModifierCodeEnum>>();
5558                }
5559                return myModifier;
5560        }
5561
5562        /**
5563         * Sets the value(s) for <b>modifier</b> ()
5564         *
5565     * <p>
5566     * <b>Definition:</b>
5567     * A modifier supported for the search parameter
5568     * </p> 
5569         */
5570        public RestResourceSearchParam setModifier(java.util.List<BoundCodeDt<SearchModifierCodeEnum>> theValue) {
5571                myModifier = theValue;
5572                return this;
5573        }
5574        
5575        
5576
5577        /**
5578         * Add a value for <b>modifier</b> () using an enumerated type. This
5579         * is intended as a convenience method for situations where the FHIR defined ValueSets are mandatory
5580         * or contain the desirable codes. If you wish to use codes other than those which are built-in, 
5581         * you may also use the {@link #addModifier()} method.
5582         *
5583     * <p>
5584     * <b>Definition:</b>
5585     * A modifier supported for the search parameter
5586     * </p> 
5587         */
5588        public BoundCodeDt<SearchModifierCodeEnum> addModifier(SearchModifierCodeEnum theValue) {
5589                BoundCodeDt<SearchModifierCodeEnum> retVal = new BoundCodeDt<SearchModifierCodeEnum>(SearchModifierCodeEnum.VALUESET_BINDER, theValue);
5590                getModifier().add(retVal);
5591                return retVal;
5592        }
5593
5594        /**
5595         * Gets the first repetition for <b>modifier</b> (),
5596         * creating it if it does not already exist.
5597         *
5598     * <p>
5599     * <b>Definition:</b>
5600     * A modifier supported for the search parameter
5601     * </p> 
5602         */
5603        public BoundCodeDt<SearchModifierCodeEnum> getModifierFirstRep() {
5604                if (getModifier().size() == 0) {
5605                        addModifier();
5606                }
5607                return getModifier().get(0);
5608        }
5609
5610        /**
5611         * Add a value for <b>modifier</b> ()
5612         *
5613     * <p>
5614     * <b>Definition:</b>
5615     * A modifier supported for the search parameter
5616     * </p> 
5617         */
5618        public BoundCodeDt<SearchModifierCodeEnum> addModifier() {
5619                BoundCodeDt<SearchModifierCodeEnum> retVal = new BoundCodeDt<SearchModifierCodeEnum>(SearchModifierCodeEnum.VALUESET_BINDER);
5620                getModifier().add(retVal);
5621                return retVal;
5622        }
5623
5624        /**
5625         * Sets the value(s), and clears any existing value(s) for <b>modifier</b> ()
5626         *
5627     * <p>
5628     * <b>Definition:</b>
5629     * A modifier supported for the search parameter
5630     * </p> 
5631         */
5632        public RestResourceSearchParam setModifier(SearchModifierCodeEnum theValue) {
5633                getModifier().clear();
5634                addModifier(theValue);
5635                return this;
5636        }
5637
5638  
5639        /**
5640         * Gets the value(s) for <b>chain</b> ().
5641         * creating it if it does
5642         * not exist. Will not return <code>null</code>.
5643         *
5644     * <p>
5645     * <b>Definition:</b>
5646     * Contains the names of any search parameters which may be chained to the containing search parameter. Chained parameters may be added to search parameters of type reference, and specify that resources will only be returned if they contain a reference to a resource which matches the chained parameter value. Values for this field should be drawn from Conformance.rest.resource.searchParam.name on the target resource type
5647     * </p> 
5648         */
5649        public java.util.List<StringDt> getChain() {  
5650                if (myChain == null) {
5651                        myChain = new java.util.ArrayList<StringDt>();
5652                }
5653                return myChain;
5654        }
5655
5656        /**
5657         * Sets the value(s) for <b>chain</b> ()
5658         *
5659     * <p>
5660     * <b>Definition:</b>
5661     * Contains the names of any search parameters which may be chained to the containing search parameter. Chained parameters may be added to search parameters of type reference, and specify that resources will only be returned if they contain a reference to a resource which matches the chained parameter value. Values for this field should be drawn from Conformance.rest.resource.searchParam.name on the target resource type
5662     * </p> 
5663         */
5664        public RestResourceSearchParam setChain(java.util.List<StringDt> theValue) {
5665                myChain = theValue;
5666                return this;
5667        }
5668        
5669        
5670
5671        /**
5672         * Adds and returns a new value for <b>chain</b> ()
5673         *
5674     * <p>
5675     * <b>Definition:</b>
5676     * Contains the names of any search parameters which may be chained to the containing search parameter. Chained parameters may be added to search parameters of type reference, and specify that resources will only be returned if they contain a reference to a resource which matches the chained parameter value. Values for this field should be drawn from Conformance.rest.resource.searchParam.name on the target resource type
5677     * </p> 
5678         */
5679        public StringDt addChain() {
5680                StringDt newType = new StringDt();
5681                getChain().add(newType);
5682                return newType; 
5683        }
5684
5685        /**
5686         * Adds a given new value for <b>chain</b> ()
5687         *
5688         * <p>
5689         * <b>Definition:</b>
5690         * Contains the names of any search parameters which may be chained to the containing search parameter. Chained parameters may be added to search parameters of type reference, and specify that resources will only be returned if they contain a reference to a resource which matches the chained parameter value. Values for this field should be drawn from Conformance.rest.resource.searchParam.name on the target resource type
5691         * </p>
5692         * @param theValue The chain to add (must not be <code>null</code>)
5693         */
5694        public RestResourceSearchParam addChain(StringDt theValue) {
5695                if (theValue == null) {
5696                        throw new NullPointerException("theValue must not be null");
5697                }
5698                getChain().add(theValue);
5699                return this;
5700        }
5701
5702        /**
5703         * Gets the first repetition for <b>chain</b> (),
5704         * creating it if it does not already exist.
5705         *
5706     * <p>
5707     * <b>Definition:</b>
5708     * Contains the names of any search parameters which may be chained to the containing search parameter. Chained parameters may be added to search parameters of type reference, and specify that resources will only be returned if they contain a reference to a resource which matches the chained parameter value. Values for this field should be drawn from Conformance.rest.resource.searchParam.name on the target resource type
5709     * </p> 
5710         */
5711        public StringDt getChainFirstRep() {
5712                if (getChain().isEmpty()) {
5713                        return addChain();
5714                }
5715                return getChain().get(0); 
5716        }
5717        /**
5718         * Adds a new value for <b>chain</b> ()
5719         *
5720     * <p>
5721     * <b>Definition:</b>
5722     * Contains the names of any search parameters which may be chained to the containing search parameter. Chained parameters may be added to search parameters of type reference, and specify that resources will only be returned if they contain a reference to a resource which matches the chained parameter value. Values for this field should be drawn from Conformance.rest.resource.searchParam.name on the target resource type
5723     * </p> 
5724     *
5725     * @return Returns a reference to this object, to allow for simple chaining.
5726         */
5727        public RestResourceSearchParam addChain( String theString) {
5728                if (myChain == null) {
5729                        myChain = new java.util.ArrayList<StringDt>();
5730                }
5731                myChain.add(new StringDt(theString));
5732                return this; 
5733        }
5734
5735 
5736
5737
5738        }
5739
5740
5741
5742        /**
5743         * Block class for child element: <b>Conformance.rest.interaction</b> ()
5744         *
5745     * <p>
5746     * <b>Definition:</b>
5747     * A specification of restful operations supported by the system
5748     * </p> 
5749         */
5750        @Block()        
5751        public static class RestInteraction 
5752            extends  BaseIdentifiableElement        implements IResourceBlock {
5753        
5754        @Child(name="code", type=CodeDt.class, order=0, min=1, max=1, summary=false, modifier=false)    
5755        @Description(
5756                shortDefinition="",
5757                formalDefinition="A coded identifier of the operation, supported by the system"
5758        )
5759        private BoundCodeDt<SystemRestfulInteractionEnum> myCode;
5760        
5761        @Child(name="documentation", type=StringDt.class, order=1, min=0, max=1, summary=false, modifier=false) 
5762        @Description(
5763                shortDefinition="",
5764                formalDefinition="Guidance specific to the implementation of this operation, such as limitations on the kind of transactions allowed, or information about system wide search is implemented"
5765        )
5766        private StringDt myDocumentation;
5767        
5768
5769        @Override
5770        public boolean isEmpty() {
5771                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myCode,  myDocumentation);
5772        }
5773        
5774        @Override
5775        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
5776                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myCode, myDocumentation);
5777        }
5778
5779        /**
5780         * Gets the value(s) for <b>code</b> ().
5781         * creating it if it does
5782         * not exist. Will not return <code>null</code>.
5783         *
5784     * <p>
5785     * <b>Definition:</b>
5786     * A coded identifier of the operation, supported by the system
5787     * </p> 
5788         */
5789        public BoundCodeDt<SystemRestfulInteractionEnum> getCodeElement() {  
5790                if (myCode == null) {
5791                        myCode = new BoundCodeDt<SystemRestfulInteractionEnum>(SystemRestfulInteractionEnum.VALUESET_BINDER);
5792                }
5793                return myCode;
5794        }
5795
5796        
5797        /**
5798         * Gets the value(s) for <b>code</b> ().
5799         * creating it if it does
5800         * not exist. Will not return <code>null</code>.
5801         *
5802     * <p>
5803     * <b>Definition:</b>
5804     * A coded identifier of the operation, supported by the system
5805     * </p> 
5806         */
5807        public String getCode() {  
5808                return getCodeElement().getValue();
5809        }
5810
5811        /**
5812         * Sets the value(s) for <b>code</b> ()
5813         *
5814     * <p>
5815     * <b>Definition:</b>
5816     * A coded identifier of the operation, supported by the system
5817     * </p> 
5818         */
5819        public RestInteraction setCode(BoundCodeDt<SystemRestfulInteractionEnum> theValue) {
5820                myCode = theValue;
5821                return this;
5822        }
5823        
5824        
5825
5826        /**
5827         * Sets the value(s) for <b>code</b> ()
5828         *
5829     * <p>
5830     * <b>Definition:</b>
5831     * A coded identifier of the operation, supported by the system
5832     * </p> 
5833         */
5834        public RestInteraction setCode(SystemRestfulInteractionEnum theValue) {
5835                setCode(new BoundCodeDt<SystemRestfulInteractionEnum>(SystemRestfulInteractionEnum.VALUESET_BINDER, theValue));
5836                
5837/*
5838                getCodeElement().setValueAsEnum(theValue);
5839*/
5840                return this;
5841        }
5842
5843  
5844        /**
5845         * Gets the value(s) for <b>documentation</b> ().
5846         * creating it if it does
5847         * not exist. Will not return <code>null</code>.
5848         *
5849     * <p>
5850     * <b>Definition:</b>
5851     * Guidance specific to the implementation of this operation, such as limitations on the kind of transactions allowed, or information about system wide search is implemented
5852     * </p> 
5853         */
5854        public StringDt getDocumentationElement() {  
5855                if (myDocumentation == null) {
5856                        myDocumentation = new StringDt();
5857                }
5858                return myDocumentation;
5859        }
5860
5861        
5862        /**
5863         * Gets the value(s) for <b>documentation</b> ().
5864         * creating it if it does
5865         * not exist. Will not return <code>null</code>.
5866         *
5867     * <p>
5868     * <b>Definition:</b>
5869     * Guidance specific to the implementation of this operation, such as limitations on the kind of transactions allowed, or information about system wide search is implemented
5870     * </p> 
5871         */
5872        public String getDocumentation() {  
5873                return getDocumentationElement().getValue();
5874        }
5875
5876        /**
5877         * Sets the value(s) for <b>documentation</b> ()
5878         *
5879     * <p>
5880     * <b>Definition:</b>
5881     * Guidance specific to the implementation of this operation, such as limitations on the kind of transactions allowed, or information about system wide search is implemented
5882     * </p> 
5883         */
5884        public RestInteraction setDocumentation(StringDt theValue) {
5885                myDocumentation = theValue;
5886                return this;
5887        }
5888        
5889        
5890
5891        /**
5892         * Sets the value for <b>documentation</b> ()
5893         *
5894     * <p>
5895     * <b>Definition:</b>
5896     * Guidance specific to the implementation of this operation, such as limitations on the kind of transactions allowed, or information about system wide search is implemented
5897     * </p> 
5898         */
5899        public RestInteraction setDocumentation( String theString) {
5900                myDocumentation = new StringDt(theString); 
5901                return this; 
5902        }
5903
5904 
5905
5906
5907        }
5908
5909
5910        /**
5911         * Block class for child element: <b>Conformance.rest.operation</b> ()
5912         *
5913     * <p>
5914     * <b>Definition:</b>
5915     * Definition of an operation or a named query and with its parameters and their meaning and type
5916     * </p> 
5917         */
5918        @Block()        
5919        public static class RestOperation 
5920            extends  BaseIdentifiableElement        implements IResourceBlock {
5921        
5922        @Child(name="name", type=StringDt.class, order=0, min=1, max=1, summary=false, modifier=false)  
5923        @Description(
5924                shortDefinition="",
5925                formalDefinition="The name of a query, which is used in the _query parameter when the query is called"
5926        )
5927        private StringDt myName;
5928        
5929        @Child(name="definition", order=1, min=1, max=1, summary=false, modifier=false, type={
5930                ca.uhn.fhir.model.dstu2.resource.OperationDefinition.class      })
5931        @Description(
5932                shortDefinition="",
5933                formalDefinition="Where the formal definition can be found"
5934        )
5935        private ResourceReferenceDt myDefinition;
5936        
5937
5938        @Override
5939        public boolean isEmpty() {
5940                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myName,  myDefinition);
5941        }
5942        
5943        @Override
5944        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
5945                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myName, myDefinition);
5946        }
5947
5948        /**
5949         * Gets the value(s) for <b>name</b> ().
5950         * creating it if it does
5951         * not exist. Will not return <code>null</code>.
5952         *
5953     * <p>
5954     * <b>Definition:</b>
5955     * The name of a query, which is used in the _query parameter when the query is called
5956     * </p> 
5957         */
5958        public StringDt getNameElement() {  
5959                if (myName == null) {
5960                        myName = new StringDt();
5961                }
5962                return myName;
5963        }
5964
5965        
5966        /**
5967         * Gets the value(s) for <b>name</b> ().
5968         * creating it if it does
5969         * not exist. Will not return <code>null</code>.
5970         *
5971     * <p>
5972     * <b>Definition:</b>
5973     * The name of a query, which is used in the _query parameter when the query is called
5974     * </p> 
5975         */
5976        public String getName() {  
5977                return getNameElement().getValue();
5978        }
5979
5980        /**
5981         * Sets the value(s) for <b>name</b> ()
5982         *
5983     * <p>
5984     * <b>Definition:</b>
5985     * The name of a query, which is used in the _query parameter when the query is called
5986     * </p> 
5987         */
5988        public RestOperation setName(StringDt theValue) {
5989                myName = theValue;
5990                return this;
5991        }
5992        
5993        
5994
5995        /**
5996         * Sets the value for <b>name</b> ()
5997         *
5998     * <p>
5999     * <b>Definition:</b>
6000     * The name of a query, which is used in the _query parameter when the query is called
6001     * </p> 
6002         */
6003        public RestOperation setName( String theString) {
6004                myName = new StringDt(theString); 
6005                return this; 
6006        }
6007
6008 
6009        /**
6010         * Gets the value(s) for <b>definition</b> ().
6011         * creating it if it does
6012         * not exist. Will not return <code>null</code>.
6013         *
6014     * <p>
6015     * <b>Definition:</b>
6016     * Where the formal definition can be found
6017     * </p> 
6018         */
6019        public ResourceReferenceDt getDefinition() {  
6020                if (myDefinition == null) {
6021                        myDefinition = new ResourceReferenceDt();
6022                }
6023                return myDefinition;
6024        }
6025
6026        /**
6027         * Sets the value(s) for <b>definition</b> ()
6028         *
6029     * <p>
6030     * <b>Definition:</b>
6031     * Where the formal definition can be found
6032     * </p> 
6033         */
6034        public RestOperation setDefinition(ResourceReferenceDt theValue) {
6035                myDefinition = theValue;
6036                return this;
6037        }
6038        
6039        
6040
6041  
6042
6043
6044        }
6045
6046
6047
6048        /**
6049         * Block class for child element: <b>Conformance.messaging</b> ()
6050         *
6051     * <p>
6052     * <b>Definition:</b>
6053     * A description of the messaging capabilities of the solution
6054     * </p> 
6055         */
6056        @Block()        
6057        public static class Messaging 
6058            extends  BaseIdentifiableElement        implements IResourceBlock {
6059        
6060        @Child(name="endpoint", order=0, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false) 
6061        @Description(
6062                shortDefinition="",
6063                formalDefinition="An endpoint (network accessible address) to which messages and/or replies are to be sent."
6064        )
6065        private java.util.List<MessagingEndpoint> myEndpoint;
6066        
6067        @Child(name="reliableCache", type=UnsignedIntDt.class, order=1, min=0, max=1, summary=false, modifier=false)    
6068        @Description(
6069                shortDefinition="",
6070                formalDefinition="Length if the receiver's reliable messaging cache in minutes (if a receiver) or how long the cache length on the receiver should be (if a sender)"
6071        )
6072        private UnsignedIntDt myReliableCache;
6073        
6074        @Child(name="documentation", type=StringDt.class, order=2, min=0, max=1, summary=false, modifier=false) 
6075        @Description(
6076                shortDefinition="",
6077                formalDefinition="Documentation about the system's messaging capabilities for this endpoint not otherwise documented by the conformance statement.  For example, process for becoming an authorized messaging exchange partner."
6078        )
6079        private StringDt myDocumentation;
6080        
6081        @Child(name="event", order=3, min=1, max=Child.MAX_UNLIMITED, summary=false, modifier=false)    
6082        @Description(
6083                shortDefinition="",
6084                formalDefinition="A description of the solution's support for an event at this end-point."
6085        )
6086        private java.util.List<MessagingEvent> myEvent;
6087        
6088
6089        @Override
6090        public boolean isEmpty() {
6091                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myEndpoint,  myReliableCache,  myDocumentation,  myEvent);
6092        }
6093        
6094        @Override
6095        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
6096                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myEndpoint, myReliableCache, myDocumentation, myEvent);
6097        }
6098
6099        /**
6100         * Gets the value(s) for <b>endpoint</b> ().
6101         * creating it if it does
6102         * not exist. Will not return <code>null</code>.
6103         *
6104     * <p>
6105     * <b>Definition:</b>
6106     * An endpoint (network accessible address) to which messages and/or replies are to be sent.
6107     * </p> 
6108         */
6109        public java.util.List<MessagingEndpoint> getEndpoint() {  
6110                if (myEndpoint == null) {
6111                        myEndpoint = new java.util.ArrayList<MessagingEndpoint>();
6112                }
6113                return myEndpoint;
6114        }
6115
6116        /**
6117         * Sets the value(s) for <b>endpoint</b> ()
6118         *
6119     * <p>
6120     * <b>Definition:</b>
6121     * An endpoint (network accessible address) to which messages and/or replies are to be sent.
6122     * </p> 
6123         */
6124        public Messaging setEndpoint(java.util.List<MessagingEndpoint> theValue) {
6125                myEndpoint = theValue;
6126                return this;
6127        }
6128        
6129        
6130
6131        /**
6132         * Adds and returns a new value for <b>endpoint</b> ()
6133         *
6134     * <p>
6135     * <b>Definition:</b>
6136     * An endpoint (network accessible address) to which messages and/or replies are to be sent.
6137     * </p> 
6138         */
6139        public MessagingEndpoint addEndpoint() {
6140                MessagingEndpoint newType = new MessagingEndpoint();
6141                getEndpoint().add(newType);
6142                return newType; 
6143        }
6144
6145        /**
6146         * Adds a given new value for <b>endpoint</b> ()
6147         *
6148         * <p>
6149         * <b>Definition:</b>
6150         * An endpoint (network accessible address) to which messages and/or replies are to be sent.
6151         * </p>
6152         * @param theValue The endpoint to add (must not be <code>null</code>)
6153         */
6154        public Messaging addEndpoint(MessagingEndpoint theValue) {
6155                if (theValue == null) {
6156                        throw new NullPointerException("theValue must not be null");
6157                }
6158                getEndpoint().add(theValue);
6159                return this;
6160        }
6161
6162        /**
6163         * Gets the first repetition for <b>endpoint</b> (),
6164         * creating it if it does not already exist.
6165         *
6166     * <p>
6167     * <b>Definition:</b>
6168     * An endpoint (network accessible address) to which messages and/or replies are to be sent.
6169     * </p> 
6170         */
6171        public MessagingEndpoint getEndpointFirstRep() {
6172                if (getEndpoint().isEmpty()) {
6173                        return addEndpoint();
6174                }
6175                return getEndpoint().get(0); 
6176        }
6177  
6178        /**
6179         * Gets the value(s) for <b>reliableCache</b> ().
6180         * creating it if it does
6181         * not exist. Will not return <code>null</code>.
6182         *
6183     * <p>
6184     * <b>Definition:</b>
6185     * Length if the receiver's reliable messaging cache in minutes (if a receiver) or how long the cache length on the receiver should be (if a sender)
6186     * </p> 
6187         */
6188        public UnsignedIntDt getReliableCacheElement() {  
6189                if (myReliableCache == null) {
6190                        myReliableCache = new UnsignedIntDt();
6191                }
6192                return myReliableCache;
6193        }
6194
6195        
6196        /**
6197         * Gets the value(s) for <b>reliableCache</b> ().
6198         * creating it if it does
6199         * not exist. Will not return <code>null</code>.
6200         *
6201     * <p>
6202     * <b>Definition:</b>
6203     * Length if the receiver's reliable messaging cache in minutes (if a receiver) or how long the cache length on the receiver should be (if a sender)
6204     * </p> 
6205         */
6206        public Integer getReliableCache() {  
6207                return getReliableCacheElement().getValue();
6208        }
6209
6210        /**
6211         * Sets the value(s) for <b>reliableCache</b> ()
6212         *
6213     * <p>
6214     * <b>Definition:</b>
6215     * Length if the receiver's reliable messaging cache in minutes (if a receiver) or how long the cache length on the receiver should be (if a sender)
6216     * </p> 
6217         */
6218        public Messaging setReliableCache(UnsignedIntDt theValue) {
6219                myReliableCache = theValue;
6220                return this;
6221        }
6222        
6223        
6224
6225        /**
6226         * Sets the value for <b>reliableCache</b> ()
6227         *
6228     * <p>
6229     * <b>Definition:</b>
6230     * Length if the receiver's reliable messaging cache in minutes (if a receiver) or how long the cache length on the receiver should be (if a sender)
6231     * </p> 
6232         */
6233        public Messaging setReliableCache( int theInteger) {
6234                myReliableCache = new UnsignedIntDt(theInteger); 
6235                return this; 
6236        }
6237
6238 
6239        /**
6240         * Gets the value(s) for <b>documentation</b> ().
6241         * creating it if it does
6242         * not exist. Will not return <code>null</code>.
6243         *
6244     * <p>
6245     * <b>Definition:</b>
6246     * Documentation about the system's messaging capabilities for this endpoint not otherwise documented by the conformance statement.  For example, process for becoming an authorized messaging exchange partner.
6247     * </p> 
6248         */
6249        public StringDt getDocumentationElement() {  
6250                if (myDocumentation == null) {
6251                        myDocumentation = new StringDt();
6252                }
6253                return myDocumentation;
6254        }
6255
6256        
6257        /**
6258         * Gets the value(s) for <b>documentation</b> ().
6259         * creating it if it does
6260         * not exist. Will not return <code>null</code>.
6261         *
6262     * <p>
6263     * <b>Definition:</b>
6264     * Documentation about the system's messaging capabilities for this endpoint not otherwise documented by the conformance statement.  For example, process for becoming an authorized messaging exchange partner.
6265     * </p> 
6266         */
6267        public String getDocumentation() {  
6268                return getDocumentationElement().getValue();
6269        }
6270
6271        /**
6272         * Sets the value(s) for <b>documentation</b> ()
6273         *
6274     * <p>
6275     * <b>Definition:</b>
6276     * Documentation about the system's messaging capabilities for this endpoint not otherwise documented by the conformance statement.  For example, process for becoming an authorized messaging exchange partner.
6277     * </p> 
6278         */
6279        public Messaging setDocumentation(StringDt theValue) {
6280                myDocumentation = theValue;
6281                return this;
6282        }
6283        
6284        
6285
6286        /**
6287         * Sets the value for <b>documentation</b> ()
6288         *
6289     * <p>
6290     * <b>Definition:</b>
6291     * Documentation about the system's messaging capabilities for this endpoint not otherwise documented by the conformance statement.  For example, process for becoming an authorized messaging exchange partner.
6292     * </p> 
6293         */
6294        public Messaging setDocumentation( String theString) {
6295                myDocumentation = new StringDt(theString); 
6296                return this; 
6297        }
6298
6299 
6300        /**
6301         * Gets the value(s) for <b>event</b> ().
6302         * creating it if it does
6303         * not exist. Will not return <code>null</code>.
6304         *
6305     * <p>
6306     * <b>Definition:</b>
6307     * A description of the solution's support for an event at this end-point.
6308     * </p> 
6309         */
6310        public java.util.List<MessagingEvent> getEvent() {  
6311                if (myEvent == null) {
6312                        myEvent = new java.util.ArrayList<MessagingEvent>();
6313                }
6314                return myEvent;
6315        }
6316
6317        /**
6318         * Sets the value(s) for <b>event</b> ()
6319         *
6320     * <p>
6321     * <b>Definition:</b>
6322     * A description of the solution's support for an event at this end-point.
6323     * </p> 
6324         */
6325        public Messaging setEvent(java.util.List<MessagingEvent> theValue) {
6326                myEvent = theValue;
6327                return this;
6328        }
6329        
6330        
6331
6332        /**
6333         * Adds and returns a new value for <b>event</b> ()
6334         *
6335     * <p>
6336     * <b>Definition:</b>
6337     * A description of the solution's support for an event at this end-point.
6338     * </p> 
6339         */
6340        public MessagingEvent addEvent() {
6341                MessagingEvent newType = new MessagingEvent();
6342                getEvent().add(newType);
6343                return newType; 
6344        }
6345
6346        /**
6347         * Adds a given new value for <b>event</b> ()
6348         *
6349         * <p>
6350         * <b>Definition:</b>
6351         * A description of the solution's support for an event at this end-point.
6352         * </p>
6353         * @param theValue The event to add (must not be <code>null</code>)
6354         */
6355        public Messaging addEvent(MessagingEvent theValue) {
6356                if (theValue == null) {
6357                        throw new NullPointerException("theValue must not be null");
6358                }
6359                getEvent().add(theValue);
6360                return this;
6361        }
6362
6363        /**
6364         * Gets the first repetition for <b>event</b> (),
6365         * creating it if it does not already exist.
6366         *
6367     * <p>
6368     * <b>Definition:</b>
6369     * A description of the solution's support for an event at this end-point.
6370     * </p> 
6371         */
6372        public MessagingEvent getEventFirstRep() {
6373                if (getEvent().isEmpty()) {
6374                        return addEvent();
6375                }
6376                return getEvent().get(0); 
6377        }
6378  
6379
6380
6381        }
6382
6383        /**
6384         * Block class for child element: <b>Conformance.messaging.endpoint</b> ()
6385         *
6386     * <p>
6387     * <b>Definition:</b>
6388     * An endpoint (network accessible address) to which messages and/or replies are to be sent.
6389     * </p> 
6390         */
6391        @Block()        
6392        public static class MessagingEndpoint 
6393            extends  BaseIdentifiableElement        implements IResourceBlock {
6394        
6395        @Child(name="protocol", type=CodingDt.class, order=0, min=1, max=1, summary=false, modifier=false)      
6396        @Description(
6397                shortDefinition="",
6398                formalDefinition="A list of the messaging transport protocol(s) identifiers, supported by this endpoint"
6399        )
6400        private CodingDt myProtocol;
6401        
6402        @Child(name="address", type=UriDt.class, order=1, min=1, max=1, summary=false, modifier=false)  
6403        @Description(
6404                shortDefinition="",
6405                formalDefinition="The network address of the end-point. For solutions that do not use network addresses for routing, it can be just an identifier"
6406        )
6407        private UriDt myAddress;
6408        
6409
6410        @Override
6411        public boolean isEmpty() {
6412                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myProtocol,  myAddress);
6413        }
6414        
6415        @Override
6416        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
6417                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myProtocol, myAddress);
6418        }
6419
6420        /**
6421         * Gets the value(s) for <b>protocol</b> ().
6422         * creating it if it does
6423         * not exist. Will not return <code>null</code>.
6424         *
6425     * <p>
6426     * <b>Definition:</b>
6427     * A list of the messaging transport protocol(s) identifiers, supported by this endpoint
6428     * </p> 
6429         */
6430        public CodingDt getProtocol() {  
6431                if (myProtocol == null) {
6432                        myProtocol = new CodingDt();
6433                }
6434                return myProtocol;
6435        }
6436
6437        /**
6438         * Sets the value(s) for <b>protocol</b> ()
6439         *
6440     * <p>
6441     * <b>Definition:</b>
6442     * A list of the messaging transport protocol(s) identifiers, supported by this endpoint
6443     * </p> 
6444         */
6445        public MessagingEndpoint setProtocol(CodingDt theValue) {
6446                myProtocol = theValue;
6447                return this;
6448        }
6449        
6450        
6451
6452  
6453        /**
6454         * Gets the value(s) for <b>address</b> ().
6455         * creating it if it does
6456         * not exist. Will not return <code>null</code>.
6457         *
6458     * <p>
6459     * <b>Definition:</b>
6460     * The network address of the end-point. For solutions that do not use network addresses for routing, it can be just an identifier
6461     * </p> 
6462         */
6463        public UriDt getAddressElement() {  
6464                if (myAddress == null) {
6465                        myAddress = new UriDt();
6466                }
6467                return myAddress;
6468        }
6469
6470        
6471        /**
6472         * Gets the value(s) for <b>address</b> ().
6473         * creating it if it does
6474         * not exist. Will not return <code>null</code>.
6475         *
6476     * <p>
6477     * <b>Definition:</b>
6478     * The network address of the end-point. For solutions that do not use network addresses for routing, it can be just an identifier
6479     * </p> 
6480         */
6481        public String getAddress() {  
6482                return getAddressElement().getValue();
6483        }
6484
6485        /**
6486         * Sets the value(s) for <b>address</b> ()
6487         *
6488     * <p>
6489     * <b>Definition:</b>
6490     * The network address of the end-point. For solutions that do not use network addresses for routing, it can be just an identifier
6491     * </p> 
6492         */
6493        public MessagingEndpoint setAddress(UriDt theValue) {
6494                myAddress = theValue;
6495                return this;
6496        }
6497        
6498        
6499
6500        /**
6501         * Sets the value for <b>address</b> ()
6502         *
6503     * <p>
6504     * <b>Definition:</b>
6505     * The network address of the end-point. For solutions that do not use network addresses for routing, it can be just an identifier
6506     * </p> 
6507         */
6508        public MessagingEndpoint setAddress( String theUri) {
6509                myAddress = new UriDt(theUri); 
6510                return this; 
6511        }
6512
6513 
6514
6515
6516        }
6517
6518
6519        /**
6520         * Block class for child element: <b>Conformance.messaging.event</b> ()
6521         *
6522     * <p>
6523     * <b>Definition:</b>
6524     * A description of the solution's support for an event at this end-point.
6525     * </p> 
6526         */
6527        @Block()        
6528        public static class MessagingEvent 
6529            extends  BaseIdentifiableElement        implements IResourceBlock {
6530        
6531        @Child(name="code", type=CodingDt.class, order=0, min=1, max=1, summary=false, modifier=false)  
6532        @Description(
6533                shortDefinition="",
6534                formalDefinition="A coded identifier of a supported messaging event"
6535        )
6536        private CodingDt myCode;
6537        
6538        @Child(name="category", type=CodeDt.class, order=1, min=0, max=1, summary=false, modifier=false)        
6539        @Description(
6540                shortDefinition="",
6541                formalDefinition="The impact of the content of the message"
6542        )
6543        private BoundCodeDt<MessageSignificanceCategoryEnum> myCategory;
6544        
6545        @Child(name="mode", type=CodeDt.class, order=2, min=1, max=1, summary=false, modifier=false)    
6546        @Description(
6547                shortDefinition="",
6548                formalDefinition="The mode of this event declaration - whether application is sender or receiver"
6549        )
6550        private BoundCodeDt<ConformanceEventModeEnum> myMode;
6551        
6552        @Child(name="focus", type=CodeDt.class, order=3, min=1, max=1, summary=false, modifier=false)   
6553        @Description(
6554                shortDefinition="",
6555                formalDefinition="A resource associated with the event.  This is the resource that defines the event."
6556        )
6557        private BoundCodeDt<ResourceTypeEnum> myFocus;
6558        
6559        @Child(name="request", order=4, min=1, max=1, summary=false, modifier=false, type={
6560                ca.uhn.fhir.model.dstu2.resource.StructureDefinition.class      })
6561        @Description(
6562                shortDefinition="",
6563                formalDefinition="Information about the request for this event"
6564        )
6565        private ResourceReferenceDt myRequest;
6566        
6567        @Child(name="response", order=5, min=1, max=1, summary=false, modifier=false, type={
6568                ca.uhn.fhir.model.dstu2.resource.StructureDefinition.class      })
6569        @Description(
6570                shortDefinition="",
6571                formalDefinition="Information about the response for this event"
6572        )
6573        private ResourceReferenceDt myResponse;
6574        
6575        @Child(name="documentation", type=StringDt.class, order=6, min=0, max=1, summary=false, modifier=false) 
6576        @Description(
6577                shortDefinition="",
6578                formalDefinition="Guidance on how this event is handled, such as internal system trigger points, business rules, etc."
6579        )
6580        private StringDt myDocumentation;
6581        
6582
6583        @Override
6584        public boolean isEmpty() {
6585                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myCode,  myCategory,  myMode,  myFocus,  myRequest,  myResponse,  myDocumentation);
6586        }
6587        
6588        @Override
6589        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
6590                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myCode, myCategory, myMode, myFocus, myRequest, myResponse, myDocumentation);
6591        }
6592
6593        /**
6594         * Gets the value(s) for <b>code</b> ().
6595         * creating it if it does
6596         * not exist. Will not return <code>null</code>.
6597         *
6598     * <p>
6599     * <b>Definition:</b>
6600     * A coded identifier of a supported messaging event
6601     * </p> 
6602         */
6603        public CodingDt getCode() {  
6604                if (myCode == null) {
6605                        myCode = new CodingDt();
6606                }
6607                return myCode;
6608        }
6609
6610        /**
6611         * Sets the value(s) for <b>code</b> ()
6612         *
6613     * <p>
6614     * <b>Definition:</b>
6615     * A coded identifier of a supported messaging event
6616     * </p> 
6617         */
6618        public MessagingEvent setCode(CodingDt theValue) {
6619                myCode = theValue;
6620                return this;
6621        }
6622        
6623        
6624
6625  
6626        /**
6627         * Gets the value(s) for <b>category</b> ().
6628         * creating it if it does
6629         * not exist. Will not return <code>null</code>.
6630         *
6631     * <p>
6632     * <b>Definition:</b>
6633     * The impact of the content of the message
6634     * </p> 
6635         */
6636        public BoundCodeDt<MessageSignificanceCategoryEnum> getCategoryElement() {  
6637                if (myCategory == null) {
6638                        myCategory = new BoundCodeDt<MessageSignificanceCategoryEnum>(MessageSignificanceCategoryEnum.VALUESET_BINDER);
6639                }
6640                return myCategory;
6641        }
6642
6643        
6644        /**
6645         * Gets the value(s) for <b>category</b> ().
6646         * creating it if it does
6647         * not exist. Will not return <code>null</code>.
6648         *
6649     * <p>
6650     * <b>Definition:</b>
6651     * The impact of the content of the message
6652     * </p> 
6653         */
6654        public String getCategory() {  
6655                return getCategoryElement().getValue();
6656        }
6657
6658        /**
6659         * Sets the value(s) for <b>category</b> ()
6660         *
6661     * <p>
6662     * <b>Definition:</b>
6663     * The impact of the content of the message
6664     * </p> 
6665         */
6666        public MessagingEvent setCategory(BoundCodeDt<MessageSignificanceCategoryEnum> theValue) {
6667                myCategory = theValue;
6668                return this;
6669        }
6670        
6671        
6672
6673        /**
6674         * Sets the value(s) for <b>category</b> ()
6675         *
6676     * <p>
6677     * <b>Definition:</b>
6678     * The impact of the content of the message
6679     * </p> 
6680         */
6681        public MessagingEvent setCategory(MessageSignificanceCategoryEnum theValue) {
6682                setCategory(new BoundCodeDt<MessageSignificanceCategoryEnum>(MessageSignificanceCategoryEnum.VALUESET_BINDER, theValue));
6683                
6684/*
6685                getCategoryElement().setValueAsEnum(theValue);
6686*/
6687                return this;
6688        }
6689
6690  
6691        /**
6692         * Gets the value(s) for <b>mode</b> ().
6693         * creating it if it does
6694         * not exist. Will not return <code>null</code>.
6695         *
6696     * <p>
6697     * <b>Definition:</b>
6698     * The mode of this event declaration - whether application is sender or receiver
6699     * </p> 
6700         */
6701        public BoundCodeDt<ConformanceEventModeEnum> getModeElement() {  
6702                if (myMode == null) {
6703                        myMode = new BoundCodeDt<ConformanceEventModeEnum>(ConformanceEventModeEnum.VALUESET_BINDER);
6704                }
6705                return myMode;
6706        }
6707
6708        
6709        /**
6710         * Gets the value(s) for <b>mode</b> ().
6711         * creating it if it does
6712         * not exist. Will not return <code>null</code>.
6713         *
6714     * <p>
6715     * <b>Definition:</b>
6716     * The mode of this event declaration - whether application is sender or receiver
6717     * </p> 
6718         */
6719        public String getMode() {  
6720                return getModeElement().getValue();
6721        }
6722
6723        /**
6724         * Sets the value(s) for <b>mode</b> ()
6725         *
6726     * <p>
6727     * <b>Definition:</b>
6728     * The mode of this event declaration - whether application is sender or receiver
6729     * </p> 
6730         */
6731        public MessagingEvent setMode(BoundCodeDt<ConformanceEventModeEnum> theValue) {
6732                myMode = theValue;
6733                return this;
6734        }
6735        
6736        
6737
6738        /**
6739         * Sets the value(s) for <b>mode</b> ()
6740         *
6741     * <p>
6742     * <b>Definition:</b>
6743     * The mode of this event declaration - whether application is sender or receiver
6744     * </p> 
6745         */
6746        public MessagingEvent setMode(ConformanceEventModeEnum theValue) {
6747                setMode(new BoundCodeDt<ConformanceEventModeEnum>(ConformanceEventModeEnum.VALUESET_BINDER, theValue));
6748                
6749/*
6750                getModeElement().setValueAsEnum(theValue);
6751*/
6752                return this;
6753        }
6754
6755  
6756        /**
6757         * Gets the value(s) for <b>focus</b> ().
6758         * creating it if it does
6759         * not exist. Will not return <code>null</code>.
6760         *
6761     * <p>
6762     * <b>Definition:</b>
6763     * A resource associated with the event.  This is the resource that defines the event.
6764     * </p> 
6765         */
6766        public BoundCodeDt<ResourceTypeEnum> getFocusElement() {  
6767                if (myFocus == null) {
6768                        myFocus = new BoundCodeDt<ResourceTypeEnum>(ResourceTypeEnum.VALUESET_BINDER);
6769                }
6770                return myFocus;
6771        }
6772
6773        
6774        /**
6775         * Gets the value(s) for <b>focus</b> ().
6776         * creating it if it does
6777         * not exist. Will not return <code>null</code>.
6778         *
6779     * <p>
6780     * <b>Definition:</b>
6781     * A resource associated with the event.  This is the resource that defines the event.
6782     * </p> 
6783         */
6784        public String getFocus() {  
6785                return getFocusElement().getValue();
6786        }
6787
6788        /**
6789         * Sets the value(s) for <b>focus</b> ()
6790         *
6791     * <p>
6792     * <b>Definition:</b>
6793     * A resource associated with the event.  This is the resource that defines the event.
6794     * </p> 
6795         */
6796        public MessagingEvent setFocus(BoundCodeDt<ResourceTypeEnum> theValue) {
6797                myFocus = theValue;
6798                return this;
6799        }
6800        
6801        
6802
6803        /**
6804         * Sets the value(s) for <b>focus</b> ()
6805         *
6806     * <p>
6807     * <b>Definition:</b>
6808     * A resource associated with the event.  This is the resource that defines the event.
6809     * </p> 
6810         */
6811        public MessagingEvent setFocus(ResourceTypeEnum theValue) {
6812                setFocus(new BoundCodeDt<ResourceTypeEnum>(ResourceTypeEnum.VALUESET_BINDER, theValue));
6813                
6814/*
6815                getFocusElement().setValueAsEnum(theValue);
6816*/
6817                return this;
6818        }
6819
6820  
6821        /**
6822         * Gets the value(s) for <b>request</b> ().
6823         * creating it if it does
6824         * not exist. Will not return <code>null</code>.
6825         *
6826     * <p>
6827     * <b>Definition:</b>
6828     * Information about the request for this event
6829     * </p> 
6830         */
6831        public ResourceReferenceDt getRequest() {  
6832                if (myRequest == null) {
6833                        myRequest = new ResourceReferenceDt();
6834                }
6835                return myRequest;
6836        }
6837
6838        /**
6839         * Sets the value(s) for <b>request</b> ()
6840         *
6841     * <p>
6842     * <b>Definition:</b>
6843     * Information about the request for this event
6844     * </p> 
6845         */
6846        public MessagingEvent setRequest(ResourceReferenceDt theValue) {
6847                myRequest = theValue;
6848                return this;
6849        }
6850        
6851        
6852
6853  
6854        /**
6855         * Gets the value(s) for <b>response</b> ().
6856         * creating it if it does
6857         * not exist. Will not return <code>null</code>.
6858         *
6859     * <p>
6860     * <b>Definition:</b>
6861     * Information about the response for this event
6862     * </p> 
6863         */
6864        public ResourceReferenceDt getResponse() {  
6865                if (myResponse == null) {
6866                        myResponse = new ResourceReferenceDt();
6867                }
6868                return myResponse;
6869        }
6870
6871        /**
6872         * Sets the value(s) for <b>response</b> ()
6873         *
6874     * <p>
6875     * <b>Definition:</b>
6876     * Information about the response for this event
6877     * </p> 
6878         */
6879        public MessagingEvent setResponse(ResourceReferenceDt theValue) {
6880                myResponse = theValue;
6881                return this;
6882        }
6883        
6884        
6885
6886  
6887        /**
6888         * Gets the value(s) for <b>documentation</b> ().
6889         * creating it if it does
6890         * not exist. Will not return <code>null</code>.
6891         *
6892     * <p>
6893     * <b>Definition:</b>
6894     * Guidance on how this event is handled, such as internal system trigger points, business rules, etc.
6895     * </p> 
6896         */
6897        public StringDt getDocumentationElement() {  
6898                if (myDocumentation == null) {
6899                        myDocumentation = new StringDt();
6900                }
6901                return myDocumentation;
6902        }
6903
6904        
6905        /**
6906         * Gets the value(s) for <b>documentation</b> ().
6907         * creating it if it does
6908         * not exist. Will not return <code>null</code>.
6909         *
6910     * <p>
6911     * <b>Definition:</b>
6912     * Guidance on how this event is handled, such as internal system trigger points, business rules, etc.
6913     * </p> 
6914         */
6915        public String getDocumentation() {  
6916                return getDocumentationElement().getValue();
6917        }
6918
6919        /**
6920         * Sets the value(s) for <b>documentation</b> ()
6921         *
6922     * <p>
6923     * <b>Definition:</b>
6924     * Guidance on how this event is handled, such as internal system trigger points, business rules, etc.
6925     * </p> 
6926         */
6927        public MessagingEvent setDocumentation(StringDt theValue) {
6928                myDocumentation = theValue;
6929                return this;
6930        }
6931        
6932        
6933
6934        /**
6935         * Sets the value for <b>documentation</b> ()
6936         *
6937     * <p>
6938     * <b>Definition:</b>
6939     * Guidance on how this event is handled, such as internal system trigger points, business rules, etc.
6940     * </p> 
6941         */
6942        public MessagingEvent setDocumentation( String theString) {
6943                myDocumentation = new StringDt(theString); 
6944                return this; 
6945        }
6946
6947 
6948
6949
6950        }
6951
6952
6953
6954        /**
6955         * Block class for child element: <b>Conformance.document</b> ()
6956         *
6957     * <p>
6958     * <b>Definition:</b>
6959     * A document definition
6960     * </p> 
6961         */
6962        @Block()        
6963        public static class Document 
6964            extends  BaseIdentifiableElement        implements IResourceBlock {
6965        
6966        @Child(name="mode", type=CodeDt.class, order=0, min=1, max=1, summary=false, modifier=false)    
6967        @Description(
6968                shortDefinition="",
6969                formalDefinition="Mode of this document declaration - whether application is producer or consumer"
6970        )
6971        private BoundCodeDt<DocumentModeEnum> myMode;
6972        
6973        @Child(name="documentation", type=StringDt.class, order=1, min=0, max=1, summary=false, modifier=false) 
6974        @Description(
6975                shortDefinition="",
6976                formalDefinition="A description of how the application supports or uses the specified document profile.  For example, when are documents created, what action is taken with consumed documents, etc."
6977        )
6978        private StringDt myDocumentation;
6979        
6980        @Child(name="profile", order=2, min=1, max=1, summary=false, modifier=false, type={
6981                ca.uhn.fhir.model.dstu2.resource.StructureDefinition.class      })
6982        @Description(
6983                shortDefinition="",
6984                formalDefinition="A constraint on a resource used in the document"
6985        )
6986        private ResourceReferenceDt myProfile;
6987        
6988
6989        @Override
6990        public boolean isEmpty() {
6991                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myMode,  myDocumentation,  myProfile);
6992        }
6993        
6994        @Override
6995        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
6996                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myMode, myDocumentation, myProfile);
6997        }
6998
6999        /**
7000         * Gets the value(s) for <b>mode</b> ().
7001         * creating it if it does
7002         * not exist. Will not return <code>null</code>.
7003         *
7004     * <p>
7005     * <b>Definition:</b>
7006     * Mode of this document declaration - whether application is producer or consumer
7007     * </p> 
7008         */
7009        public BoundCodeDt<DocumentModeEnum> getModeElement() {  
7010                if (myMode == null) {
7011                        myMode = new BoundCodeDt<DocumentModeEnum>(DocumentModeEnum.VALUESET_BINDER);
7012                }
7013                return myMode;
7014        }
7015
7016        
7017        /**
7018         * Gets the value(s) for <b>mode</b> ().
7019         * creating it if it does
7020         * not exist. Will not return <code>null</code>.
7021         *
7022     * <p>
7023     * <b>Definition:</b>
7024     * Mode of this document declaration - whether application is producer or consumer
7025     * </p> 
7026         */
7027        public String getMode() {  
7028                return getModeElement().getValue();
7029        }
7030
7031        /**
7032         * Sets the value(s) for <b>mode</b> ()
7033         *
7034     * <p>
7035     * <b>Definition:</b>
7036     * Mode of this document declaration - whether application is producer or consumer
7037     * </p> 
7038         */
7039        public Document setMode(BoundCodeDt<DocumentModeEnum> theValue) {
7040                myMode = theValue;
7041                return this;
7042        }
7043        
7044        
7045
7046        /**
7047         * Sets the value(s) for <b>mode</b> ()
7048         *
7049     * <p>
7050     * <b>Definition:</b>
7051     * Mode of this document declaration - whether application is producer or consumer
7052     * </p> 
7053         */
7054        public Document setMode(DocumentModeEnum theValue) {
7055                setMode(new BoundCodeDt<DocumentModeEnum>(DocumentModeEnum.VALUESET_BINDER, theValue));
7056                
7057/*
7058                getModeElement().setValueAsEnum(theValue);
7059*/
7060                return this;
7061        }
7062
7063  
7064        /**
7065         * Gets the value(s) for <b>documentation</b> ().
7066         * creating it if it does
7067         * not exist. Will not return <code>null</code>.
7068         *
7069     * <p>
7070     * <b>Definition:</b>
7071     * A description of how the application supports or uses the specified document profile.  For example, when are documents created, what action is taken with consumed documents, etc.
7072     * </p> 
7073         */
7074        public StringDt getDocumentationElement() {  
7075                if (myDocumentation == null) {
7076                        myDocumentation = new StringDt();
7077                }
7078                return myDocumentation;
7079        }
7080
7081        
7082        /**
7083         * Gets the value(s) for <b>documentation</b> ().
7084         * creating it if it does
7085         * not exist. Will not return <code>null</code>.
7086         *
7087     * <p>
7088     * <b>Definition:</b>
7089     * A description of how the application supports or uses the specified document profile.  For example, when are documents created, what action is taken with consumed documents, etc.
7090     * </p> 
7091         */
7092        public String getDocumentation() {  
7093                return getDocumentationElement().getValue();
7094        }
7095
7096        /**
7097         * Sets the value(s) for <b>documentation</b> ()
7098         *
7099     * <p>
7100     * <b>Definition:</b>
7101     * A description of how the application supports or uses the specified document profile.  For example, when are documents created, what action is taken with consumed documents, etc.
7102     * </p> 
7103         */
7104        public Document setDocumentation(StringDt theValue) {
7105                myDocumentation = theValue;
7106                return this;
7107        }
7108        
7109        
7110
7111        /**
7112         * Sets the value for <b>documentation</b> ()
7113         *
7114     * <p>
7115     * <b>Definition:</b>
7116     * A description of how the application supports or uses the specified document profile.  For example, when are documents created, what action is taken with consumed documents, etc.
7117     * </p> 
7118         */
7119        public Document setDocumentation( String theString) {
7120                myDocumentation = new StringDt(theString); 
7121                return this; 
7122        }
7123
7124 
7125        /**
7126         * Gets the value(s) for <b>profile</b> ().
7127         * creating it if it does
7128         * not exist. Will not return <code>null</code>.
7129         *
7130     * <p>
7131     * <b>Definition:</b>
7132     * A constraint on a resource used in the document
7133     * </p> 
7134         */
7135        public ResourceReferenceDt getProfile() {  
7136                if (myProfile == null) {
7137                        myProfile = new ResourceReferenceDt();
7138                }
7139                return myProfile;
7140        }
7141
7142        /**
7143         * Sets the value(s) for <b>profile</b> ()
7144         *
7145     * <p>
7146     * <b>Definition:</b>
7147     * A constraint on a resource used in the document
7148     * </p> 
7149         */
7150        public Document setProfile(ResourceReferenceDt theValue) {
7151                myProfile = theValue;
7152                return this;
7153        }
7154        
7155        
7156
7157  
7158
7159
7160        }
7161
7162
7163
7164
7165    @Override
7166    public String getResourceName() {
7167        return "Conformance";
7168    }
7169    
7170    public ca.uhn.fhir.context.FhirVersionEnum getStructureFhirVersionEnum() {
7171        return ca.uhn.fhir.context.FhirVersionEnum.DSTU2;
7172    }
7173
7174
7175}