001
002
003
004
005
006
007
008
009
010
011
012
013
014
015
016
017package ca.uhn.fhir.model.dstu2.resource;
018
019import java.math.BigDecimal;
020import java.net.URI;
021import java.util.*;
022import ca.uhn.fhir.model.api.*;
023import ca.uhn.fhir.model.api.annotation.*;
024import ca.uhn.fhir.rest.gclient.*;
025
026import ca.uhn.fhir.model.dstu2.valueset.AccountStatusEnum;
027import ca.uhn.fhir.model.dstu2.valueset.ActionListEnum;
028import ca.uhn.fhir.model.dstu2.composite.AddressDt;
029import ca.uhn.fhir.model.dstu2.valueset.AdjudicationCodesEnum;
030import ca.uhn.fhir.model.dstu2.valueset.AdjudicationErrorCodesEnum;
031import ca.uhn.fhir.model.dstu2.valueset.AdjustmentReasonCodesEnum;
032import ca.uhn.fhir.model.dstu2.valueset.AdministrativeGenderEnum;
033import ca.uhn.fhir.model.dstu2.valueset.AdmitSourceEnum;
034import ca.uhn.fhir.model.dstu2.resource.AllergyIntolerance;
035import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceCategoryEnum;
036import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceCertaintyEnum;
037import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceCriticalityEnum;
038import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceSeverityEnum;
039import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceStatusEnum;
040import ca.uhn.fhir.model.dstu2.valueset.AllergyIntoleranceTypeEnum;
041import ca.uhn.fhir.model.dstu2.composite.AnnotationDt;
042import ca.uhn.fhir.model.dstu2.valueset.AnswerFormatEnum;
043import ca.uhn.fhir.model.dstu2.resource.Appointment;
044import ca.uhn.fhir.model.dstu2.valueset.AppointmentStatusEnum;
045import ca.uhn.fhir.model.dstu2.valueset.AssertionDirectionTypeEnum;
046import ca.uhn.fhir.model.dstu2.valueset.AssertionOperatorTypeEnum;
047import ca.uhn.fhir.model.dstu2.valueset.AssertionResponseTypesEnum;
048import ca.uhn.fhir.model.dstu2.composite.AttachmentDt;
049import ca.uhn.fhir.model.dstu2.valueset.AuditEventActionEnum;
050import ca.uhn.fhir.model.dstu2.valueset.AuditEventObjectLifecycleEnum;
051import ca.uhn.fhir.model.dstu2.valueset.AuditEventObjectRoleEnum;
052import ca.uhn.fhir.model.dstu2.valueset.AuditEventObjectTypeEnum;
053import ca.uhn.fhir.model.dstu2.valueset.AuditEventOutcomeEnum;
054import ca.uhn.fhir.model.dstu2.valueset.AuditEventParticipantNetworkTypeEnum;
055import ca.uhn.fhir.model.dstu2.valueset.AuditEventSourceTypeEnum;
056import ca.uhn.fhir.model.dstu2.valueset.BindingStrengthEnum;
057import ca.uhn.fhir.model.dstu2.resource.BodySite;
058import ca.uhn.fhir.model.dstu2.valueset.BundleTypeEnum;
059import ca.uhn.fhir.model.dstu2.resource.CarePlan;
060import ca.uhn.fhir.model.dstu2.valueset.CarePlanActivityStatusEnum;
061import ca.uhn.fhir.model.dstu2.valueset.CarePlanRelationshipEnum;
062import ca.uhn.fhir.model.dstu2.valueset.CarePlanStatusEnum;
063import ca.uhn.fhir.model.dstu2.resource.Claim;
064import ca.uhn.fhir.model.dstu2.resource.ClaimResponse;
065import ca.uhn.fhir.model.dstu2.valueset.ClaimTypeEnum;
066import ca.uhn.fhir.model.dstu2.resource.ClinicalImpression;
067import ca.uhn.fhir.model.dstu2.valueset.ClinicalImpressionStatusEnum;
068import ca.uhn.fhir.model.dstu2.composite.CodeableConceptDt;
069import ca.uhn.fhir.model.dstu2.composite.CodingDt;
070import ca.uhn.fhir.model.dstu2.resource.CommunicationRequest;
071import ca.uhn.fhir.model.dstu2.valueset.CommunicationRequestStatusEnum;
072import ca.uhn.fhir.model.dstu2.valueset.CommunicationStatusEnum;
073import ca.uhn.fhir.model.dstu2.resource.Composition;
074import ca.uhn.fhir.model.dstu2.valueset.CompositionAttestationModeEnum;
075import ca.uhn.fhir.model.dstu2.valueset.CompositionStatusEnum;
076import ca.uhn.fhir.model.dstu2.valueset.ConceptMapEquivalenceEnum;
077import ca.uhn.fhir.model.dstu2.resource.Condition;
078import ca.uhn.fhir.model.dstu2.valueset.ConditionCategoryCodesEnum;
079import ca.uhn.fhir.model.dstu2.valueset.ConditionClinicalStatusCodesEnum;
080import ca.uhn.fhir.model.dstu2.valueset.ConditionVerificationStatusEnum;
081import ca.uhn.fhir.model.dstu2.valueset.ConditionalDeleteStatusEnum;
082import ca.uhn.fhir.model.dstu2.resource.Conformance;
083import ca.uhn.fhir.model.dstu2.valueset.ConformanceEventModeEnum;
084import ca.uhn.fhir.model.dstu2.valueset.ConformanceResourceStatusEnum;
085import ca.uhn.fhir.model.dstu2.valueset.ConformanceStatementKindEnum;
086import ca.uhn.fhir.model.dstu2.composite.ContactPointDt;
087import ca.uhn.fhir.model.dstu2.valueset.ContentTypeEnum;
088import ca.uhn.fhir.model.dstu2.resource.Contract;
089import ca.uhn.fhir.model.dstu2.resource.Coverage;
090import ca.uhn.fhir.model.dstu2.valueset.DataElementStringencyEnum;
091import ca.uhn.fhir.model.dstu2.valueset.DaysOfWeekEnum;
092import ca.uhn.fhir.model.dstu2.valueset.DetectedIssueSeverityEnum;
093import ca.uhn.fhir.model.dstu2.resource.Device;
094import ca.uhn.fhir.model.dstu2.resource.DeviceComponent;
095import ca.uhn.fhir.model.dstu2.resource.DeviceMetric;
096import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricCalibrationStateEnum;
097import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricCalibrationTypeEnum;
098import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricCategoryEnum;
099import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricColorEnum;
100import ca.uhn.fhir.model.dstu2.valueset.DeviceMetricOperationalStatusEnum;
101import ca.uhn.fhir.model.dstu2.valueset.DeviceStatusEnum;
102import ca.uhn.fhir.model.dstu2.resource.DeviceUseRequest;
103import ca.uhn.fhir.model.dstu2.valueset.DeviceUseRequestPriorityEnum;
104import ca.uhn.fhir.model.dstu2.valueset.DeviceUseRequestStatusEnum;
105import ca.uhn.fhir.model.dstu2.resource.DiagnosticOrder;
106import ca.uhn.fhir.model.dstu2.valueset.DiagnosticOrderPriorityEnum;
107import ca.uhn.fhir.model.dstu2.valueset.DiagnosticOrderStatusEnum;
108import ca.uhn.fhir.model.dstu2.resource.DiagnosticReport;
109import ca.uhn.fhir.model.dstu2.valueset.DiagnosticReportStatusEnum;
110import ca.uhn.fhir.model.dstu2.valueset.DigitalMediaTypeEnum;
111import ca.uhn.fhir.model.dstu2.valueset.DocumentModeEnum;
112import ca.uhn.fhir.model.dstu2.resource.DocumentReference;
113import ca.uhn.fhir.model.dstu2.valueset.DocumentReferenceStatusEnum;
114import ca.uhn.fhir.model.dstu2.valueset.DocumentRelationshipTypeEnum;
115import ca.uhn.fhir.model.dstu2.composite.ElementDefinitionDt;
116import ca.uhn.fhir.model.dstu2.resource.EligibilityRequest;
117import ca.uhn.fhir.model.dstu2.resource.Encounter;
118import ca.uhn.fhir.model.dstu2.valueset.EncounterClassEnum;
119import ca.uhn.fhir.model.dstu2.valueset.EncounterLocationStatusEnum;
120import ca.uhn.fhir.model.dstu2.valueset.EncounterStateEnum;
121import ca.uhn.fhir.model.dstu2.resource.EnrollmentRequest;
122import ca.uhn.fhir.model.dstu2.resource.EpisodeOfCare;
123import ca.uhn.fhir.model.dstu2.valueset.EpisodeOfCareStatusEnum;
124import ca.uhn.fhir.model.dstu2.valueset.ExtensionContextEnum;
125import ca.uhn.fhir.model.dstu2.valueset.FamilyHistoryStatusEnum;
126import ca.uhn.fhir.model.dstu2.resource.FamilyMemberHistory;
127import ca.uhn.fhir.model.dstu2.valueset.FilterOperatorEnum;
128import ca.uhn.fhir.model.dstu2.valueset.FlagStatusEnum;
129import ca.uhn.fhir.model.dstu2.resource.Goal;
130import ca.uhn.fhir.model.dstu2.valueset.GoalPriorityEnum;
131import ca.uhn.fhir.model.dstu2.valueset.GoalStatusEnum;
132import ca.uhn.fhir.model.dstu2.resource.Group;
133import ca.uhn.fhir.model.dstu2.valueset.GroupTypeEnum;
134import ca.uhn.fhir.model.dstu2.valueset.GuideDependencyTypeEnum;
135import ca.uhn.fhir.model.dstu2.valueset.GuidePageKindEnum;
136import ca.uhn.fhir.model.dstu2.valueset.GuideResourcePurposeEnum;
137import ca.uhn.fhir.model.dstu2.valueset.HTTPVerbEnum;
138import ca.uhn.fhir.model.dstu2.resource.HealthcareService;
139import ca.uhn.fhir.model.dstu2.composite.HumanNameDt;
140import ca.uhn.fhir.model.dstu2.composite.IdentifierDt;
141import ca.uhn.fhir.model.dstu2.valueset.IdentifierTypeCodesEnum;
142import ca.uhn.fhir.model.dstu2.valueset.IdentityAssuranceLevelEnum;
143import ca.uhn.fhir.model.dstu2.resource.ImagingObjectSelection;
144import ca.uhn.fhir.model.dstu2.resource.ImagingStudy;
145import ca.uhn.fhir.model.dstu2.resource.Immunization;
146import ca.uhn.fhir.model.dstu2.valueset.InstanceAvailabilityEnum;
147import ca.uhn.fhir.model.dstu2.valueset.IssueSeverityEnum;
148import ca.uhn.fhir.model.dstu2.valueset.IssueTypeEnum;
149import ca.uhn.fhir.model.dstu2.valueset.KOStitleEnum;
150import ca.uhn.fhir.model.dstu2.valueset.LinkTypeEnum;
151import ca.uhn.fhir.model.dstu2.valueset.ListModeEnum;
152import ca.uhn.fhir.model.dstu2.valueset.ListOrderCodesEnum;
153import ca.uhn.fhir.model.dstu2.valueset.ListStatusEnum;
154import ca.uhn.fhir.model.dstu2.resource.Location;
155import ca.uhn.fhir.model.dstu2.valueset.LocationModeEnum;
156import ca.uhn.fhir.model.dstu2.valueset.LocationStatusEnum;
157import ca.uhn.fhir.model.dstu2.valueset.LocationTypeEnum;
158import ca.uhn.fhir.model.dstu2.valueset.MaritalStatusCodesEnum;
159import ca.uhn.fhir.model.dstu2.valueset.MeasmntPrincipleEnum;
160import ca.uhn.fhir.model.dstu2.resource.Media;
161import ca.uhn.fhir.model.dstu2.resource.Medication;
162import ca.uhn.fhir.model.dstu2.valueset.MedicationAdministrationStatusEnum;
163import ca.uhn.fhir.model.dstu2.valueset.MedicationDispenseStatusEnum;
164import ca.uhn.fhir.model.dstu2.resource.MedicationOrder;
165import ca.uhn.fhir.model.dstu2.valueset.MedicationOrderStatusEnum;
166import ca.uhn.fhir.model.dstu2.resource.MedicationStatement;
167import ca.uhn.fhir.model.dstu2.valueset.MedicationStatementStatusEnum;
168import ca.uhn.fhir.model.dstu2.valueset.MessageEventEnum;
169import ca.uhn.fhir.model.dstu2.valueset.MessageSignificanceCategoryEnum;
170import ca.uhn.fhir.model.dstu2.valueset.MessageTransportEnum;
171import ca.uhn.fhir.model.dstu2.resource.NamingSystem;
172import ca.uhn.fhir.model.dstu2.valueset.NamingSystemIdentifierTypeEnum;
173import ca.uhn.fhir.model.dstu2.valueset.NamingSystemTypeEnum;
174import ca.uhn.fhir.model.dstu2.valueset.NoteTypeEnum;
175import ca.uhn.fhir.model.dstu2.resource.NutritionOrder;
176import ca.uhn.fhir.model.dstu2.valueset.NutritionOrderStatusEnum;
177import ca.uhn.fhir.model.dstu2.resource.Observation;
178import ca.uhn.fhir.model.dstu2.valueset.ObservationRelationshipTypeEnum;
179import ca.uhn.fhir.model.dstu2.valueset.ObservationStatusEnum;
180import ca.uhn.fhir.model.dstu2.resource.OperationDefinition;
181import ca.uhn.fhir.model.dstu2.valueset.OperationKindEnum;
182import ca.uhn.fhir.model.dstu2.resource.OperationOutcome;
183import ca.uhn.fhir.model.dstu2.valueset.OperationParameterUseEnum;
184import ca.uhn.fhir.model.dstu2.resource.Order;
185import ca.uhn.fhir.model.dstu2.valueset.OrderStatusEnum;
186import ca.uhn.fhir.model.dstu2.resource.Organization;
187import ca.uhn.fhir.model.dstu2.valueset.ParticipantRequiredEnum;
188import ca.uhn.fhir.model.dstu2.valueset.ParticipantStatusEnum;
189import ca.uhn.fhir.model.dstu2.valueset.ParticipantTypeEnum;
190import ca.uhn.fhir.model.dstu2.valueset.ParticipationStatusEnum;
191import ca.uhn.fhir.model.dstu2.resource.Patient;
192import ca.uhn.fhir.model.dstu2.valueset.PayeeTypeCodesEnum;
193import ca.uhn.fhir.model.dstu2.composite.PeriodDt;
194import ca.uhn.fhir.model.dstu2.resource.Person;
195import ca.uhn.fhir.model.dstu2.resource.Practitioner;
196import ca.uhn.fhir.model.dstu2.resource.Procedure;
197import ca.uhn.fhir.model.dstu2.resource.ProcedureRequest;
198import ca.uhn.fhir.model.dstu2.valueset.ProcedureRequestPriorityEnum;
199import ca.uhn.fhir.model.dstu2.valueset.ProcedureRequestStatusEnum;
200import ca.uhn.fhir.model.dstu2.valueset.ProcedureStatusEnum;
201import ca.uhn.fhir.model.dstu2.resource.ProcessRequest;
202import ca.uhn.fhir.model.dstu2.valueset.ProvenanceEntityRoleEnum;
203import ca.uhn.fhir.model.dstu2.composite.QuantityDt;
204import ca.uhn.fhir.model.dstu2.resource.Questionnaire;
205import ca.uhn.fhir.model.dstu2.resource.QuestionnaireResponse;
206import ca.uhn.fhir.model.dstu2.valueset.QuestionnaireResponseStatusEnum;
207import ca.uhn.fhir.model.dstu2.valueset.QuestionnaireStatusEnum;
208import ca.uhn.fhir.model.dstu2.composite.RangeDt;
209import ca.uhn.fhir.model.dstu2.composite.RatioDt;
210import ca.uhn.fhir.model.dstu2.valueset.ReferralMethodEnum;
211import ca.uhn.fhir.model.dstu2.resource.ReferralRequest;
212import ca.uhn.fhir.model.dstu2.valueset.ReferralStatusEnum;
213import ca.uhn.fhir.model.dstu2.resource.RelatedPerson;
214import ca.uhn.fhir.model.dstu2.valueset.RemittanceOutcomeEnum;
215import ca.uhn.fhir.model.dstu2.valueset.ResourceTypeEnum;
216import ca.uhn.fhir.model.dstu2.valueset.ResourceVersionPolicyEnum;
217import ca.uhn.fhir.model.dstu2.valueset.ResponseTypeEnum;
218import ca.uhn.fhir.model.dstu2.valueset.RestfulConformanceModeEnum;
219import ca.uhn.fhir.model.dstu2.valueset.RestfulSecurityServiceEnum;
220import ca.uhn.fhir.model.dstu2.resource.RiskAssessment;
221import ca.uhn.fhir.model.dstu2.valueset.RulesetCodesEnum;
222import ca.uhn.fhir.model.dstu2.composite.SampledDataDt;
223import ca.uhn.fhir.model.dstu2.resource.Schedule;
224import ca.uhn.fhir.model.dstu2.valueset.SearchEntryModeEnum;
225import ca.uhn.fhir.model.dstu2.valueset.SearchModifierCodeEnum;
226import ca.uhn.fhir.model.dstu2.valueset.SearchParamTypeEnum;
227import ca.uhn.fhir.model.dstu2.valueset.ServiceProvisionConditionsEnum;
228import ca.uhn.fhir.model.dstu2.composite.SignatureDt;
229import ca.uhn.fhir.model.dstu2.resource.Slot;
230import ca.uhn.fhir.model.dstu2.valueset.SlotStatusEnum;
231import ca.uhn.fhir.model.dstu2.resource.Specimen;
232import ca.uhn.fhir.model.dstu2.valueset.SpecimenStatusEnum;
233import ca.uhn.fhir.model.dstu2.resource.StructureDefinition;
234import ca.uhn.fhir.model.dstu2.valueset.StructureDefinitionKindEnum;
235import ca.uhn.fhir.model.dstu2.valueset.SubscriptionChannelTypeEnum;
236import ca.uhn.fhir.model.dstu2.valueset.SubscriptionStatusEnum;
237import ca.uhn.fhir.model.dstu2.resource.Substance;
238import ca.uhn.fhir.model.dstu2.valueset.SubstanceCategoryCodesEnum;
239import ca.uhn.fhir.model.dstu2.valueset.SupplyDeliveryStatusEnum;
240import ca.uhn.fhir.model.dstu2.resource.SupplyRequest;
241import ca.uhn.fhir.model.dstu2.valueset.SupplyRequestStatusEnum;
242import ca.uhn.fhir.model.dstu2.valueset.SystemRestfulInteractionEnum;
243import ca.uhn.fhir.model.api.TemporalPrecisionEnum;
244import ca.uhn.fhir.model.dstu2.composite.TimingDt;
245import ca.uhn.fhir.model.dstu2.valueset.TransactionModeEnum;
246import ca.uhn.fhir.model.dstu2.valueset.TypeRestfulInteractionEnum;
247import ca.uhn.fhir.model.dstu2.valueset.UnknownContentCodeEnum;
248import ca.uhn.fhir.model.dstu2.valueset.UseEnum;
249import ca.uhn.fhir.model.dstu2.resource.ValueSet;
250import ca.uhn.fhir.model.dstu2.valueset.VisionBaseEnum;
251import ca.uhn.fhir.model.dstu2.valueset.VisionEyesEnum;
252import ca.uhn.fhir.model.dstu2.resource.VisionPrescription;
253import ca.uhn.fhir.model.dstu2.valueset.XPathUsageTypeEnum;
254import ca.uhn.fhir.model.api.IResource;
255import ca.uhn.fhir.model.dstu2.composite.AgeDt;
256import ca.uhn.fhir.model.dstu2.composite.BoundCodeableConceptDt;
257import ca.uhn.fhir.model.dstu2.composite.DurationDt;
258import ca.uhn.fhir.model.dstu2.composite.MoneyDt;
259import ca.uhn.fhir.model.dstu2.composite.NarrativeDt;
260import ca.uhn.fhir.model.dstu2.composite.ResourceReferenceDt;
261import ca.uhn.fhir.model.dstu2.composite.SimpleQuantityDt;
262import ca.uhn.fhir.model.primitive.Base64BinaryDt;
263import ca.uhn.fhir.model.primitive.BooleanDt;
264import ca.uhn.fhir.model.primitive.BoundCodeDt;
265import ca.uhn.fhir.model.primitive.CodeDt;
266import ca.uhn.fhir.model.primitive.DateDt;
267import ca.uhn.fhir.model.primitive.DateTimeDt;
268import ca.uhn.fhir.model.primitive.DecimalDt;
269import ca.uhn.fhir.model.primitive.IdDt;
270import ca.uhn.fhir.model.primitive.InstantDt;
271import ca.uhn.fhir.model.primitive.IntegerDt;
272import ca.uhn.fhir.model.primitive.OidDt;
273import ca.uhn.fhir.model.primitive.PositiveIntDt;
274import ca.uhn.fhir.model.primitive.StringDt;
275import ca.uhn.fhir.model.primitive.TimeDt;
276import ca.uhn.fhir.model.primitive.UnsignedIntDt;
277import ca.uhn.fhir.model.primitive.UriDt;
278
279
280/**
281 * HAPI/FHIR <b>Immunization</b> Resource
282 * (clinical.medication)
283 *
284 * <p>
285 * <b>Definition:</b>
286 * Describes the event of a patient being administered a vaccination or a record of a vaccination as reported by a patient, a clinician or another party and may include vaccine reaction information and what vaccination protocol was followed.
287 * </p> 
288 *
289 * <p>
290 * <b>Requirements:</b>
291 * 
292 * </p> 
293 *
294 * <p>
295 * <b>Profile Definition:</b>
296 * <a href="http://hl7.org/fhir/profiles/Immunization">http://hl7.org/fhir/profiles/Immunization</a> 
297 * </p>
298 *
299 */
300@ResourceDef(name="Immunization", profile="http://hl7.org/fhir/profiles/Immunization", id="immunization")
301public class Immunization extends ca.uhn.fhir.model.dstu2.resource.BaseResource
302    implements  IResource     {
303
304        /**
305         * Search parameter constant for <b>date</b>
306         * <p>
307         * Description: <b>Vaccination  (non)-Administration Date</b><br>
308         * Type: <b>date</b><br>
309         * Path: <b>Immunization.date</b><br>
310         * </p>
311         */
312        @SearchParamDefinition(name="date", path="Immunization.date", description="Vaccination  (non)-Administration Date", type="date"  )
313        public static final String SP_DATE = "date";
314
315        /**
316         * <b>Fluent Client</b> search parameter constant for <b>date</b>
317         * <p>
318         * Description: <b>Vaccination  (non)-Administration Date</b><br>
319         * Type: <b>date</b><br>
320         * Path: <b>Immunization.date</b><br>
321         * </p>
322         */
323        public static final DateClientParam DATE = new DateClientParam(SP_DATE);
324
325        /**
326         * Search parameter constant for <b>dose-sequence</b>
327         * <p>
328         * Description: <b></b><br>
329         * Type: <b>number</b><br>
330         * Path: <b>Immunization.vaccinationProtocol.doseSequence</b><br>
331         * </p>
332         */
333        @SearchParamDefinition(name="dose-sequence", path="Immunization.vaccinationProtocol.doseSequence", description="", type="number"  )
334        public static final String SP_DOSE_SEQUENCE = "dose-sequence";
335
336        /**
337         * <b>Fluent Client</b> search parameter constant for <b>dose-sequence</b>
338         * <p>
339         * Description: <b></b><br>
340         * Type: <b>number</b><br>
341         * Path: <b>Immunization.vaccinationProtocol.doseSequence</b><br>
342         * </p>
343         */
344        public static final NumberClientParam DOSE_SEQUENCE = new NumberClientParam(SP_DOSE_SEQUENCE);
345
346        /**
347         * Search parameter constant for <b>identifier</b>
348         * <p>
349         * Description: <b></b><br>
350         * Type: <b>token</b><br>
351         * Path: <b>Immunization.identifier</b><br>
352         * </p>
353         */
354        @SearchParamDefinition(name="identifier", path="Immunization.identifier", description="", type="token"  )
355        public static final String SP_IDENTIFIER = "identifier";
356
357        /**
358         * <b>Fluent Client</b> search parameter constant for <b>identifier</b>
359         * <p>
360         * Description: <b></b><br>
361         * Type: <b>token</b><br>
362         * Path: <b>Immunization.identifier</b><br>
363         * </p>
364         */
365        public static final TokenClientParam IDENTIFIER = new TokenClientParam(SP_IDENTIFIER);
366
367        /**
368         * Search parameter constant for <b>location</b>
369         * <p>
370         * Description: <b>The service delivery location or facility in which the vaccine was / was to be administered</b><br>
371         * Type: <b>reference</b><br>
372         * Path: <b>Immunization.location</b><br>
373         * </p>
374         */
375        @SearchParamDefinition(name="location", path="Immunization.location", description="The service delivery location or facility in which the vaccine was / was to be administered", type="reference"  )
376        public static final String SP_LOCATION = "location";
377
378        /**
379         * <b>Fluent Client</b> search parameter constant for <b>location</b>
380         * <p>
381         * Description: <b>The service delivery location or facility in which the vaccine was / was to be administered</b><br>
382         * Type: <b>reference</b><br>
383         * Path: <b>Immunization.location</b><br>
384         * </p>
385         */
386        public static final ReferenceClientParam LOCATION = new ReferenceClientParam(SP_LOCATION);
387
388        /**
389         * Search parameter constant for <b>lot-number</b>
390         * <p>
391         * Description: <b>Vaccine Lot Number</b><br>
392         * Type: <b>string</b><br>
393         * Path: <b>Immunization.lotNumber</b><br>
394         * </p>
395         */
396        @SearchParamDefinition(name="lot-number", path="Immunization.lotNumber", description="Vaccine Lot Number", type="string"  )
397        public static final String SP_LOT_NUMBER = "lot-number";
398
399        /**
400         * <b>Fluent Client</b> search parameter constant for <b>lot-number</b>
401         * <p>
402         * Description: <b>Vaccine Lot Number</b><br>
403         * Type: <b>string</b><br>
404         * Path: <b>Immunization.lotNumber</b><br>
405         * </p>
406         */
407        public static final StringClientParam LOT_NUMBER = new StringClientParam(SP_LOT_NUMBER);
408
409        /**
410         * Search parameter constant for <b>manufacturer</b>
411         * <p>
412         * Description: <b>Vaccine Manufacturer</b><br>
413         * Type: <b>reference</b><br>
414         * Path: <b>Immunization.manufacturer</b><br>
415         * </p>
416         */
417        @SearchParamDefinition(name="manufacturer", path="Immunization.manufacturer", description="Vaccine Manufacturer", type="reference"  )
418        public static final String SP_MANUFACTURER = "manufacturer";
419
420        /**
421         * <b>Fluent Client</b> search parameter constant for <b>manufacturer</b>
422         * <p>
423         * Description: <b>Vaccine Manufacturer</b><br>
424         * Type: <b>reference</b><br>
425         * Path: <b>Immunization.manufacturer</b><br>
426         * </p>
427         */
428        public static final ReferenceClientParam MANUFACTURER = new ReferenceClientParam(SP_MANUFACTURER);
429
430        /**
431         * Search parameter constant for <b>performer</b>
432         * <p>
433         * Description: <b>The practitioner who administered the vaccination</b><br>
434         * Type: <b>reference</b><br>
435         * Path: <b>Immunization.performer</b><br>
436         * </p>
437         */
438        @SearchParamDefinition(name="performer", path="Immunization.performer", description="The practitioner who administered the vaccination", type="reference" , providesMembershipIn={
439 @Compartment(name="Encounter")         }
440 )
441        public static final String SP_PERFORMER = "performer";
442
443        /**
444         * <b>Fluent Client</b> search parameter constant for <b>performer</b>
445         * <p>
446         * Description: <b>The practitioner who administered the vaccination</b><br>
447         * Type: <b>reference</b><br>
448         * Path: <b>Immunization.performer</b><br>
449         * </p>
450         */
451        public static final ReferenceClientParam PERFORMER = new ReferenceClientParam(SP_PERFORMER);
452
453        /**
454         * Search parameter constant for <b>reaction</b>
455         * <p>
456         * Description: <b></b><br>
457         * Type: <b>reference</b><br>
458         * Path: <b>Immunization.reaction.detail</b><br>
459         * </p>
460         */
461        @SearchParamDefinition(name="reaction", path="Immunization.reaction.detail", description="", type="reference"  )
462        public static final String SP_REACTION = "reaction";
463
464        /**
465         * <b>Fluent Client</b> search parameter constant for <b>reaction</b>
466         * <p>
467         * Description: <b></b><br>
468         * Type: <b>reference</b><br>
469         * Path: <b>Immunization.reaction.detail</b><br>
470         * </p>
471         */
472        public static final ReferenceClientParam REACTION = new ReferenceClientParam(SP_REACTION);
473
474        /**
475         * Search parameter constant for <b>reaction-date</b>
476         * <p>
477         * Description: <b></b><br>
478         * Type: <b>date</b><br>
479         * Path: <b>Immunization.reaction.date</b><br>
480         * </p>
481         */
482        @SearchParamDefinition(name="reaction-date", path="Immunization.reaction.date", description="", type="date"  )
483        public static final String SP_REACTION_DATE = "reaction-date";
484
485        /**
486         * <b>Fluent Client</b> search parameter constant for <b>reaction-date</b>
487         * <p>
488         * Description: <b></b><br>
489         * Type: <b>date</b><br>
490         * Path: <b>Immunization.reaction.date</b><br>
491         * </p>
492         */
493        public static final DateClientParam REACTION_DATE = new DateClientParam(SP_REACTION_DATE);
494
495        /**
496         * Search parameter constant for <b>reason</b>
497         * <p>
498         * Description: <b></b><br>
499         * Type: <b>token</b><br>
500         * Path: <b>Immunization.explanation.reason</b><br>
501         * </p>
502         */
503        @SearchParamDefinition(name="reason", path="Immunization.explanation.reason", description="", type="token"  )
504        public static final String SP_REASON = "reason";
505
506        /**
507         * <b>Fluent Client</b> search parameter constant for <b>reason</b>
508         * <p>
509         * Description: <b></b><br>
510         * Type: <b>token</b><br>
511         * Path: <b>Immunization.explanation.reason</b><br>
512         * </p>
513         */
514        public static final TokenClientParam REASON = new TokenClientParam(SP_REASON);
515
516        /**
517         * Search parameter constant for <b>reason-not-given</b>
518         * <p>
519         * Description: <b>Explanation of reason vaccination was not administered</b><br>
520         * Type: <b>token</b><br>
521         * Path: <b>Immunization.explanation.reasonNotGiven</b><br>
522         * </p>
523         */
524        @SearchParamDefinition(name="reason-not-given", path="Immunization.explanation.reasonNotGiven", description="Explanation of reason vaccination was not administered", type="token"  )
525        public static final String SP_REASON_NOT_GIVEN = "reason-not-given";
526
527        /**
528         * <b>Fluent Client</b> search parameter constant for <b>reason-not-given</b>
529         * <p>
530         * Description: <b>Explanation of reason vaccination was not administered</b><br>
531         * Type: <b>token</b><br>
532         * Path: <b>Immunization.explanation.reasonNotGiven</b><br>
533         * </p>
534         */
535        public static final TokenClientParam REASON_NOT_GIVEN = new TokenClientParam(SP_REASON_NOT_GIVEN);
536
537        /**
538         * Search parameter constant for <b>notgiven</b>
539         * <p>
540         * Description: <b>Administrations which were not given</b><br>
541         * Type: <b>token</b><br>
542         * Path: <b>Immunization.wasNotGiven</b><br>
543         * </p>
544         */
545        @SearchParamDefinition(name="notgiven", path="Immunization.wasNotGiven", description="Administrations which were not given", type="token"  )
546        public static final String SP_NOTGIVEN = "notgiven";
547
548        /**
549         * <b>Fluent Client</b> search parameter constant for <b>notgiven</b>
550         * <p>
551         * Description: <b>Administrations which were not given</b><br>
552         * Type: <b>token</b><br>
553         * Path: <b>Immunization.wasNotGiven</b><br>
554         * </p>
555         */
556        public static final TokenClientParam NOTGIVEN = new TokenClientParam(SP_NOTGIVEN);
557
558        /**
559         * Search parameter constant for <b>requester</b>
560         * <p>
561         * Description: <b>The practitioner who ordered the vaccination</b><br>
562         * Type: <b>reference</b><br>
563         * Path: <b>Immunization.requester</b><br>
564         * </p>
565         */
566        @SearchParamDefinition(name="requester", path="Immunization.requester", description="The practitioner who ordered the vaccination", type="reference" , providesMembershipIn={
567 @Compartment(name="Encounter")         }
568 )
569        public static final String SP_REQUESTER = "requester";
570
571        /**
572         * <b>Fluent Client</b> search parameter constant for <b>requester</b>
573         * <p>
574         * Description: <b>The practitioner who ordered the vaccination</b><br>
575         * Type: <b>reference</b><br>
576         * Path: <b>Immunization.requester</b><br>
577         * </p>
578         */
579        public static final ReferenceClientParam REQUESTER = new ReferenceClientParam(SP_REQUESTER);
580
581        /**
582         * Search parameter constant for <b>patient</b>
583         * <p>
584         * Description: <b>The patient for the vaccination record</b><br>
585         * Type: <b>reference</b><br>
586         * Path: <b>Immunization.patient</b><br>
587         * </p>
588         */
589        @SearchParamDefinition(name="patient", path="Immunization.patient", description="The patient for the vaccination record", type="reference" , providesMembershipIn={
590 @Compartment(name="Patient")   }
591 )
592        public static final String SP_PATIENT = "patient";
593
594        /**
595         * <b>Fluent Client</b> search parameter constant for <b>patient</b>
596         * <p>
597         * Description: <b>The patient for the vaccination record</b><br>
598         * Type: <b>reference</b><br>
599         * Path: <b>Immunization.patient</b><br>
600         * </p>
601         */
602        public static final ReferenceClientParam PATIENT = new ReferenceClientParam(SP_PATIENT);
603
604        /**
605         * Search parameter constant for <b>vaccine-code</b>
606         * <p>
607         * Description: <b>Vaccine Product Administered</b><br>
608         * Type: <b>token</b><br>
609         * Path: <b>Immunization.vaccineCode</b><br>
610         * </p>
611         */
612        @SearchParamDefinition(name="vaccine-code", path="Immunization.vaccineCode", description="Vaccine Product Administered", type="token"  )
613        public static final String SP_VACCINE_CODE = "vaccine-code";
614
615        /**
616         * <b>Fluent Client</b> search parameter constant for <b>vaccine-code</b>
617         * <p>
618         * Description: <b>Vaccine Product Administered</b><br>
619         * Type: <b>token</b><br>
620         * Path: <b>Immunization.vaccineCode</b><br>
621         * </p>
622         */
623        public static final TokenClientParam VACCINE_CODE = new TokenClientParam(SP_VACCINE_CODE);
624
625        /**
626         * Search parameter constant for <b>status</b>
627         * <p>
628         * Description: <b>Immunization event status</b><br>
629         * Type: <b>token</b><br>
630         * Path: <b>Immunization.status</b><br>
631         * </p>
632         */
633        @SearchParamDefinition(name="status", path="Immunization.status", description="Immunization event status", type="token"  )
634        public static final String SP_STATUS = "status";
635
636        /**
637         * <b>Fluent Client</b> search parameter constant for <b>status</b>
638         * <p>
639         * Description: <b>Immunization event status</b><br>
640         * Type: <b>token</b><br>
641         * Path: <b>Immunization.status</b><br>
642         * </p>
643         */
644        public static final TokenClientParam STATUS = new TokenClientParam(SP_STATUS);
645
646
647        /**
648         * Constant for fluent queries to be used to add include statements. Specifies
649         * the path value of "<b>Immunization:location</b>".
650         */
651        public static final Include INCLUDE_LOCATION = new Include("Immunization:location");
652
653        /**
654         * Constant for fluent queries to be used to add include statements. Specifies
655         * the path value of "<b>Immunization:manufacturer</b>".
656         */
657        public static final Include INCLUDE_MANUFACTURER = new Include("Immunization:manufacturer");
658
659        /**
660         * Constant for fluent queries to be used to add include statements. Specifies
661         * the path value of "<b>Immunization:patient</b>".
662         */
663        public static final Include INCLUDE_PATIENT = new Include("Immunization:patient");
664
665        /**
666         * Constant for fluent queries to be used to add include statements. Specifies
667         * the path value of "<b>Immunization:performer</b>".
668         */
669        public static final Include INCLUDE_PERFORMER = new Include("Immunization:performer");
670
671        /**
672         * Constant for fluent queries to be used to add include statements. Specifies
673         * the path value of "<b>Immunization:reaction</b>".
674         */
675        public static final Include INCLUDE_REACTION = new Include("Immunization:reaction");
676
677        /**
678         * Constant for fluent queries to be used to add include statements. Specifies
679         * the path value of "<b>Immunization:requester</b>".
680         */
681        public static final Include INCLUDE_REQUESTER = new Include("Immunization:requester");
682
683
684        @Child(name="identifier", type=IdentifierDt.class, order=0, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)      
685        @Description(
686                shortDefinition="id",
687                formalDefinition="A unique identifier assigned to this immunization record."
688        )
689        private java.util.List<IdentifierDt> myIdentifier;
690        
691        @Child(name="status", type=CodeDt.class, order=1, min=1, max=1, summary=true, modifier=true)    
692        @Description(
693                shortDefinition="status",
694                formalDefinition="Indicates the current status of the vaccination event"
695        )
696        @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/medication-admin-status")
697        private CodeDt myStatus;
698        
699        @Child(name="date", type=DateTimeDt.class, order=2, min=0, max=1, summary=false, modifier=false)        
700        @Description(
701                shortDefinition="when.init",
702                formalDefinition="Date vaccine administered or was to be administered"
703        )
704        private DateTimeDt myDate;
705        
706        @Child(name="vaccineCode", type=CodeableConceptDt.class, order=3, min=1, max=1, summary=false, modifier=false)  
707        @Description(
708                shortDefinition="what",
709                formalDefinition="Vaccine that was administered or was to be administered"
710        )
711        private CodeableConceptDt myVaccineCode;
712        
713        @Child(name="patient", order=4, min=1, max=1, summary=false, modifier=false, type={
714                ca.uhn.fhir.model.dstu2.resource.Patient.class  })
715        @Description(
716                shortDefinition="who.focus",
717                formalDefinition="The patient who either received or did not receive the immunization."
718        )
719        private ResourceReferenceDt myPatient;
720        
721        @Child(name="wasNotGiven", type=BooleanDt.class, order=5, min=1, max=1, summary=false, modifier=true)   
722        @Description(
723                shortDefinition="status",
724                formalDefinition="Indicates if the vaccination was or was not given"
725        )
726        private BooleanDt myWasNotGiven;
727        
728        @Child(name="reported", type=BooleanDt.class, order=6, min=1, max=1, summary=false, modifier=false)     
729        @Description(
730                shortDefinition="who.source",
731                formalDefinition="True if this administration was reported rather than directly administered."
732        )
733        private BooleanDt myReported;
734        
735        @Child(name="performer", order=7, min=0, max=1, summary=false, modifier=false, type={
736                ca.uhn.fhir.model.dstu2.resource.Practitioner.class     })
737        @Description(
738                shortDefinition="who.actor",
739                formalDefinition="Clinician who administered the vaccine"
740        )
741        private ResourceReferenceDt myPerformer;
742        
743        @Child(name="requester", order=8, min=0, max=1, summary=false, modifier=false, type={
744                ca.uhn.fhir.model.dstu2.resource.Practitioner.class     })
745        @Description(
746                shortDefinition="who.cause",
747                formalDefinition="Clinician who ordered the vaccination"
748        )
749        private ResourceReferenceDt myRequester;
750        
751        @Child(name="encounter", order=9, min=0, max=1, summary=false, modifier=false, type={
752                ca.uhn.fhir.model.dstu2.resource.Encounter.class        })
753        @Description(
754                shortDefinition="context",
755                formalDefinition="The visit or admission or other contact between patient and health care provider the immunization was performed as part of."
756        )
757        private ResourceReferenceDt myEncounter;
758        
759        @Child(name="manufacturer", order=10, min=0, max=1, summary=false, modifier=false, type={
760                ca.uhn.fhir.model.dstu2.resource.Organization.class     })
761        @Description(
762                shortDefinition="",
763                formalDefinition="Name of vaccine manufacturer"
764        )
765        private ResourceReferenceDt myManufacturer;
766        
767        @Child(name="location", order=11, min=0, max=1, summary=false, modifier=false, type={
768                ca.uhn.fhir.model.dstu2.resource.Location.class })
769        @Description(
770                shortDefinition="where",
771                formalDefinition="The service delivery location where the vaccine administration occurred."
772        )
773        private ResourceReferenceDt myLocation;
774        
775        @Child(name="lotNumber", type=StringDt.class, order=12, min=0, max=1, summary=false, modifier=false)    
776        @Description(
777                shortDefinition="",
778                formalDefinition="Lot number of the  vaccine product"
779        )
780        private StringDt myLotNumber;
781        
782        @Child(name="expirationDate", type=DateDt.class, order=13, min=0, max=1, summary=false, modifier=false) 
783        @Description(
784                shortDefinition="",
785                formalDefinition="Date vaccine batch expires"
786        )
787        private DateDt myExpirationDate;
788        
789        @Child(name="site", type=CodeableConceptDt.class, order=14, min=0, max=1, summary=false, modifier=false)        
790        @Description(
791                shortDefinition="",
792                formalDefinition="Body site where vaccine was administered"
793        )
794        private CodeableConceptDt mySite;
795        
796        @Child(name="route", type=CodeableConceptDt.class, order=15, min=0, max=1, summary=false, modifier=false)       
797        @Description(
798                shortDefinition="",
799                formalDefinition="The path by which the vaccine product is taken into the body."
800        )
801        private CodeableConceptDt myRoute;
802        
803        @Child(name="doseQuantity", type=SimpleQuantityDt.class, order=16, min=0, max=1, summary=false, modifier=false) 
804        @Description(
805                shortDefinition="",
806                formalDefinition="The quantity of vaccine product that was administered"
807        )
808        private SimpleQuantityDt myDoseQuantity;
809        
810        @Child(name="note", type=AnnotationDt.class, order=17, min=0, max=Child.MAX_UNLIMITED, summary=true, modifier=false)    
811        @Description(
812                shortDefinition="",
813                formalDefinition="Extra information about the immunization that is not conveyed by the other attributes."
814        )
815        private java.util.List<AnnotationDt> myNote;
816        
817        @Child(name="explanation", order=18, min=0, max=1, summary=false, modifier=false)       
818        @Description(
819                shortDefinition="",
820                formalDefinition="Reasons why a vaccine was or was not administered"
821        )
822        private Explanation myExplanation;
823        
824        @Child(name="reaction", order=19, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)        
825        @Description(
826                shortDefinition="",
827                formalDefinition="Categorical data indicating that an adverse event is associated in time to an immunization"
828        )
829        private java.util.List<Reaction> myReaction;
830        
831        @Child(name="vaccinationProtocol", order=20, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)     
832        @Description(
833                shortDefinition="",
834                formalDefinition="Contains information about the protocol(s) under which the vaccine was administered"
835        )
836        private java.util.List<VaccinationProtocol> myVaccinationProtocol;
837        
838
839        @Override
840        public boolean isEmpty() {
841                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myIdentifier,  myStatus,  myDate,  myVaccineCode,  myPatient,  myWasNotGiven,  myReported,  myPerformer,  myRequester,  myEncounter,  myManufacturer,  myLocation,  myLotNumber,  myExpirationDate,  mySite,  myRoute,  myDoseQuantity,  myNote,  myExplanation,  myReaction,  myVaccinationProtocol);
842        }
843        
844        @Override
845        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
846                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myIdentifier, myStatus, myDate, myVaccineCode, myPatient, myWasNotGiven, myReported, myPerformer, myRequester, myEncounter, myManufacturer, myLocation, myLotNumber, myExpirationDate, mySite, myRoute, myDoseQuantity, myNote, myExplanation, myReaction, myVaccinationProtocol);
847        }
848
849        /**
850         * Gets the value(s) for <b>identifier</b> (id).
851         * creating it if it does
852         * not exist. Will not return <code>null</code>.
853         *
854     * <p>
855     * <b>Definition:</b>
856     * A unique identifier assigned to this immunization record.
857     * </p> 
858         */
859        public java.util.List<IdentifierDt> getIdentifier() {  
860                if (myIdentifier == null) {
861                        myIdentifier = new java.util.ArrayList<IdentifierDt>();
862                }
863                return myIdentifier;
864        }
865
866        /**
867         * Sets the value(s) for <b>identifier</b> (id)
868         *
869     * <p>
870     * <b>Definition:</b>
871     * A unique identifier assigned to this immunization record.
872     * </p> 
873         */
874        public Immunization setIdentifier(java.util.List<IdentifierDt> theValue) {
875                myIdentifier = theValue;
876                return this;
877        }
878        
879        
880
881        /**
882         * Adds and returns a new value for <b>identifier</b> (id)
883         *
884     * <p>
885     * <b>Definition:</b>
886     * A unique identifier assigned to this immunization record.
887     * </p> 
888         */
889        public IdentifierDt addIdentifier() {
890                IdentifierDt newType = new IdentifierDt();
891                getIdentifier().add(newType);
892                return newType; 
893        }
894
895        /**
896         * Adds a given new value for <b>identifier</b> (id)
897         *
898         * <p>
899         * <b>Definition:</b>
900         * A unique identifier assigned to this immunization record.
901         * </p>
902         * @param theValue The identifier to add (must not be <code>null</code>)
903         */
904        public Immunization addIdentifier(IdentifierDt theValue) {
905                if (theValue == null) {
906                        throw new NullPointerException("theValue must not be null");
907                }
908                getIdentifier().add(theValue);
909                return this;
910        }
911
912        /**
913         * Gets the first repetition for <b>identifier</b> (id),
914         * creating it if it does not already exist.
915         *
916     * <p>
917     * <b>Definition:</b>
918     * A unique identifier assigned to this immunization record.
919     * </p> 
920         */
921        public IdentifierDt getIdentifierFirstRep() {
922                if (getIdentifier().isEmpty()) {
923                        return addIdentifier();
924                }
925                return getIdentifier().get(0); 
926        }
927  
928        /**
929         * Gets the value(s) for <b>status</b> (status).
930         * creating it if it does
931         * not exist. Will not return <code>null</code>.
932         *
933     * <p>
934     * <b>Definition:</b>
935     * Indicates the current status of the vaccination event
936     * </p> 
937         */
938        public CodeDt getStatusElement() {  
939                if (myStatus == null) {
940                        myStatus = new CodeDt();
941                }
942                return myStatus;
943        }
944
945        
946        /**
947         * Gets the value(s) for <b>status</b> (status).
948         * creating it if it does
949         * not exist. This method may return <code>null</code>.
950         *
951     * <p>
952     * <b>Definition:</b>
953     * Indicates the current status of the vaccination event
954     * </p> 
955         */
956        public String getStatus() {  
957                return getStatusElement().getValue();
958        }
959
960        /**
961         * Sets the value(s) for <b>status</b> (status)
962         *
963     * <p>
964     * <b>Definition:</b>
965     * Indicates the current status of the vaccination event
966     * </p> 
967         */
968        public Immunization setStatus(CodeDt theValue) {
969                myStatus = theValue;
970                return this;
971        }
972        
973        
974
975        /**
976         * Sets the value for <b>status</b> (status)
977         *
978     * <p>
979     * <b>Definition:</b>
980     * Indicates the current status of the vaccination event
981     * </p> 
982         */
983        public Immunization setStatus( String theCode) {
984                myStatus = new CodeDt(theCode); 
985                return this; 
986        }
987
988 
989        /**
990         * Gets the value(s) for <b>date</b> (when.init).
991         * creating it if it does
992         * not exist. Will not return <code>null</code>.
993         *
994     * <p>
995     * <b>Definition:</b>
996     * Date vaccine administered or was to be administered
997     * </p> 
998         */
999        public DateTimeDt getDateElement() {  
1000                if (myDate == null) {
1001                        myDate = new DateTimeDt();
1002                }
1003                return myDate;
1004        }
1005
1006        
1007        /**
1008         * Gets the value(s) for <b>date</b> (when.init).
1009         * creating it if it does
1010         * not exist. This method may return <code>null</code>.
1011         *
1012     * <p>
1013     * <b>Definition:</b>
1014     * Date vaccine administered or was to be administered
1015     * </p> 
1016         */
1017        public Date getDate() {  
1018                return getDateElement().getValue();
1019        }
1020
1021        /**
1022         * Sets the value(s) for <b>date</b> (when.init)
1023         *
1024     * <p>
1025     * <b>Definition:</b>
1026     * Date vaccine administered or was to be administered
1027     * </p> 
1028         */
1029        public Immunization setDate(DateTimeDt theValue) {
1030                myDate = theValue;
1031                return this;
1032        }
1033        
1034        
1035
1036        /**
1037         * Sets the value for <b>date</b> (when.init)
1038         *
1039     * <p>
1040     * <b>Definition:</b>
1041     * Date vaccine administered or was to be administered
1042     * </p> 
1043         */
1044        public Immunization setDateWithSecondsPrecision( Date theDate) {
1045                myDate = new DateTimeDt(theDate); 
1046                return this; 
1047        }
1048
1049        /**
1050         * Sets the value for <b>date</b> (when.init)
1051         *
1052     * <p>
1053     * <b>Definition:</b>
1054     * Date vaccine administered or was to be administered
1055     * </p> 
1056         */
1057        public Immunization setDate( Date theDate,  TemporalPrecisionEnum thePrecision) {
1058                myDate = new DateTimeDt(theDate, thePrecision); 
1059                return this; 
1060        }
1061
1062 
1063        /**
1064         * Gets the value(s) for <b>vaccineCode</b> (what).
1065         * creating it if it does
1066         * not exist. Will not return <code>null</code>.
1067         *
1068     * <p>
1069     * <b>Definition:</b>
1070     * Vaccine that was administered or was to be administered
1071     * </p> 
1072         */
1073        public CodeableConceptDt getVaccineCode() {  
1074                if (myVaccineCode == null) {
1075                        myVaccineCode = new CodeableConceptDt();
1076                }
1077                return myVaccineCode;
1078        }
1079
1080        /**
1081         * Sets the value(s) for <b>vaccineCode</b> (what)
1082         *
1083     * <p>
1084     * <b>Definition:</b>
1085     * Vaccine that was administered or was to be administered
1086     * </p> 
1087         */
1088        public Immunization setVaccineCode(CodeableConceptDt theValue) {
1089                myVaccineCode = theValue;
1090                return this;
1091        }
1092        
1093        
1094
1095  
1096        /**
1097         * Gets the value(s) for <b>patient</b> (who.focus).
1098         * creating it if it does
1099         * not exist. Will not return <code>null</code>.
1100         *
1101     * <p>
1102     * <b>Definition:</b>
1103     * The patient who either received or did not receive the immunization.
1104     * </p> 
1105         */
1106        public ResourceReferenceDt getPatient() {  
1107                if (myPatient == null) {
1108                        myPatient = new ResourceReferenceDt();
1109                }
1110                return myPatient;
1111        }
1112
1113        /**
1114         * Sets the value(s) for <b>patient</b> (who.focus)
1115         *
1116     * <p>
1117     * <b>Definition:</b>
1118     * The patient who either received or did not receive the immunization.
1119     * </p> 
1120         */
1121        public Immunization setPatient(ResourceReferenceDt theValue) {
1122                myPatient = theValue;
1123                return this;
1124        }
1125        
1126        
1127
1128  
1129        /**
1130         * Gets the value(s) for <b>wasNotGiven</b> (status).
1131         * creating it if it does
1132         * not exist. Will not return <code>null</code>.
1133         *
1134     * <p>
1135     * <b>Definition:</b>
1136     * Indicates if the vaccination was or was not given
1137     * </p> 
1138         */
1139        public BooleanDt getWasNotGivenElement() {  
1140                if (myWasNotGiven == null) {
1141                        myWasNotGiven = new BooleanDt();
1142                }
1143                return myWasNotGiven;
1144        }
1145
1146        
1147        /**
1148         * Gets the value(s) for <b>wasNotGiven</b> (status).
1149         * creating it if it does
1150         * not exist. This method may return <code>null</code>.
1151         *
1152     * <p>
1153     * <b>Definition:</b>
1154     * Indicates if the vaccination was or was not given
1155     * </p> 
1156         */
1157        public Boolean getWasNotGiven() {  
1158                return getWasNotGivenElement().getValue();
1159        }
1160
1161        /**
1162         * Sets the value(s) for <b>wasNotGiven</b> (status)
1163         *
1164     * <p>
1165     * <b>Definition:</b>
1166     * Indicates if the vaccination was or was not given
1167     * </p> 
1168         */
1169        public Immunization setWasNotGiven(BooleanDt theValue) {
1170                myWasNotGiven = theValue;
1171                return this;
1172        }
1173        
1174        
1175
1176        /**
1177         * Sets the value for <b>wasNotGiven</b> (status)
1178         *
1179     * <p>
1180     * <b>Definition:</b>
1181     * Indicates if the vaccination was or was not given
1182     * </p> 
1183         */
1184        public Immunization setWasNotGiven( boolean theBoolean) {
1185                myWasNotGiven = new BooleanDt(theBoolean); 
1186                return this; 
1187        }
1188
1189 
1190        /**
1191         * Gets the value(s) for <b>reported</b> (who.source).
1192         * creating it if it does
1193         * not exist. Will not return <code>null</code>.
1194         *
1195     * <p>
1196     * <b>Definition:</b>
1197     * True if this administration was reported rather than directly administered.
1198     * </p> 
1199         */
1200        public BooleanDt getReportedElement() {  
1201                if (myReported == null) {
1202                        myReported = new BooleanDt();
1203                }
1204                return myReported;
1205        }
1206
1207        
1208        /**
1209         * Gets the value(s) for <b>reported</b> (who.source).
1210         * creating it if it does
1211         * not exist. This method may return <code>null</code>.
1212         *
1213     * <p>
1214     * <b>Definition:</b>
1215     * True if this administration was reported rather than directly administered.
1216     * </p> 
1217         */
1218        public Boolean getReported() {  
1219                return getReportedElement().getValue();
1220        }
1221
1222        /**
1223         * Sets the value(s) for <b>reported</b> (who.source)
1224         *
1225     * <p>
1226     * <b>Definition:</b>
1227     * True if this administration was reported rather than directly administered.
1228     * </p> 
1229         */
1230        public Immunization setReported(BooleanDt theValue) {
1231                myReported = theValue;
1232                return this;
1233        }
1234        
1235        
1236
1237        /**
1238         * Sets the value for <b>reported</b> (who.source)
1239         *
1240     * <p>
1241     * <b>Definition:</b>
1242     * True if this administration was reported rather than directly administered.
1243     * </p> 
1244         */
1245        public Immunization setReported( boolean theBoolean) {
1246                myReported = new BooleanDt(theBoolean); 
1247                return this; 
1248        }
1249
1250 
1251        /**
1252         * Gets the value(s) for <b>performer</b> (who.actor).
1253         * creating it if it does
1254         * not exist. Will not return <code>null</code>.
1255         *
1256     * <p>
1257     * <b>Definition:</b>
1258     * Clinician who administered the vaccine
1259     * </p> 
1260         */
1261        public ResourceReferenceDt getPerformer() {  
1262                if (myPerformer == null) {
1263                        myPerformer = new ResourceReferenceDt();
1264                }
1265                return myPerformer;
1266        }
1267
1268        /**
1269         * Sets the value(s) for <b>performer</b> (who.actor)
1270         *
1271     * <p>
1272     * <b>Definition:</b>
1273     * Clinician who administered the vaccine
1274     * </p> 
1275         */
1276        public Immunization setPerformer(ResourceReferenceDt theValue) {
1277                myPerformer = theValue;
1278                return this;
1279        }
1280        
1281        
1282
1283  
1284        /**
1285         * Gets the value(s) for <b>requester</b> (who.cause).
1286         * creating it if it does
1287         * not exist. Will not return <code>null</code>.
1288         *
1289     * <p>
1290     * <b>Definition:</b>
1291     * Clinician who ordered the vaccination
1292     * </p> 
1293         */
1294        public ResourceReferenceDt getRequester() {  
1295                if (myRequester == null) {
1296                        myRequester = new ResourceReferenceDt();
1297                }
1298                return myRequester;
1299        }
1300
1301        /**
1302         * Sets the value(s) for <b>requester</b> (who.cause)
1303         *
1304     * <p>
1305     * <b>Definition:</b>
1306     * Clinician who ordered the vaccination
1307     * </p> 
1308         */
1309        public Immunization setRequester(ResourceReferenceDt theValue) {
1310                myRequester = theValue;
1311                return this;
1312        }
1313        
1314        
1315
1316  
1317        /**
1318         * Gets the value(s) for <b>encounter</b> (context).
1319         * creating it if it does
1320         * not exist. Will not return <code>null</code>.
1321         *
1322     * <p>
1323     * <b>Definition:</b>
1324     * The visit or admission or other contact between patient and health care provider the immunization was performed as part of.
1325     * </p> 
1326         */
1327        public ResourceReferenceDt getEncounter() {  
1328                if (myEncounter == null) {
1329                        myEncounter = new ResourceReferenceDt();
1330                }
1331                return myEncounter;
1332        }
1333
1334        /**
1335         * Sets the value(s) for <b>encounter</b> (context)
1336         *
1337     * <p>
1338     * <b>Definition:</b>
1339     * The visit or admission or other contact between patient and health care provider the immunization was performed as part of.
1340     * </p> 
1341         */
1342        public Immunization setEncounter(ResourceReferenceDt theValue) {
1343                myEncounter = theValue;
1344                return this;
1345        }
1346        
1347        
1348
1349  
1350        /**
1351         * Gets the value(s) for <b>manufacturer</b> ().
1352         * creating it if it does
1353         * not exist. Will not return <code>null</code>.
1354         *
1355     * <p>
1356     * <b>Definition:</b>
1357     * Name of vaccine manufacturer
1358     * </p> 
1359         */
1360        public ResourceReferenceDt getManufacturer() {  
1361                if (myManufacturer == null) {
1362                        myManufacturer = new ResourceReferenceDt();
1363                }
1364                return myManufacturer;
1365        }
1366
1367        /**
1368         * Sets the value(s) for <b>manufacturer</b> ()
1369         *
1370     * <p>
1371     * <b>Definition:</b>
1372     * Name of vaccine manufacturer
1373     * </p> 
1374         */
1375        public Immunization setManufacturer(ResourceReferenceDt theValue) {
1376                myManufacturer = theValue;
1377                return this;
1378        }
1379        
1380        
1381
1382  
1383        /**
1384         * Gets the value(s) for <b>location</b> (where).
1385         * creating it if it does
1386         * not exist. Will not return <code>null</code>.
1387         *
1388     * <p>
1389     * <b>Definition:</b>
1390     * The service delivery location where the vaccine administration occurred.
1391     * </p> 
1392         */
1393        public ResourceReferenceDt getLocation() {  
1394                if (myLocation == null) {
1395                        myLocation = new ResourceReferenceDt();
1396                }
1397                return myLocation;
1398        }
1399
1400        /**
1401         * Sets the value(s) for <b>location</b> (where)
1402         *
1403     * <p>
1404     * <b>Definition:</b>
1405     * The service delivery location where the vaccine administration occurred.
1406     * </p> 
1407         */
1408        public Immunization setLocation(ResourceReferenceDt theValue) {
1409                myLocation = theValue;
1410                return this;
1411        }
1412        
1413        
1414
1415  
1416        /**
1417         * Gets the value(s) for <b>lotNumber</b> ().
1418         * creating it if it does
1419         * not exist. Will not return <code>null</code>.
1420         *
1421     * <p>
1422     * <b>Definition:</b>
1423     * Lot number of the  vaccine product
1424     * </p> 
1425         */
1426        public StringDt getLotNumberElement() {  
1427                if (myLotNumber == null) {
1428                        myLotNumber = new StringDt();
1429                }
1430                return myLotNumber;
1431        }
1432
1433        
1434        /**
1435         * Gets the value(s) for <b>lotNumber</b> ().
1436         * creating it if it does
1437         * not exist. This method may return <code>null</code>.
1438         *
1439     * <p>
1440     * <b>Definition:</b>
1441     * Lot number of the  vaccine product
1442     * </p> 
1443         */
1444        public String getLotNumber() {  
1445                return getLotNumberElement().getValue();
1446        }
1447
1448        /**
1449         * Sets the value(s) for <b>lotNumber</b> ()
1450         *
1451     * <p>
1452     * <b>Definition:</b>
1453     * Lot number of the  vaccine product
1454     * </p> 
1455         */
1456        public Immunization setLotNumber(StringDt theValue) {
1457                myLotNumber = theValue;
1458                return this;
1459        }
1460        
1461        
1462
1463        /**
1464         * Sets the value for <b>lotNumber</b> ()
1465         *
1466     * <p>
1467     * <b>Definition:</b>
1468     * Lot number of the  vaccine product
1469     * </p> 
1470         */
1471        public Immunization setLotNumber( String theString) {
1472                myLotNumber = new StringDt(theString); 
1473                return this; 
1474        }
1475
1476 
1477        /**
1478         * Gets the value(s) for <b>expirationDate</b> ().
1479         * creating it if it does
1480         * not exist. Will not return <code>null</code>.
1481         *
1482     * <p>
1483     * <b>Definition:</b>
1484     * Date vaccine batch expires
1485     * </p> 
1486         */
1487        public DateDt getExpirationDateElement() {  
1488                if (myExpirationDate == null) {
1489                        myExpirationDate = new DateDt();
1490                }
1491                return myExpirationDate;
1492        }
1493
1494        
1495        /**
1496         * Gets the value(s) for <b>expirationDate</b> ().
1497         * creating it if it does
1498         * not exist. This method may return <code>null</code>.
1499         *
1500     * <p>
1501     * <b>Definition:</b>
1502     * Date vaccine batch expires
1503     * </p> 
1504         */
1505        public Date getExpirationDate() {  
1506                return getExpirationDateElement().getValue();
1507        }
1508
1509        /**
1510         * Sets the value(s) for <b>expirationDate</b> ()
1511         *
1512     * <p>
1513     * <b>Definition:</b>
1514     * Date vaccine batch expires
1515     * </p> 
1516         */
1517        public Immunization setExpirationDate(DateDt theValue) {
1518                myExpirationDate = theValue;
1519                return this;
1520        }
1521        
1522        
1523
1524        /**
1525         * Sets the value for <b>expirationDate</b> ()
1526         *
1527     * <p>
1528     * <b>Definition:</b>
1529     * Date vaccine batch expires
1530     * </p> 
1531         */
1532        public Immunization setExpirationDateWithDayPrecision( Date theDate) {
1533                myExpirationDate = new DateDt(theDate); 
1534                return this; 
1535        }
1536
1537        /**
1538         * Sets the value for <b>expirationDate</b> ()
1539         *
1540     * <p>
1541     * <b>Definition:</b>
1542     * Date vaccine batch expires
1543     * </p> 
1544         */
1545        public Immunization setExpirationDate( Date theDate,  TemporalPrecisionEnum thePrecision) {
1546                myExpirationDate = new DateDt(theDate, thePrecision); 
1547                return this; 
1548        }
1549
1550 
1551        /**
1552         * Gets the value(s) for <b>site</b> ().
1553         * creating it if it does
1554         * not exist. Will not return <code>null</code>.
1555         *
1556     * <p>
1557     * <b>Definition:</b>
1558     * Body site where vaccine was administered
1559     * </p> 
1560         */
1561        public CodeableConceptDt getSite() {  
1562                if (mySite == null) {
1563                        mySite = new CodeableConceptDt();
1564                }
1565                return mySite;
1566        }
1567
1568        /**
1569         * Sets the value(s) for <b>site</b> ()
1570         *
1571     * <p>
1572     * <b>Definition:</b>
1573     * Body site where vaccine was administered
1574     * </p> 
1575         */
1576        public Immunization setSite(CodeableConceptDt theValue) {
1577                mySite = theValue;
1578                return this;
1579        }
1580        
1581        
1582
1583  
1584        /**
1585         * Gets the value(s) for <b>route</b> ().
1586         * creating it if it does
1587         * not exist. Will not return <code>null</code>.
1588         *
1589     * <p>
1590     * <b>Definition:</b>
1591     * The path by which the vaccine product is taken into the body.
1592     * </p> 
1593         */
1594        public CodeableConceptDt getRoute() {  
1595                if (myRoute == null) {
1596                        myRoute = new CodeableConceptDt();
1597                }
1598                return myRoute;
1599        }
1600
1601        /**
1602         * Sets the value(s) for <b>route</b> ()
1603         *
1604     * <p>
1605     * <b>Definition:</b>
1606     * The path by which the vaccine product is taken into the body.
1607     * </p> 
1608         */
1609        public Immunization setRoute(CodeableConceptDt theValue) {
1610                myRoute = theValue;
1611                return this;
1612        }
1613        
1614        
1615
1616  
1617        /**
1618         * Gets the value(s) for <b>doseQuantity</b> ().
1619         * creating it if it does
1620         * not exist. Will not return <code>null</code>.
1621         *
1622     * <p>
1623     * <b>Definition:</b>
1624     * The quantity of vaccine product that was administered
1625     * </p> 
1626         */
1627        public SimpleQuantityDt getDoseQuantity() {  
1628                if (myDoseQuantity == null) {
1629                        myDoseQuantity = new SimpleQuantityDt();
1630                }
1631                return myDoseQuantity;
1632        }
1633
1634        /**
1635         * Sets the value(s) for <b>doseQuantity</b> ()
1636         *
1637     * <p>
1638     * <b>Definition:</b>
1639     * The quantity of vaccine product that was administered
1640     * </p> 
1641         */
1642        public Immunization setDoseQuantity(SimpleQuantityDt theValue) {
1643                myDoseQuantity = theValue;
1644                return this;
1645        }
1646        
1647        
1648
1649  
1650        /**
1651         * Gets the value(s) for <b>note</b> ().
1652         * creating it if it does
1653         * not exist. Will not return <code>null</code>.
1654         *
1655     * <p>
1656     * <b>Definition:</b>
1657     * Extra information about the immunization that is not conveyed by the other attributes.
1658     * </p> 
1659         */
1660        public java.util.List<AnnotationDt> getNote() {  
1661                if (myNote == null) {
1662                        myNote = new java.util.ArrayList<AnnotationDt>();
1663                }
1664                return myNote;
1665        }
1666
1667        /**
1668         * Sets the value(s) for <b>note</b> ()
1669         *
1670     * <p>
1671     * <b>Definition:</b>
1672     * Extra information about the immunization that is not conveyed by the other attributes.
1673     * </p> 
1674         */
1675        public Immunization setNote(java.util.List<AnnotationDt> theValue) {
1676                myNote = theValue;
1677                return this;
1678        }
1679        
1680        
1681
1682        /**
1683         * Adds and returns a new value for <b>note</b> ()
1684         *
1685     * <p>
1686     * <b>Definition:</b>
1687     * Extra information about the immunization that is not conveyed by the other attributes.
1688     * </p> 
1689         */
1690        public AnnotationDt addNote() {
1691                AnnotationDt newType = new AnnotationDt();
1692                getNote().add(newType);
1693                return newType; 
1694        }
1695
1696        /**
1697         * Adds a given new value for <b>note</b> ()
1698         *
1699         * <p>
1700         * <b>Definition:</b>
1701         * Extra information about the immunization that is not conveyed by the other attributes.
1702         * </p>
1703         * @param theValue The note to add (must not be <code>null</code>)
1704         */
1705        public Immunization addNote(AnnotationDt theValue) {
1706                if (theValue == null) {
1707                        throw new NullPointerException("theValue must not be null");
1708                }
1709                getNote().add(theValue);
1710                return this;
1711        }
1712
1713        /**
1714         * Gets the first repetition for <b>note</b> (),
1715         * creating it if it does not already exist.
1716         *
1717     * <p>
1718     * <b>Definition:</b>
1719     * Extra information about the immunization that is not conveyed by the other attributes.
1720     * </p> 
1721         */
1722        public AnnotationDt getNoteFirstRep() {
1723                if (getNote().isEmpty()) {
1724                        return addNote();
1725                }
1726                return getNote().get(0); 
1727        }
1728  
1729        /**
1730         * Gets the value(s) for <b>explanation</b> ().
1731         * creating it if it does
1732         * not exist. Will not return <code>null</code>.
1733         *
1734     * <p>
1735     * <b>Definition:</b>
1736     * Reasons why a vaccine was or was not administered
1737     * </p> 
1738         */
1739        public Explanation getExplanation() {  
1740                if (myExplanation == null) {
1741                        myExplanation = new Explanation();
1742                }
1743                return myExplanation;
1744        }
1745
1746        /**
1747         * Sets the value(s) for <b>explanation</b> ()
1748         *
1749     * <p>
1750     * <b>Definition:</b>
1751     * Reasons why a vaccine was or was not administered
1752     * </p> 
1753         */
1754        public Immunization setExplanation(Explanation theValue) {
1755                myExplanation = theValue;
1756                return this;
1757        }
1758        
1759        
1760
1761  
1762        /**
1763         * Gets the value(s) for <b>reaction</b> ().
1764         * creating it if it does
1765         * not exist. Will not return <code>null</code>.
1766         *
1767     * <p>
1768     * <b>Definition:</b>
1769     * Categorical data indicating that an adverse event is associated in time to an immunization
1770     * </p> 
1771         */
1772        public java.util.List<Reaction> getReaction() {  
1773                if (myReaction == null) {
1774                        myReaction = new java.util.ArrayList<Reaction>();
1775                }
1776                return myReaction;
1777        }
1778
1779        /**
1780         * Sets the value(s) for <b>reaction</b> ()
1781         *
1782     * <p>
1783     * <b>Definition:</b>
1784     * Categorical data indicating that an adverse event is associated in time to an immunization
1785     * </p> 
1786         */
1787        public Immunization setReaction(java.util.List<Reaction> theValue) {
1788                myReaction = theValue;
1789                return this;
1790        }
1791        
1792        
1793
1794        /**
1795         * Adds and returns a new value for <b>reaction</b> ()
1796         *
1797     * <p>
1798     * <b>Definition:</b>
1799     * Categorical data indicating that an adverse event is associated in time to an immunization
1800     * </p> 
1801         */
1802        public Reaction addReaction() {
1803                Reaction newType = new Reaction();
1804                getReaction().add(newType);
1805                return newType; 
1806        }
1807
1808        /**
1809         * Adds a given new value for <b>reaction</b> ()
1810         *
1811         * <p>
1812         * <b>Definition:</b>
1813         * Categorical data indicating that an adverse event is associated in time to an immunization
1814         * </p>
1815         * @param theValue The reaction to add (must not be <code>null</code>)
1816         */
1817        public Immunization addReaction(Reaction theValue) {
1818                if (theValue == null) {
1819                        throw new NullPointerException("theValue must not be null");
1820                }
1821                getReaction().add(theValue);
1822                return this;
1823        }
1824
1825        /**
1826         * Gets the first repetition for <b>reaction</b> (),
1827         * creating it if it does not already exist.
1828         *
1829     * <p>
1830     * <b>Definition:</b>
1831     * Categorical data indicating that an adverse event is associated in time to an immunization
1832     * </p> 
1833         */
1834        public Reaction getReactionFirstRep() {
1835                if (getReaction().isEmpty()) {
1836                        return addReaction();
1837                }
1838                return getReaction().get(0); 
1839        }
1840  
1841        /**
1842         * Gets the value(s) for <b>vaccinationProtocol</b> ().
1843         * creating it if it does
1844         * not exist. Will not return <code>null</code>.
1845         *
1846     * <p>
1847     * <b>Definition:</b>
1848     * Contains information about the protocol(s) under which the vaccine was administered
1849     * </p> 
1850         */
1851        public java.util.List<VaccinationProtocol> getVaccinationProtocol() {  
1852                if (myVaccinationProtocol == null) {
1853                        myVaccinationProtocol = new java.util.ArrayList<VaccinationProtocol>();
1854                }
1855                return myVaccinationProtocol;
1856        }
1857
1858        /**
1859         * Sets the value(s) for <b>vaccinationProtocol</b> ()
1860         *
1861     * <p>
1862     * <b>Definition:</b>
1863     * Contains information about the protocol(s) under which the vaccine was administered
1864     * </p> 
1865         */
1866        public Immunization setVaccinationProtocol(java.util.List<VaccinationProtocol> theValue) {
1867                myVaccinationProtocol = theValue;
1868                return this;
1869        }
1870        
1871        
1872
1873        /**
1874         * Adds and returns a new value for <b>vaccinationProtocol</b> ()
1875         *
1876     * <p>
1877     * <b>Definition:</b>
1878     * Contains information about the protocol(s) under which the vaccine was administered
1879     * </p> 
1880         */
1881        public VaccinationProtocol addVaccinationProtocol() {
1882                VaccinationProtocol newType = new VaccinationProtocol();
1883                getVaccinationProtocol().add(newType);
1884                return newType; 
1885        }
1886
1887        /**
1888         * Adds a given new value for <b>vaccinationProtocol</b> ()
1889         *
1890         * <p>
1891         * <b>Definition:</b>
1892         * Contains information about the protocol(s) under which the vaccine was administered
1893         * </p>
1894         * @param theValue The vaccinationProtocol to add (must not be <code>null</code>)
1895         */
1896        public Immunization addVaccinationProtocol(VaccinationProtocol theValue) {
1897                if (theValue == null) {
1898                        throw new NullPointerException("theValue must not be null");
1899                }
1900                getVaccinationProtocol().add(theValue);
1901                return this;
1902        }
1903
1904        /**
1905         * Gets the first repetition for <b>vaccinationProtocol</b> (),
1906         * creating it if it does not already exist.
1907         *
1908     * <p>
1909     * <b>Definition:</b>
1910     * Contains information about the protocol(s) under which the vaccine was administered
1911     * </p> 
1912         */
1913        public VaccinationProtocol getVaccinationProtocolFirstRep() {
1914                if (getVaccinationProtocol().isEmpty()) {
1915                        return addVaccinationProtocol();
1916                }
1917                return getVaccinationProtocol().get(0); 
1918        }
1919  
1920        /**
1921         * Block class for child element: <b>Immunization.explanation</b> ()
1922         *
1923     * <p>
1924     * <b>Definition:</b>
1925     * Reasons why a vaccine was or was not administered
1926     * </p> 
1927         */
1928        @Block()        
1929        public static class Explanation 
1930            extends  BaseIdentifiableElement        implements IResourceBlock {
1931        
1932        @Child(name="reason", type=CodeableConceptDt.class, order=0, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)     
1933        @Description(
1934                shortDefinition="",
1935                formalDefinition="Reasons why a vaccine was administered"
1936        )
1937        private java.util.List<CodeableConceptDt> myReason;
1938        
1939        @Child(name="reasonNotGiven", type=CodeableConceptDt.class, order=1, min=0, max=Child.MAX_UNLIMITED, summary=false, modifier=false)     
1940        @Description(
1941                shortDefinition="",
1942                formalDefinition="Reason why a vaccine was not administered"
1943        )
1944        private java.util.List<CodeableConceptDt> myReasonNotGiven;
1945        
1946
1947        @Override
1948        public boolean isEmpty() {
1949                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myReason,  myReasonNotGiven);
1950        }
1951        
1952        @Override
1953        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
1954                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myReason, myReasonNotGiven);
1955        }
1956
1957        /**
1958         * Gets the value(s) for <b>reason</b> ().
1959         * creating it if it does
1960         * not exist. Will not return <code>null</code>.
1961         *
1962     * <p>
1963     * <b>Definition:</b>
1964     * Reasons why a vaccine was administered
1965     * </p> 
1966         */
1967        public java.util.List<CodeableConceptDt> getReason() {  
1968                if (myReason == null) {
1969                        myReason = new java.util.ArrayList<CodeableConceptDt>();
1970                }
1971                return myReason;
1972        }
1973
1974        /**
1975         * Sets the value(s) for <b>reason</b> ()
1976         *
1977     * <p>
1978     * <b>Definition:</b>
1979     * Reasons why a vaccine was administered
1980     * </p> 
1981         */
1982        public Explanation setReason(java.util.List<CodeableConceptDt> theValue) {
1983                myReason = theValue;
1984                return this;
1985        }
1986        
1987        
1988
1989        /**
1990         * Adds and returns a new value for <b>reason</b> ()
1991         *
1992     * <p>
1993     * <b>Definition:</b>
1994     * Reasons why a vaccine was administered
1995     * </p> 
1996         */
1997        public CodeableConceptDt addReason() {
1998                CodeableConceptDt newType = new CodeableConceptDt();
1999                getReason().add(newType);
2000                return newType; 
2001        }
2002
2003        /**
2004         * Adds a given new value for <b>reason</b> ()
2005         *
2006         * <p>
2007         * <b>Definition:</b>
2008         * Reasons why a vaccine was administered
2009         * </p>
2010         * @param theValue The reason to add (must not be <code>null</code>)
2011         */
2012        public Explanation addReason(CodeableConceptDt theValue) {
2013                if (theValue == null) {
2014                        throw new NullPointerException("theValue must not be null");
2015                }
2016                getReason().add(theValue);
2017                return this;
2018        }
2019
2020        /**
2021         * Gets the first repetition for <b>reason</b> (),
2022         * creating it if it does not already exist.
2023         *
2024     * <p>
2025     * <b>Definition:</b>
2026     * Reasons why a vaccine was administered
2027     * </p> 
2028         */
2029        public CodeableConceptDt getReasonFirstRep() {
2030                if (getReason().isEmpty()) {
2031                        return addReason();
2032                }
2033                return getReason().get(0); 
2034        }
2035  
2036        /**
2037         * Gets the value(s) for <b>reasonNotGiven</b> ().
2038         * creating it if it does
2039         * not exist. Will not return <code>null</code>.
2040         *
2041     * <p>
2042     * <b>Definition:</b>
2043     * Reason why a vaccine was not administered
2044     * </p> 
2045         */
2046        public java.util.List<CodeableConceptDt> getReasonNotGiven() {  
2047                if (myReasonNotGiven == null) {
2048                        myReasonNotGiven = new java.util.ArrayList<CodeableConceptDt>();
2049                }
2050                return myReasonNotGiven;
2051        }
2052
2053        /**
2054         * Sets the value(s) for <b>reasonNotGiven</b> ()
2055         *
2056     * <p>
2057     * <b>Definition:</b>
2058     * Reason why a vaccine was not administered
2059     * </p> 
2060         */
2061        public Explanation setReasonNotGiven(java.util.List<CodeableConceptDt> theValue) {
2062                myReasonNotGiven = theValue;
2063                return this;
2064        }
2065        
2066        
2067
2068        /**
2069         * Adds and returns a new value for <b>reasonNotGiven</b> ()
2070         *
2071     * <p>
2072     * <b>Definition:</b>
2073     * Reason why a vaccine was not administered
2074     * </p> 
2075         */
2076        public CodeableConceptDt addReasonNotGiven() {
2077                CodeableConceptDt newType = new CodeableConceptDt();
2078                getReasonNotGiven().add(newType);
2079                return newType; 
2080        }
2081
2082        /**
2083         * Adds a given new value for <b>reasonNotGiven</b> ()
2084         *
2085         * <p>
2086         * <b>Definition:</b>
2087         * Reason why a vaccine was not administered
2088         * </p>
2089         * @param theValue The reasonNotGiven to add (must not be <code>null</code>)
2090         */
2091        public Explanation addReasonNotGiven(CodeableConceptDt theValue) {
2092                if (theValue == null) {
2093                        throw new NullPointerException("theValue must not be null");
2094                }
2095                getReasonNotGiven().add(theValue);
2096                return this;
2097        }
2098
2099        /**
2100         * Gets the first repetition for <b>reasonNotGiven</b> (),
2101         * creating it if it does not already exist.
2102         *
2103     * <p>
2104     * <b>Definition:</b>
2105     * Reason why a vaccine was not administered
2106     * </p> 
2107         */
2108        public CodeableConceptDt getReasonNotGivenFirstRep() {
2109                if (getReasonNotGiven().isEmpty()) {
2110                        return addReasonNotGiven();
2111                }
2112                return getReasonNotGiven().get(0); 
2113        }
2114  
2115
2116
2117        }
2118
2119
2120        /**
2121         * Block class for child element: <b>Immunization.reaction</b> ()
2122         *
2123     * <p>
2124     * <b>Definition:</b>
2125     * Categorical data indicating that an adverse event is associated in time to an immunization
2126     * </p> 
2127         */
2128        @Block()        
2129        public static class Reaction 
2130            extends  BaseIdentifiableElement        implements IResourceBlock {
2131        
2132        @Child(name="date", type=DateTimeDt.class, order=0, min=0, max=1, summary=false, modifier=false)        
2133        @Description(
2134                shortDefinition="",
2135                formalDefinition="Date of reaction to the immunization"
2136        )
2137        private DateTimeDt myDate;
2138        
2139        @Child(name="detail", order=1, min=0, max=1, summary=false, modifier=false, type={
2140                ca.uhn.fhir.model.dstu2.resource.Observation.class      })
2141        @Description(
2142                shortDefinition="",
2143                formalDefinition="Details of the reaction"
2144        )
2145        private ResourceReferenceDt myDetail;
2146        
2147        @Child(name="reported", type=BooleanDt.class, order=2, min=0, max=1, summary=false, modifier=false)     
2148        @Description(
2149                shortDefinition="",
2150                formalDefinition="Self-reported indicator"
2151        )
2152        private BooleanDt myReported;
2153        
2154
2155        @Override
2156        public boolean isEmpty() {
2157                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myDate,  myDetail,  myReported);
2158        }
2159        
2160        @Override
2161        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
2162                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myDate, myDetail, myReported);
2163        }
2164
2165        /**
2166         * Gets the value(s) for <b>date</b> ().
2167         * creating it if it does
2168         * not exist. Will not return <code>null</code>.
2169         *
2170     * <p>
2171     * <b>Definition:</b>
2172     * Date of reaction to the immunization
2173     * </p> 
2174         */
2175        public DateTimeDt getDateElement() {  
2176                if (myDate == null) {
2177                        myDate = new DateTimeDt();
2178                }
2179                return myDate;
2180        }
2181
2182        
2183        /**
2184         * Gets the value(s) for <b>date</b> ().
2185         * creating it if it does
2186         * not exist. This method may return <code>null</code>.
2187         *
2188     * <p>
2189     * <b>Definition:</b>
2190     * Date of reaction to the immunization
2191     * </p> 
2192         */
2193        public Date getDate() {  
2194                return getDateElement().getValue();
2195        }
2196
2197        /**
2198         * Sets the value(s) for <b>date</b> ()
2199         *
2200     * <p>
2201     * <b>Definition:</b>
2202     * Date of reaction to the immunization
2203     * </p> 
2204         */
2205        public Reaction setDate(DateTimeDt theValue) {
2206                myDate = theValue;
2207                return this;
2208        }
2209        
2210        
2211
2212        /**
2213         * Sets the value for <b>date</b> ()
2214         *
2215     * <p>
2216     * <b>Definition:</b>
2217     * Date of reaction to the immunization
2218     * </p> 
2219         */
2220        public Reaction setDateWithSecondsPrecision( Date theDate) {
2221                myDate = new DateTimeDt(theDate); 
2222                return this; 
2223        }
2224
2225        /**
2226         * Sets the value for <b>date</b> ()
2227         *
2228     * <p>
2229     * <b>Definition:</b>
2230     * Date of reaction to the immunization
2231     * </p> 
2232         */
2233        public Reaction setDate( Date theDate,  TemporalPrecisionEnum thePrecision) {
2234                myDate = new DateTimeDt(theDate, thePrecision); 
2235                return this; 
2236        }
2237
2238 
2239        /**
2240         * Gets the value(s) for <b>detail</b> ().
2241         * creating it if it does
2242         * not exist. Will not return <code>null</code>.
2243         *
2244     * <p>
2245     * <b>Definition:</b>
2246     * Details of the reaction
2247     * </p> 
2248         */
2249        public ResourceReferenceDt getDetail() {  
2250                if (myDetail == null) {
2251                        myDetail = new ResourceReferenceDt();
2252                }
2253                return myDetail;
2254        }
2255
2256        /**
2257         * Sets the value(s) for <b>detail</b> ()
2258         *
2259     * <p>
2260     * <b>Definition:</b>
2261     * Details of the reaction
2262     * </p> 
2263         */
2264        public Reaction setDetail(ResourceReferenceDt theValue) {
2265                myDetail = theValue;
2266                return this;
2267        }
2268        
2269        
2270
2271  
2272        /**
2273         * Gets the value(s) for <b>reported</b> ().
2274         * creating it if it does
2275         * not exist. Will not return <code>null</code>.
2276         *
2277     * <p>
2278     * <b>Definition:</b>
2279     * Self-reported indicator
2280     * </p> 
2281         */
2282        public BooleanDt getReportedElement() {  
2283                if (myReported == null) {
2284                        myReported = new BooleanDt();
2285                }
2286                return myReported;
2287        }
2288
2289        
2290        /**
2291         * Gets the value(s) for <b>reported</b> ().
2292         * creating it if it does
2293         * not exist. This method may return <code>null</code>.
2294         *
2295     * <p>
2296     * <b>Definition:</b>
2297     * Self-reported indicator
2298     * </p> 
2299         */
2300        public Boolean getReported() {  
2301                return getReportedElement().getValue();
2302        }
2303
2304        /**
2305         * Sets the value(s) for <b>reported</b> ()
2306         *
2307     * <p>
2308     * <b>Definition:</b>
2309     * Self-reported indicator
2310     * </p> 
2311         */
2312        public Reaction setReported(BooleanDt theValue) {
2313                myReported = theValue;
2314                return this;
2315        }
2316        
2317        
2318
2319        /**
2320         * Sets the value for <b>reported</b> ()
2321         *
2322     * <p>
2323     * <b>Definition:</b>
2324     * Self-reported indicator
2325     * </p> 
2326         */
2327        public Reaction setReported( boolean theBoolean) {
2328                myReported = new BooleanDt(theBoolean); 
2329                return this; 
2330        }
2331
2332 
2333
2334
2335        }
2336
2337
2338        /**
2339         * Block class for child element: <b>Immunization.vaccinationProtocol</b> ()
2340         *
2341     * <p>
2342     * <b>Definition:</b>
2343     * Contains information about the protocol(s) under which the vaccine was administered
2344     * </p> 
2345         */
2346        @Block()        
2347        public static class VaccinationProtocol 
2348            extends  BaseIdentifiableElement        implements IResourceBlock {
2349        
2350        @Child(name="doseSequence", type=PositiveIntDt.class, order=0, min=1, max=1, summary=false, modifier=false)     
2351        @Description(
2352                shortDefinition="",
2353                formalDefinition="Nominal position in a series"
2354        )
2355        private PositiveIntDt myDoseSequence;
2356        
2357        @Child(name="description", type=StringDt.class, order=1, min=0, max=1, summary=false, modifier=false)   
2358        @Description(
2359                shortDefinition="",
2360                formalDefinition="Contains the description about the protocol under which the vaccine was administered"
2361        )
2362        private StringDt myDescription;
2363        
2364        @Child(name="authority", order=2, min=0, max=1, summary=false, modifier=false, type={
2365                ca.uhn.fhir.model.dstu2.resource.Organization.class     })
2366        @Description(
2367                shortDefinition="",
2368                formalDefinition="Indicates the authority who published the protocol.  E.g. ACIP"
2369        )
2370        private ResourceReferenceDt myAuthority;
2371        
2372        @Child(name="series", type=StringDt.class, order=3, min=0, max=1, summary=false, modifier=false)        
2373        @Description(
2374                shortDefinition="",
2375                formalDefinition="One possible path to achieve presumed immunity against a disease - within the context of an authority"
2376        )
2377        private StringDt mySeries;
2378        
2379        @Child(name="seriesDoses", type=PositiveIntDt.class, order=4, min=0, max=1, summary=false, modifier=false)      
2380        @Description(
2381                shortDefinition="",
2382                formalDefinition="The recommended number of doses to achieve immunity."
2383        )
2384        private PositiveIntDt mySeriesDoses;
2385        
2386        @Child(name="targetDisease", type=CodeableConceptDt.class, order=5, min=1, max=Child.MAX_UNLIMITED, summary=false, modifier=false)      
2387        @Description(
2388                shortDefinition="",
2389                formalDefinition="The targeted disease"
2390        )
2391        private java.util.List<CodeableConceptDt> myTargetDisease;
2392        
2393        @Child(name="doseStatus", type=CodeableConceptDt.class, order=6, min=1, max=1, summary=false, modifier=false)   
2394        @Description(
2395                shortDefinition="",
2396                formalDefinition="Indicates if the immunization event should \"count\" against  the protocol."
2397        )
2398        private CodeableConceptDt myDoseStatus;
2399        
2400        @Child(name="doseStatusReason", type=CodeableConceptDt.class, order=7, min=0, max=1, summary=false, modifier=false)     
2401        @Description(
2402                shortDefinition="",
2403                formalDefinition="Provides an explanation as to why an immunization event should or should not count against the protocol."
2404        )
2405        private CodeableConceptDt myDoseStatusReason;
2406        
2407
2408        @Override
2409        public boolean isEmpty() {
2410                return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(  myDoseSequence,  myDescription,  myAuthority,  mySeries,  mySeriesDoses,  myTargetDisease,  myDoseStatus,  myDoseStatusReason);
2411        }
2412        
2413        @Override
2414        public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) {
2415                return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements(theType, myDoseSequence, myDescription, myAuthority, mySeries, mySeriesDoses, myTargetDisease, myDoseStatus, myDoseStatusReason);
2416        }
2417
2418        /**
2419         * Gets the value(s) for <b>doseSequence</b> ().
2420         * creating it if it does
2421         * not exist. Will not return <code>null</code>.
2422         *
2423     * <p>
2424     * <b>Definition:</b>
2425     * Nominal position in a series
2426     * </p> 
2427         */
2428        public PositiveIntDt getDoseSequenceElement() {  
2429                if (myDoseSequence == null) {
2430                        myDoseSequence = new PositiveIntDt();
2431                }
2432                return myDoseSequence;
2433        }
2434
2435        
2436        /**
2437         * Gets the value(s) for <b>doseSequence</b> ().
2438         * creating it if it does
2439         * not exist. This method may return <code>null</code>.
2440         *
2441     * <p>
2442     * <b>Definition:</b>
2443     * Nominal position in a series
2444     * </p> 
2445         */
2446        public Integer getDoseSequence() {  
2447                return getDoseSequenceElement().getValue();
2448        }
2449
2450        /**
2451         * Sets the value(s) for <b>doseSequence</b> ()
2452         *
2453     * <p>
2454     * <b>Definition:</b>
2455     * Nominal position in a series
2456     * </p> 
2457         */
2458        public VaccinationProtocol setDoseSequence(PositiveIntDt theValue) {
2459                myDoseSequence = theValue;
2460                return this;
2461        }
2462        
2463        
2464
2465        /**
2466         * Sets the value for <b>doseSequence</b> ()
2467         *
2468     * <p>
2469     * <b>Definition:</b>
2470     * Nominal position in a series
2471     * </p> 
2472         */
2473        public VaccinationProtocol setDoseSequence( int theInteger) {
2474                myDoseSequence = new PositiveIntDt(theInteger); 
2475                return this; 
2476        }
2477
2478 
2479        /**
2480         * Gets the value(s) for <b>description</b> ().
2481         * creating it if it does
2482         * not exist. Will not return <code>null</code>.
2483         *
2484     * <p>
2485     * <b>Definition:</b>
2486     * Contains the description about the protocol under which the vaccine was administered
2487     * </p> 
2488         */
2489        public StringDt getDescriptionElement() {  
2490                if (myDescription == null) {
2491                        myDescription = new StringDt();
2492                }
2493                return myDescription;
2494        }
2495
2496        
2497        /**
2498         * Gets the value(s) for <b>description</b> ().
2499         * creating it if it does
2500         * not exist. This method may return <code>null</code>.
2501         *
2502     * <p>
2503     * <b>Definition:</b>
2504     * Contains the description about the protocol under which the vaccine was administered
2505     * </p> 
2506         */
2507        public String getDescription() {  
2508                return getDescriptionElement().getValue();
2509        }
2510
2511        /**
2512         * Sets the value(s) for <b>description</b> ()
2513         *
2514     * <p>
2515     * <b>Definition:</b>
2516     * Contains the description about the protocol under which the vaccine was administered
2517     * </p> 
2518         */
2519        public VaccinationProtocol setDescription(StringDt theValue) {
2520                myDescription = theValue;
2521                return this;
2522        }
2523        
2524        
2525
2526        /**
2527         * Sets the value for <b>description</b> ()
2528         *
2529     * <p>
2530     * <b>Definition:</b>
2531     * Contains the description about the protocol under which the vaccine was administered
2532     * </p> 
2533         */
2534        public VaccinationProtocol setDescription( String theString) {
2535                myDescription = new StringDt(theString); 
2536                return this; 
2537        }
2538
2539 
2540        /**
2541         * Gets the value(s) for <b>authority</b> ().
2542         * creating it if it does
2543         * not exist. Will not return <code>null</code>.
2544         *
2545     * <p>
2546     * <b>Definition:</b>
2547     * Indicates the authority who published the protocol.  E.g. ACIP
2548     * </p> 
2549         */
2550        public ResourceReferenceDt getAuthority() {  
2551                if (myAuthority == null) {
2552                        myAuthority = new ResourceReferenceDt();
2553                }
2554                return myAuthority;
2555        }
2556
2557        /**
2558         * Sets the value(s) for <b>authority</b> ()
2559         *
2560     * <p>
2561     * <b>Definition:</b>
2562     * Indicates the authority who published the protocol.  E.g. ACIP
2563     * </p> 
2564         */
2565        public VaccinationProtocol setAuthority(ResourceReferenceDt theValue) {
2566                myAuthority = theValue;
2567                return this;
2568        }
2569        
2570        
2571
2572  
2573        /**
2574         * Gets the value(s) for <b>series</b> ().
2575         * creating it if it does
2576         * not exist. Will not return <code>null</code>.
2577         *
2578     * <p>
2579     * <b>Definition:</b>
2580     * One possible path to achieve presumed immunity against a disease - within the context of an authority
2581     * </p> 
2582         */
2583        public StringDt getSeriesElement() {  
2584                if (mySeries == null) {
2585                        mySeries = new StringDt();
2586                }
2587                return mySeries;
2588        }
2589
2590        
2591        /**
2592         * Gets the value(s) for <b>series</b> ().
2593         * creating it if it does
2594         * not exist. This method may return <code>null</code>.
2595         *
2596     * <p>
2597     * <b>Definition:</b>
2598     * One possible path to achieve presumed immunity against a disease - within the context of an authority
2599     * </p> 
2600         */
2601        public String getSeries() {  
2602                return getSeriesElement().getValue();
2603        }
2604
2605        /**
2606         * Sets the value(s) for <b>series</b> ()
2607         *
2608     * <p>
2609     * <b>Definition:</b>
2610     * One possible path to achieve presumed immunity against a disease - within the context of an authority
2611     * </p> 
2612         */
2613        public VaccinationProtocol setSeries(StringDt theValue) {
2614                mySeries = theValue;
2615                return this;
2616        }
2617        
2618        
2619
2620        /**
2621         * Sets the value for <b>series</b> ()
2622         *
2623     * <p>
2624     * <b>Definition:</b>
2625     * One possible path to achieve presumed immunity against a disease - within the context of an authority
2626     * </p> 
2627         */
2628        public VaccinationProtocol setSeries( String theString) {
2629                mySeries = new StringDt(theString); 
2630                return this; 
2631        }
2632
2633 
2634        /**
2635         * Gets the value(s) for <b>seriesDoses</b> ().
2636         * creating it if it does
2637         * not exist. Will not return <code>null</code>.
2638         *
2639     * <p>
2640     * <b>Definition:</b>
2641     * The recommended number of doses to achieve immunity.
2642     * </p> 
2643         */
2644        public PositiveIntDt getSeriesDosesElement() {  
2645                if (mySeriesDoses == null) {
2646                        mySeriesDoses = new PositiveIntDt();
2647                }
2648                return mySeriesDoses;
2649        }
2650
2651        
2652        /**
2653         * Gets the value(s) for <b>seriesDoses</b> ().
2654         * creating it if it does
2655         * not exist. This method may return <code>null</code>.
2656         *
2657     * <p>
2658     * <b>Definition:</b>
2659     * The recommended number of doses to achieve immunity.
2660     * </p> 
2661         */
2662        public Integer getSeriesDoses() {  
2663                return getSeriesDosesElement().getValue();
2664        }
2665
2666        /**
2667         * Sets the value(s) for <b>seriesDoses</b> ()
2668         *
2669     * <p>
2670     * <b>Definition:</b>
2671     * The recommended number of doses to achieve immunity.
2672     * </p> 
2673         */
2674        public VaccinationProtocol setSeriesDoses(PositiveIntDt theValue) {
2675                mySeriesDoses = theValue;
2676                return this;
2677        }
2678        
2679        
2680
2681        /**
2682         * Sets the value for <b>seriesDoses</b> ()
2683         *
2684     * <p>
2685     * <b>Definition:</b>
2686     * The recommended number of doses to achieve immunity.
2687     * </p> 
2688         */
2689        public VaccinationProtocol setSeriesDoses( int theInteger) {
2690                mySeriesDoses = new PositiveIntDt(theInteger); 
2691                return this; 
2692        }
2693
2694 
2695        /**
2696         * Gets the value(s) for <b>targetDisease</b> ().
2697         * creating it if it does
2698         * not exist. Will not return <code>null</code>.
2699         *
2700     * <p>
2701     * <b>Definition:</b>
2702     * The targeted disease
2703     * </p> 
2704         */
2705        public java.util.List<CodeableConceptDt> getTargetDisease() {  
2706                if (myTargetDisease == null) {
2707                        myTargetDisease = new java.util.ArrayList<CodeableConceptDt>();
2708                }
2709                return myTargetDisease;
2710        }
2711
2712        /**
2713         * Sets the value(s) for <b>targetDisease</b> ()
2714         *
2715     * <p>
2716     * <b>Definition:</b>
2717     * The targeted disease
2718     * </p> 
2719         */
2720        public VaccinationProtocol setTargetDisease(java.util.List<CodeableConceptDt> theValue) {
2721                myTargetDisease = theValue;
2722                return this;
2723        }
2724        
2725        
2726
2727        /**
2728         * Adds and returns a new value for <b>targetDisease</b> ()
2729         *
2730     * <p>
2731     * <b>Definition:</b>
2732     * The targeted disease
2733     * </p> 
2734         */
2735        public CodeableConceptDt addTargetDisease() {
2736                CodeableConceptDt newType = new CodeableConceptDt();
2737                getTargetDisease().add(newType);
2738                return newType; 
2739        }
2740
2741        /**
2742         * Adds a given new value for <b>targetDisease</b> ()
2743         *
2744         * <p>
2745         * <b>Definition:</b>
2746         * The targeted disease
2747         * </p>
2748         * @param theValue The targetDisease to add (must not be <code>null</code>)
2749         */
2750        public VaccinationProtocol addTargetDisease(CodeableConceptDt theValue) {
2751                if (theValue == null) {
2752                        throw new NullPointerException("theValue must not be null");
2753                }
2754                getTargetDisease().add(theValue);
2755                return this;
2756        }
2757
2758        /**
2759         * Gets the first repetition for <b>targetDisease</b> (),
2760         * creating it if it does not already exist.
2761         *
2762     * <p>
2763     * <b>Definition:</b>
2764     * The targeted disease
2765     * </p> 
2766         */
2767        public CodeableConceptDt getTargetDiseaseFirstRep() {
2768                if (getTargetDisease().isEmpty()) {
2769                        return addTargetDisease();
2770                }
2771                return getTargetDisease().get(0); 
2772        }
2773  
2774        /**
2775         * Gets the value(s) for <b>doseStatus</b> ().
2776         * creating it if it does
2777         * not exist. Will not return <code>null</code>.
2778         *
2779     * <p>
2780     * <b>Definition:</b>
2781     * Indicates if the immunization event should \&quot;count\&quot; against  the protocol.
2782     * </p> 
2783         */
2784        public CodeableConceptDt getDoseStatus() {  
2785                if (myDoseStatus == null) {
2786                        myDoseStatus = new CodeableConceptDt();
2787                }
2788                return myDoseStatus;
2789        }
2790
2791        /**
2792         * Sets the value(s) for <b>doseStatus</b> ()
2793         *
2794     * <p>
2795     * <b>Definition:</b>
2796     * Indicates if the immunization event should \&quot;count\&quot; against  the protocol.
2797     * </p> 
2798         */
2799        public VaccinationProtocol setDoseStatus(CodeableConceptDt theValue) {
2800                myDoseStatus = theValue;
2801                return this;
2802        }
2803        
2804        
2805
2806  
2807        /**
2808         * Gets the value(s) for <b>doseStatusReason</b> ().
2809         * creating it if it does
2810         * not exist. Will not return <code>null</code>.
2811         *
2812     * <p>
2813     * <b>Definition:</b>
2814     * Provides an explanation as to why an immunization event should or should not count against the protocol.
2815     * </p> 
2816         */
2817        public CodeableConceptDt getDoseStatusReason() {  
2818                if (myDoseStatusReason == null) {
2819                        myDoseStatusReason = new CodeableConceptDt();
2820                }
2821                return myDoseStatusReason;
2822        }
2823
2824        /**
2825         * Sets the value(s) for <b>doseStatusReason</b> ()
2826         *
2827     * <p>
2828     * <b>Definition:</b>
2829     * Provides an explanation as to why an immunization event should or should not count against the protocol.
2830     * </p> 
2831         */
2832        public VaccinationProtocol setDoseStatusReason(CodeableConceptDt theValue) {
2833                myDoseStatusReason = theValue;
2834                return this;
2835        }
2836        
2837        
2838
2839  
2840
2841
2842        }
2843
2844
2845
2846
2847    @Override
2848    public String getResourceName() {
2849        return "Immunization";
2850    }
2851    
2852    public ca.uhn.fhir.context.FhirVersionEnum getStructureFhirVersionEnum() {
2853        return ca.uhn.fhir.context.FhirVersionEnum.DSTU2;
2854    }
2855
2856
2857}