From 5088850e6b252e74b312ec417ba1de650868103c Mon Sep 17 00:00:00 2001
From: jamesagnew
Date: Sun, 16 Mar 2014 15:09:30 -0400
Subject: [PATCH] More work on JSON parser, and contained resources
---
hapi-fhir-base/.classpath | 112 +-
hapi-fhir-base/.project | 1 -
.../org.eclipse.core.resources.prefs | 2 +
hapi-fhir-base/TODO.txt | 4 +-
hapi-fhir-base/pom.xml | 34 +-
.../BaseRuntimeDeclaredChildDefinition.java | 4 +-
.../java/ca/uhn/fhir/context/FhirContext.java | 4 +-
.../context/IRuntimeDatatypeDefinition.java | 7 +
.../ca/uhn/fhir/context/ModelScanner.java | 37 +-
.../RuntimeChildResourceDefinition.java | 27 +-
...imeChildUndeclaredExtensionDefinition.java | 12 +-
.../RuntimeCompositeDatatypeDefinition.java | 24 +-
.../RuntimePrimitiveDatatypeDefinition.java | 24 +-
.../RuntimeResourceBlockDefinition.java | 1 -
.../RuntimeResourceReferenceDefinition.java | 2 +-
.../ca/uhn/fhir/model/api/BaseBundle.java | 2 +-
.../ca/uhn/fhir/model/api/BaseElement.java | 16 +-
.../fhir/model/api/BaseResourceReference.java | 23 +-
.../java/ca/uhn/fhir/model/api/Bundle.java | 12 +-
.../ca/uhn/fhir/model/api/BundleCategory.java | 2 +-
.../ca/uhn/fhir/model/api/BundleEntry.java | 13 +-
.../uhn/fhir/model/api/ICompositeElement.java | 5 +
.../java/ca/uhn/fhir/model/api/IElement.java | 7 +-
.../uhn/fhir/model/api/IQueryParameterOr.java | 28 +
.../uhn/fhir/model/api/ValueSetRegistry.java | 2 -
.../model/api/annotation/DatatypeDef.java | 15 +
.../fhir/model/dstu/composite/AddressDt.java | 31 +-
.../model/dstu/composite/AttachmentDt.java | 22 +-
.../dstu/composite/CodeableConceptDt.java | 26 +-
.../fhir/model/dstu/composite/CodingDt.java | 77 +-
.../fhir/model/dstu/composite/ContactDt.java | 22 +-
.../fhir/model/dstu/composite/DurationDt.java | 3 +
.../model/dstu/composite/HumanNameDt.java | 61 +-
.../model/dstu/composite/IdentifierDt.java | 25 +-
.../model/dstu/composite/NarrativeDt.java | 20 +-
.../fhir/model/dstu/composite/PeriodDt.java | 37 +-
.../fhir/model/dstu/composite/QuantityDt.java | 27 +-
.../fhir/model/dstu/composite/RangeDt.java | 17 +-
.../fhir/model/dstu/composite/RatioDt.java | 17 +-
.../dstu/composite/ResourceReferenceDt.java | 18 +-
.../model/dstu/composite/SampledDataDt.java | 36 +-
.../fhir/model/dstu/composite/ScheduleDt.java | 54 +-
.../uhn/fhir/model/dstu/resource/Binary.java | 12 +-
.../fhir/model/dstu/resource/Conformance.java | 308 ++-
.../uhn/fhir/model/dstu/resource/Device.java | 59 +-
.../model/dstu/resource/DiagnosticOrder.java | 1154 ++++++++++
.../model/dstu/resource/DiagnosticReport.java | 1027 +++++++++
.../fhir/model/dstu/resource/Encounter.java | 1731 +++++++++++++++
.../uhn/fhir/model/dstu/resource/Group.java | 63 +-
.../model/dstu/resource/ImagingStudy.java | 1849 ++++++++++++++++
.../fhir/model/dstu/resource/Location.java | 64 +-
.../uhn/fhir/model/dstu/resource/Media.java | 750 +++++++
.../fhir/model/dstu/resource/Medication.java | 54 +-
.../fhir/model/dstu/resource/Observation.java | 103 +-
.../model/dstu/resource/Organization.java | 90 +-
.../uhn/fhir/model/dstu/resource/Patient.java | 162 +-
.../model/dstu/resource/Practitioner.java | 121 +-
.../uhn/fhir/model/dstu/resource/Profile.java | 265 ++-
.../model/dstu/resource/RelatedPerson.java | 508 +++++
.../fhir/model/dstu/resource/Specimen.java | 149 +-
.../fhir/model/dstu/resource/Substance.java | 62 +-
.../fhir/model/dstu/resource/ValueSet.java | 171 +-
.../model/dstu/valueset/AddressUseEnum.java | 3 +-
.../AdministrativeGenderCodesEnum.java | 3 +-
.../model/dstu/valueset/AdmitSourceEnum.java | 163 ++
.../dstu/valueset/AggregationModeEnum.java | 3 +-
.../dstu/valueset/AnimalSpeciesEnum.java | 3 +-
.../dstu/valueset/BindingConformanceEnum.java | 3 +-
.../valueset/ConformanceEventModeEnum.java | 3 +-
.../ConformanceStatementStatusEnum.java | 3 +-
.../dstu/valueset/ConstraintSeverityEnum.java | 3 +-
.../dstu/valueset/ContactSystemEnum.java | 3 +-
.../model/dstu/valueset/ContactUseEnum.java | 3 +-
.../model/dstu/valueset/DataTypeEnum.java | 3 +-
.../valueset/DiagnosticOrderPriorityEnum.java | 135 ++
.../valueset/DiagnosticOrderStatusEnum.java | 166 ++
.../valueset/DiagnosticReportStatusEnum.java | 159 ++
.../model/dstu/valueset/DocumentModeEnum.java | 3 +-
.../dstu/valueset/EncounterClassEnum.java | 159 ++
.../valueset/EncounterReasonCodesEnum.java | 103 +
.../dstu/valueset/EncounterStateEnum.java | 138 ++
.../dstu/valueset/EncounterTypeEnum.java | 127 ++
.../model/dstu/valueset/EventTimingEnum.java | 3 +-
.../dstu/valueset/ExtensionContextEnum.java | 3 +-
.../dstu/valueset/FHIRDefinedTypeEnum.java | 3 +-
.../dstu/valueset/FilterOperatorEnum.java | 3 +-
.../model/dstu/valueset/GroupTypeEnum.java | 3 +-
.../HierarchicalRelationshipTypeEnum.java | 3 +-
.../dstu/valueset/IdentifierUseEnum.java | 3 +-
.../dstu/valueset/ImagingModalityEnum.java | 283 +++
.../valueset/InstanceAvailabilityEnum.java | 123 ++
.../model/dstu/valueset/LinkTypeEnum.java | 3 +-
.../model/dstu/valueset/LocationModeEnum.java | 3 +-
.../dstu/valueset/LocationStatusEnum.java | 3 +-
.../model/dstu/valueset/LocationTypeEnum.java | 3 +-
.../dstu/valueset/MaritalStatusCodesEnum.java | 3 +-
.../model/dstu/valueset/MediaTypeEnum.java | 124 ++
.../dstu/valueset/MedicationKindEnum.java | 3 +-
.../model/dstu/valueset/MessageEventEnum.java | 180 ++
.../MessageSignificanceCategoryEnum.java | 3 +-
.../dstu/valueset/MessageTransportEnum.java | 124 ++
.../model/dstu/valueset/ModalityEnum.java | 368 ++++
.../fhir/model/dstu/valueset/NameUseEnum.java | 3 +-
.../dstu/valueset/NarrativeStatusEnum.java | 4 +-
.../ObservationInterpretationCodesEnum.java | 3 +-
.../ObservationRelationshipTypeEnum.java | 3 +-
.../valueset/ObservationReliabilityEnum.java | 3 +-
.../dstu/valueset/ObservationStatusEnum.java | 3 +-
.../dstu/valueset/OrganizationTypeEnum.java | 3 +-
.../dstu/valueset/ParticipantTypeEnum.java | 119 +
.../valueset/PatientRelationshipTypeEnum.java | 103 +
.../dstu/valueset/PractitionerRoleEnum.java | 3 +-
.../valueset/PractitionerSpecialtyEnum.java | 3 +-
.../valueset/PropertyRepresentationEnum.java | 3 +-
.../valueset/QuantityCompararatorEnum.java | 3 +-
.../valueset/ResourceProfileStatusEnum.java | 3 +-
.../model/dstu/valueset/ResourceTypeEnum.java | 3 +-
.../valueset/RestfulConformanceModeEnum.java | 3 +-
.../valueset/RestfulOperationSystemEnum.java | 3 +-
.../valueset/RestfulOperationTypeEnum.java | 3 +-
.../valueset/RestfulSecurityServiceEnum.java | 3 +-
.../dstu/valueset/SearchParamTypeEnum.java | 3 +-
.../model/dstu/valueset/SlicingRulesEnum.java | 3 +-
.../SpecimenCollectionMethodEnum.java | 3 +-
.../SpecimenTreatmentProcedureEnum.java | 3 +-
.../dstu/valueset/SubstanceTypeEnum.java | 3 +-
.../model/dstu/valueset/UnitsOfTimeEnum.java | 3 +-
.../dstu/valueset/ValueSetStatusEnum.java | 3 +-
.../fhir/model/primitive/BaseDateTimeDt.java | 2 -
.../uhn/fhir/model/primitive/BoundCodeDt.java | 2 +-
.../uhn/fhir/model/primitive/DecimalDt.java | 2 -
.../ca/uhn/fhir/model/primitive/IdDt.java | 2 -
.../uhn/fhir/model/primitive/IntegerDt.java | 2 -
.../ca/uhn/fhir/model/primitive/OidDt.java | 3 +
.../ca/uhn/fhir/model/primitive/StringDt.java | 2 -
.../ca/uhn/fhir/model/primitive/UriDt.java | 2 -
.../main/java/ca/uhn/fhir/parser/IParser.java | 6 +-
.../java/ca/uhn/fhir/parser/JsonParser.java | 610 ++---
.../java/ca/uhn/fhir/parser/ParserState.java | 216 +-
.../java/ca/uhn/fhir/parser/XmlParser.java | 41 +-
.../rest/client/ClientInvocationHandler.java | 2 +-
.../fhir/rest/client/GetClientInvocation.java | 38 +-
.../rest/client/RestfulClientFactory.java | 9 +-
.../{common => method}/BaseMethodBinding.java | 6 +-
.../ConformanceMethodBinding.java | 4 +-
.../{common => method}/ReadMethodBinding.java | 4 +-
.../fhir/rest/{common => method}/Request.java | 5 +-
.../SearchMethodBinding.java | 62 +-
.../uhn/fhir/rest/param/CodingListParam.java | 49 +
.../uhn/fhir/rest/param/CollectionBinder.java | 57 +
.../ca/uhn/fhir/rest/param/IParamBinder.java | 14 +
.../fhir/rest/param/IdentifierListParam.java | 45 +
.../ca/uhn/fhir/rest/param/Parameter.java | 79 +
.../fhir/rest/param/QualifiedDateParam.java | 85 +
.../rest/param/QueryParameterOrBinder.java | 45 +
.../rest/param/QueryParameterTypeBinder.java | 45 +
.../ca/uhn/fhir/rest/server/Constants.java | 34 +
.../ca/uhn/fhir/rest/server/EncodingUtil.java | 22 +-
.../fhir/rest/server/ISecurityManager.java | 4 +-
.../ca/uhn/fhir/rest/server/Parameter.java | 104 -
.../ca/uhn/fhir/rest/server/Resource.java | 6 +-
.../uhn/fhir/rest/server/RestfulServer.java | 288 +--
.../java/ca/uhn/fhir/rest/server/Util.java | 24 +-
.../exceptions/AuthenticationException.java | 1 -
.../java/ca/uhn/fhir/util/ElementUtil.java | 23 +
.../fhir/util/PrettyPrintWriterWrapper.java | 1 -
.../main/java/ca/uhn/fhir/util/QueryUtil.java | 30 +
.../java/ca/uhn/fhir/util/ReflectionUtil.java | 49 +
.../java/example/FhirContextIntro.java | 2 +-
.../RestfulPatientResourceProviderMore.java | 95 +-
hapi-fhir-base/src/site/resources/hapi.css | 3 +-
.../src/site/xdoc/doc_rest_operations.xml | 95 +-
.../ca/uhn/fhir/context/ModelScannerTest.java | 4 -
.../fhir/context/ResourceWithExtensionsA.java | 56 +
.../RuntimeResourceDefinitionTest.java | 3 -
.../model/primitive/Base64BinaryDtTest.java | 2 -
.../model/primitive/BaseDateTimeDtTest.java | 2 -
.../ca/uhn/fhir/parser/JsonParserTest.java | 50 +-
.../ca/uhn/fhir/parser/XmlParserTest.java | 21 +-
.../ca/uhn/fhir/rest/client/ClientTest.java | 50 +-
.../ca/uhn/fhir/rest/client/ITestClient.java | 9 +
.../java/ca/uhn/fhir/rest/client/Tester.java | 2 -
.../server/DummyPatientResourceProvider.java | 36 +-
.../fhir/rest/server/DummyRestfulServer.java | 3 -
.../fhir/rest/server/ResfulServerTest.java | 122 +-
.../fhir/rest/server/ResourceMethodTest.java | 10 +-
.../ca/uhn/fhir/testmodel/IdentifierDt.java | 9 +
.../java/ca/uhn/fhir/testmodel/Patient.java | 17 +-
.../ca/uhn/fhir/testutil/QueryUtilTest.java | 37 +
.../resources/contained-diagnosticreport.json | 778 +++++++
.../resources/contained-diagnosticreport.xml | 718 ++++++
.../resources/example-patient-general.json | 448 ++++
.../resources/example-patient-general.xml | 27 +-
.../resources/observation-example-eeg.xml | 3 +-
hapi-fhir-structures-dstu/pom.xml | 6 +
.../ResourceGeneratorUsingSpreadsheet.java | 2 +-
.../java/ca/uhn/fhir/tinder/model/Child.java | 2 +-
.../res/diagnosticorder-spreadsheet.xml | 1032 +++++++++
.../res/diagnosticreport-spreadsheet.xml | 1197 ++++++++++
.../resources/res/encounter-spreadsheet.xml | 1330 +++++++++++
.../res/imagingstudy-spreadsheet.xml | 1956 +++++++++++++++++
.../main/resources/res/media-spreadsheet.xml | 1086 +++++++++
.../res/relatedperson-spreadsheet.xml | 650 ++++++
.../src/main/resources/vm/dt_composite.vm | 57 +-
.../src/main/resources/vm/templates.vm | 9 +
pom.xml | 3 +-
206 files changed, 22716 insertions(+), 1581 deletions(-)
create mode 100644 hapi-fhir-base/.settings/org.eclipse.core.resources.prefs
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/context/IRuntimeDatatypeDefinition.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/IQueryParameterOr.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/DiagnosticOrder.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/DiagnosticReport.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/Encounter.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/ImagingStudy.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/Media.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/RelatedPerson.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/AdmitSourceEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/DiagnosticOrderPriorityEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/DiagnosticOrderStatusEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/DiagnosticReportStatusEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/EncounterClassEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/EncounterReasonCodesEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/EncounterStateEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/EncounterTypeEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/ImagingModalityEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/InstanceAvailabilityEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/MediaTypeEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/MessageEventEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/MessageTransportEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/ModalityEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/ParticipantTypeEnum.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/valueset/PatientRelationshipTypeEnum.java
rename hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/{common => method}/BaseMethodBinding.java (98%)
rename hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/{common => method}/ConformanceMethodBinding.java (93%)
rename hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/{common => method}/ReadMethodBinding.java (97%)
rename hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/{common => method}/Request.java (93%)
rename hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/{common => method}/SearchMethodBinding.java (81%)
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/param/CodingListParam.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/param/CollectionBinder.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/param/IParamBinder.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/param/IdentifierListParam.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/param/Parameter.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/param/QualifiedDateParam.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/param/QueryParameterOrBinder.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/param/QueryParameterTypeBinder.java
delete mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/rest/server/Parameter.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/util/QueryUtil.java
create mode 100644 hapi-fhir-base/src/main/java/ca/uhn/fhir/util/ReflectionUtil.java
create mode 100644 hapi-fhir-base/src/test/java/ca/uhn/fhir/testutil/QueryUtilTest.java
create mode 100644 hapi-fhir-base/src/test/resources/contained-diagnosticreport.json
create mode 100644 hapi-fhir-base/src/test/resources/contained-diagnosticreport.xml
create mode 100644 hapi-fhir-base/src/test/resources/example-patient-general.json
create mode 100644 hapi-tinder-plugin/src/main/resources/res/diagnosticorder-spreadsheet.xml
create mode 100644 hapi-tinder-plugin/src/main/resources/res/diagnosticreport-spreadsheet.xml
create mode 100644 hapi-tinder-plugin/src/main/resources/res/encounter-spreadsheet.xml
create mode 100644 hapi-tinder-plugin/src/main/resources/res/imagingstudy-spreadsheet.xml
create mode 100644 hapi-tinder-plugin/src/main/resources/res/media-spreadsheet.xml
create mode 100644 hapi-tinder-plugin/src/main/resources/res/relatedperson-spreadsheet.xml
diff --git a/hapi-fhir-base/.classpath b/hapi-fhir-base/.classpath
index 80d418e6e21..63b83033cc1 100644
--- a/hapi-fhir-base/.classpath
+++ b/hapi-fhir-base/.classpath
@@ -1,70 +1,96 @@
-
-
+
+
+
+
+
+
+
+
-
-
-
+
+
-
+
-
+
-
+
+
+
+
+
+
+
-
-
+
-
-
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/hapi-fhir-base/.project b/hapi-fhir-base/.project
index a75380b92e5..22f076c3eef 100644
--- a/hapi-fhir-base/.project
+++ b/hapi-fhir-base/.project
@@ -1,4 +1,3 @@
-
hapi-fhir-base
NO_M2ECLIPSE_SUPPORT: Project files created with the maven-eclipse-plugin are not supported in M2Eclipse.
diff --git a/hapi-fhir-base/.settings/org.eclipse.core.resources.prefs b/hapi-fhir-base/.settings/org.eclipse.core.resources.prefs
new file mode 100644
index 00000000000..99f26c0203a
--- /dev/null
+++ b/hapi-fhir-base/.settings/org.eclipse.core.resources.prefs
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/=UTF-8
diff --git a/hapi-fhir-base/TODO.txt b/hapi-fhir-base/TODO.txt
index 3d47d223154..2ab3fe8135f 100644
--- a/hapi-fhir-base/TODO.txt
+++ b/hapi-fhir-base/TODO.txt
@@ -40,4 +40,6 @@ Issues:
* CarePlan.Activity has a type of "xmlIdRef" which is a weird datatype. The example here:
http://www.hl7.org/implement/standards/fhir/careplan-example-integrated.xml.html
- seems to use an extension to model that element instead of the goal type too.
\ No newline at end of file
+ seems to use an extension to model that element instead of the goal type too.
+
+ * Would like a standardized (but optional) HTTP parameter for pretty-printing. Suggest: _pretty=true
\ No newline at end of file
diff --git a/hapi-fhir-base/pom.xml b/hapi-fhir-base/pom.xml
index bd7558a79ae..f495672536a 100644
--- a/hapi-fhir-base/pom.xml
+++ b/hapi-fhir-base/pom.xml
@@ -18,12 +18,24 @@
+
+
+ javax.json
+ javax.json-api
+ 1.0
+
+
+ org.glassfish
+ javax.json
+ 1.0.4
+
+
org.codehaus.woodstox
@@ -80,7 +92,7 @@
javax.servlet
javax.servlet-api
- 3.1.0
+ 3.0.1
provided
@@ -115,6 +127,20 @@
1.9.5
test
+
+ net.sf.json-lib
+ json-lib
+ 2.4
+ jdk15
+ test
+
+
+ net.sf.json-lib
+ json-lib
+ 2.4
+ jdk15-sources
+ test
+
org.eclipse.jetty
@@ -196,6 +222,10 @@
+
+ UTF-8
+
+
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/BaseRuntimeDeclaredChildDefinition.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/BaseRuntimeDeclaredChildDefinition.java
index 7b96af6169d..003d54d3c0d 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/BaseRuntimeDeclaredChildDefinition.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/BaseRuntimeDeclaredChildDefinition.java
@@ -58,8 +58,8 @@ public abstract class BaseRuntimeDeclaredChildDefinition extends BaseRuntimeChil
final Class> targetReturnType = myField.getType();
try {
String elementName = myElementName;
- if ("Class".equals(elementName)) {
- elementName = "ClassElement"; // because getClass() is reserved
+ if ("class".equals(elementName.toLowerCase())) {
+ elementName = "classElement"; // because getClass() is reserved
}
final Method accessor = BeanUtils.findAccessor(declaringClass, targetReturnType, elementName);
final Method mutator = BeanUtils.findMutator(declaringClass, targetReturnType, elementName);
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/FhirContext.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/FhirContext.java
index 6c98bb9b3fa..26b9bb32f7a 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/FhirContext.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/FhirContext.java
@@ -41,8 +41,8 @@ public class FhirContext {
return myIdToResourceDefinition.get(theId);
}
- public Map, BaseRuntimeElementDefinition>> getClassToElementDefinition() {
- return myClassToElementDefinition;
+ public BaseRuntimeElementDefinition> getElementDefinition(Class extends IElement> theElementType) {
+ return myClassToElementDefinition.get(theElementType);
}
public RuntimeResourceDefinition getResourceDefinition(Class extends IResource> theResourceType) {
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/IRuntimeDatatypeDefinition.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/IRuntimeDatatypeDefinition.java
new file mode 100644
index 00000000000..457971e6d44
--- /dev/null
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/IRuntimeDatatypeDefinition.java
@@ -0,0 +1,7 @@
+package ca.uhn.fhir.context;
+
+public interface IRuntimeDatatypeDefinition {
+
+ boolean isSpecialization();
+
+}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/ModelScanner.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/ModelScanner.java
index 933824e5369..bbe1ddc6989 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/ModelScanner.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/ModelScanner.java
@@ -17,6 +17,7 @@ import java.util.Set;
import java.util.TreeMap;
import java.util.TreeSet;
+import ca.uhn.fhir.model.api.BaseResourceReference;
import ca.uhn.fhir.model.api.CodeableConceptElement;
import ca.uhn.fhir.model.api.ICodeEnum;
import ca.uhn.fhir.model.api.ICompositeDatatype;
@@ -27,7 +28,6 @@ import ca.uhn.fhir.model.api.IPrimitiveDatatype;
import ca.uhn.fhir.model.api.IResource;
import ca.uhn.fhir.model.api.IResourceBlock;
import ca.uhn.fhir.model.api.IValueSetEnumBinder;
-import ca.uhn.fhir.model.api.BaseResourceReference;
import ca.uhn.fhir.model.api.annotation.Block;
import ca.uhn.fhir.model.api.annotation.Child;
import ca.uhn.fhir.model.api.annotation.CodeTableDef;
@@ -42,6 +42,7 @@ import ca.uhn.fhir.model.primitive.CodeDt;
import ca.uhn.fhir.model.primitive.DateDt;
import ca.uhn.fhir.model.primitive.ICodedDatatype;
import ca.uhn.fhir.model.primitive.XhtmlDt;
+import ca.uhn.fhir.util.ReflectionUtil;
class ModelScanner {
private static final org.slf4j.Logger ourLog = org.slf4j.LoggerFactory.getLogger(ModelScanner.class);
@@ -92,7 +93,7 @@ class ModelScanner {
private Class> determineElementType(Field next) {
Class> nextElementType = next.getType();
if (List.class.equals(nextElementType)) {
- nextElementType = getGenericCollectionTypeOfField(next);
+ nextElementType = ReflectionUtil.getGenericCollectionTypeOfField(next);
} else if (Collection.class.isAssignableFrom(nextElementType)) {
throw new ConfigurationException("Field '" + next.getName() + "' in type '" + next.getClass().getCanonicalName() + "' is a Collection - Only java.util.List curently supported");
}
@@ -231,12 +232,7 @@ class ModelScanner {
private void scanCompositeDatatype(Class extends ICompositeDatatype> theClass, DatatypeDef theDatatypeDefinition) {
ourLog.debug("Scanning resource class: {}", theClass.getName());
- String resourceName = theDatatypeDefinition.name();
- if (isBlank(resourceName)) {
- throw new ConfigurationException("Resource type @" + ResourceDef.class.getSimpleName() + " annotation contains no resource name: " + theClass.getCanonicalName());
- }
-
- RuntimeCompositeDatatypeDefinition resourceDef = new RuntimeCompositeDatatypeDefinition(resourceName, theClass);
+ RuntimeCompositeDatatypeDefinition resourceDef = new RuntimeCompositeDatatypeDefinition(theDatatypeDefinition, theClass);
myClassToElementDefinitions.put(theClass, resourceDef);
scanCompositeElementForChildren(theClass, resourceDef, null);
}
@@ -368,7 +364,7 @@ class ModelScanner {
List> refTypesList = new ArrayList>();
for (Class extends IElement> nextType : childAnnotation.type()) {
if (IResource.class.isAssignableFrom(nextType) == false) {
- throw new ConfigurationException("Field '" + next.getName() + "' is of type " + ResourceReferenceDt.class + " but contains a non-resource type: " + nextType.getCanonicalName());
+ throw new ConfigurationException("Field '" + next.getName() + "' in class '" + next.getDeclaringClass().getSimpleName() + "' is of type " + ResourceReferenceDt.class + " but contains a non-resource type: " + nextType.getCanonicalName());
}
refTypesList.add((Class extends IResource>) nextType);
addScanAlso(nextType);
@@ -444,7 +440,7 @@ class ModelScanner {
Class clazz = (Class) theClass;
resourceDef = new RuntimePrimitiveDatatypeNarrativeDefinition(resourceName, clazz);
} else {
- resourceDef = new RuntimePrimitiveDatatypeDefinition(resourceName, theClass);
+ resourceDef = new RuntimePrimitiveDatatypeDefinition(theDatatypeDefinition, theClass);
}
myClassToElementDefinitions.put(theClass, resourceDef);
@@ -506,26 +502,5 @@ class ModelScanner {
return type;
}
- private static Class> getGenericCollectionTypeOfField(Field next) {
- // Type genericSuperclass = next.getType().getGenericSuperclass();
- Class> type;
- // if (genericSuperclass == null) {
- ParameterizedType collectionType = (ParameterizedType) next.getGenericType();
- Type firstArg = collectionType.getActualTypeArguments()[0];
- if (ParameterizedType.class.isAssignableFrom(firstArg.getClass())) {
- ParameterizedType pt = ((ParameterizedType) firstArg);
- type = (Class>) pt.getRawType();
- // firstArg = pt.getActualTypeArguments()[0];
- // type = (Class>) firstArg;
- } else {
- type = (Class>) firstArg;
- }
- // }else {
- // Type[] actualTypeArguments = ((ParameterizedType)
- // genericSuperclass).getActualTypeArguments();
- // type = (Class>) actualTypeArguments[0];
- // }
- return type;
- }
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeChildResourceDefinition.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeChildResourceDefinition.java
index 0a418a0e0f5..bec4393a17f 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeChildResourceDefinition.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeChildResourceDefinition.java
@@ -5,11 +5,12 @@ import java.util.Collections;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
+import java.util.Map.Entry;
import java.util.Set;
+import ca.uhn.fhir.model.api.BaseResourceReference;
import ca.uhn.fhir.model.api.IElement;
import ca.uhn.fhir.model.api.IResource;
-import ca.uhn.fhir.model.api.BaseResourceReference;
import ca.uhn.fhir.model.api.annotation.Child;
import ca.uhn.fhir.model.api.annotation.Description;
@@ -22,7 +23,7 @@ public class RuntimeChildResourceDefinition extends BaseRuntimeDeclaredChildDefi
public RuntimeChildResourceDefinition(Field theField, String theElementName, Child theChildAnnotation, Description theDescriptionAnnotation, List> theResourceTypes) {
super(theField, theChildAnnotation, theDescriptionAnnotation, theElementName);
myResourceTypes = theResourceTypes;
-
+
if (theResourceTypes == null || theResourceTypes.isEmpty()) {
throw new ConfigurationException("Field '" + theField.getName() + "' on type '" + theField.getDeclaringClass().getCanonicalName() + "' has no resource types noted");
}
@@ -58,16 +59,28 @@ public class RuntimeChildResourceDefinition extends BaseRuntimeDeclaredChildDefi
void sealAndInitialize(Map, BaseRuntimeElementDefinition>> theClassToElementDefinitions) {
myRuntimeDef = new RuntimeResourceReferenceDefinition(getElementName(), myResourceTypes);
myRuntimeDef.sealAndInitialize(theClassToElementDefinitions);
-
+
myValidChildNames = new HashSet();
myValidChildNames.add(getElementName());
myValidChildNames.add(getElementName() + "Resource");
-
+
for (Class extends IResource> next : myResourceTypes) {
- RuntimeResourceDefinition nextDef = (RuntimeResourceDefinition) theClassToElementDefinitions.get(next);
- myValidChildNames.add(getElementName() + nextDef.getName());
+ if (next == IResource.class) {
+ for (Entry, BaseRuntimeElementDefinition>> nextEntry : theClassToElementDefinitions.entrySet()) {
+ if (IResource.class.isAssignableFrom(nextEntry.getKey())) {
+ RuntimeResourceDefinition nextDef = (RuntimeResourceDefinition) nextEntry.getValue();
+ myValidChildNames.add(getElementName() + nextDef.getName());
+ }
+ }
+ } else {
+ RuntimeResourceDefinition nextDef = (RuntimeResourceDefinition) theClassToElementDefinitions.get(next);
+ if (nextDef == null) {
+ throw new ConfigurationException("Can't find child of type: " + next.getCanonicalName() + " in " + getField().getDeclaringClass());
+ }
+ myValidChildNames.add(getElementName() + nextDef.getName());
+ }
}
-
+
myValidChildNames = Collections.unmodifiableSet(myValidChildNames);
}
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeChildUndeclaredExtensionDefinition.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeChildUndeclaredExtensionDefinition.java
index 3541895a383..57b2005f6c5 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeChildUndeclaredExtensionDefinition.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeChildUndeclaredExtensionDefinition.java
@@ -8,10 +8,10 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.Set;
+import ca.uhn.fhir.model.api.BaseResourceReference;
import ca.uhn.fhir.model.api.IDatatype;
import ca.uhn.fhir.model.api.IElement;
import ca.uhn.fhir.model.api.IResource;
-import ca.uhn.fhir.model.api.BaseResourceReference;
import ca.uhn.fhir.model.api.UndeclaredExtension;
import ca.uhn.fhir.model.dstu.composite.ResourceReferenceDt;
@@ -52,9 +52,11 @@ public class RuntimeChildUndeclaredExtensionDefinition extends BaseRuntimeChildD
Map> datatypeAttributeNameToDefinition=new HashMap>();
for (BaseRuntimeElementDefinition> next : theClassToElementDefinitions.values()) {
- if (next instanceof RuntimePrimitiveDatatypeDefinition || next instanceof RuntimeCompositeDatatypeDefinition) {
- String attrName = "value" + next.getName().substring(0, 1).toUpperCase() + next.getName().substring(1);
- datatypeAttributeNameToDefinition.put(attrName, next);
+ if (next instanceof IRuntimeDatatypeDefinition) {
+ if (!((IRuntimeDatatypeDefinition) next).isSpecialization()) {
+ String attrName = "value" + next.getName().substring(0, 1).toUpperCase() + next.getName().substring(1);
+ datatypeAttributeNameToDefinition.put(attrName, next);
+ }
}
}
@@ -71,7 +73,7 @@ public class RuntimeChildUndeclaredExtensionDefinition extends BaseRuntimeChildD
}
// Resource Reference
- myDatatypeToAttributeName.put(BaseResourceReference.class, "valueReference");
+ myDatatypeToAttributeName.put(ResourceReferenceDt.class, "valueReference");
List> types = new ArrayList>();
types.add(IResource.class);
RuntimeResourceReferenceDefinition def = new RuntimeResourceReferenceDefinition("valueResource", types);
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeCompositeDatatypeDefinition.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeCompositeDatatypeDefinition.java
index 4a9e27a3529..ec16dbca1df 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeCompositeDatatypeDefinition.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeCompositeDatatypeDefinition.java
@@ -1,12 +1,28 @@
package ca.uhn.fhir.context;
-import ca.uhn.fhir.context.BaseRuntimeElementDefinition.ChildTypeEnum;
+import static org.apache.commons.lang3.StringUtils.*;
import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.ResourceDef;
-public class RuntimeCompositeDatatypeDefinition extends BaseRuntimeElementCompositeDefinition {
+public class RuntimeCompositeDatatypeDefinition extends BaseRuntimeElementCompositeDefinition implements IRuntimeDatatypeDefinition {
- public RuntimeCompositeDatatypeDefinition(String theName, Class extends ICompositeDatatype> theImplementingClass) {
- super(theName, theImplementingClass);
+ private boolean mySpecialization;
+
+ public RuntimeCompositeDatatypeDefinition(DatatypeDef theDef, Class extends ICompositeDatatype> theImplementingClass) {
+ super(theDef.name(), theImplementingClass);
+
+ String resourceName = theDef.name();
+ if (isBlank(resourceName)) {
+ throw new ConfigurationException("Resource type @" + ResourceDef.class.getSimpleName() + " annotation contains no resource name: " + theImplementingClass.getCanonicalName());
+ }
+
+ mySpecialization = theDef.isSpecialization();
+
+ }
+
+ public boolean isSpecialization() {
+ return mySpecialization;
}
@Override
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimePrimitiveDatatypeDefinition.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimePrimitiveDatatypeDefinition.java
index 862124845a0..721a0c2b86f 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimePrimitiveDatatypeDefinition.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimePrimitiveDatatypeDefinition.java
@@ -1,14 +1,32 @@
package ca.uhn.fhir.context;
+import static org.apache.commons.lang3.StringUtils.*;
+
import java.util.Map;
import ca.uhn.fhir.model.api.IElement;
import ca.uhn.fhir.model.api.IPrimitiveDatatype;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.ResourceDef;
-public class RuntimePrimitiveDatatypeDefinition extends BaseRuntimeElementDefinition>{
+public class RuntimePrimitiveDatatypeDefinition extends BaseRuntimeElementDefinition> implements IRuntimeDatatypeDefinition {
- public RuntimePrimitiveDatatypeDefinition(String theName, Class extends IPrimitiveDatatype>> theImplementingClass) {
- super(theName, theImplementingClass);
+ private boolean mySpecialization;
+
+ public RuntimePrimitiveDatatypeDefinition(DatatypeDef theDef, Class extends IPrimitiveDatatype>> theImplementingClass) {
+ super(theDef.name(), theImplementingClass);
+
+ String resourceName = theDef.name();
+ if (isBlank(resourceName)) {
+ throw new ConfigurationException("Resource type @" + ResourceDef.class.getSimpleName() + " annotation contains no resource name: " + theImplementingClass.getCanonicalName());
+ }
+
+ mySpecialization = theDef.isSpecialization();
+ }
+
+ @Override
+ public boolean isSpecialization() {
+ return mySpecialization;
}
@Override
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeResourceBlockDefinition.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeResourceBlockDefinition.java
index e5f892aa774..f3e5ca27796 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeResourceBlockDefinition.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeResourceBlockDefinition.java
@@ -1,6 +1,5 @@
package ca.uhn.fhir.context;
-import ca.uhn.fhir.context.BaseRuntimeElementDefinition.ChildTypeEnum;
import ca.uhn.fhir.model.api.IResourceBlock;
public class RuntimeResourceBlockDefinition extends BaseRuntimeElementCompositeDefinition {
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeResourceReferenceDefinition.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeResourceReferenceDefinition.java
index 64955c5f955..6571a35fe8c 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeResourceReferenceDefinition.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeResourceReferenceDefinition.java
@@ -4,9 +4,9 @@ import java.util.HashMap;
import java.util.List;
import java.util.Map;
+import ca.uhn.fhir.model.api.BaseResourceReference;
import ca.uhn.fhir.model.api.IElement;
import ca.uhn.fhir.model.api.IResource;
-import ca.uhn.fhir.model.api.BaseResourceReference;
public class RuntimeResourceReferenceDefinition extends BaseRuntimeElementDefinition {
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseBundle.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseBundle.java
index 63b275d6c1d..b6509c3d492 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseBundle.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseBundle.java
@@ -3,7 +3,7 @@ package ca.uhn.fhir.model.api;
import ca.uhn.fhir.model.primitive.StringDt;
import ca.uhn.fhir.util.ElementUtil;
-public class BaseBundle implements IElement {
+public class BaseBundle extends BaseElement implements IElement {
private StringDt myAuthorName;
private StringDt myAuthorUri;
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseElement.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseElement.java
index e87f2a4ae83..615dc375316 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseElement.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseElement.java
@@ -24,10 +24,10 @@ public abstract class BaseElement implements IElement, ISupportsUndeclaredExtens
return Collections.unmodifiableList(retVal);
}
-// @Override
-// public IdDt getId() {
-// return myId;
-// }
+ @Override
+ public IdDt getId() {
+ return myId;
+ }
@Override
public List getUndeclaredExtensions() {
@@ -67,9 +67,9 @@ public abstract class BaseElement implements IElement, ISupportsUndeclaredExtens
return true;
}
-// @Override
-// public void setId(IdDt theId) {
-// myId = theId;
-// }
+ @Override
+ public void setId(IdDt theId) {
+ myId = theId;
+ }
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseResourceReference.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseResourceReference.java
index e5c851c3a4c..3907304827c 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseResourceReference.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/BaseResourceReference.java
@@ -16,8 +16,8 @@ import ca.uhn.fhir.rest.client.api.IRestfulClient;
public abstract class BaseResourceReference extends BaseElement {
- private IResource myResource;
private static final org.slf4j.Logger ourLog = org.slf4j.LoggerFactory.getLogger(BaseResourceReference.class);
+ private IResource myResource;
/**
* Gets the value(s) for reference (Relative, internal or absolute URL reference). creating it if it does not exist. Will not return null
.
@@ -30,6 +30,23 @@ public abstract class BaseResourceReference extends BaseElement {
*/
public abstract StringDt getReference();
+ /**
+ * Gets the actual loaded and parsed resource instance, if it is already present. This
+ * method will return the resource instance only if it has previously been loaded using
+ * {@link #loadResource(IRestfulClient)} or it was contained within the resource containing
+ * this resource.
+ *
+ * @see See {@link #loadResource(IRestfulClient)}
+ * @see See the FHIR specification section on 2.2.2 Search Parameter Types
+ * for information on the token format
+ */
+ public void setValuesAsQueryTokens(List theParameters);
+
+ /**
+ * Returns the value of this type using the token format. This
+ * format is used in HTTP queries as a parameter format.
+ *
+ * @see See FHIR specification
+ * 2.2.2 Search Parameter Types
+ * for information on the token format
+ */
+ public List getValuesAsQueryTokens();
+
+
+}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/ValueSetRegistry.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/ValueSetRegistry.java
index df02b0b7cf4..92cbccb80a4 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/ValueSetRegistry.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/ValueSetRegistry.java
@@ -1,7 +1,5 @@
package ca.uhn.fhir.model.api;
-import java.util.HashMap;
-import java.util.Map;
public abstract class ValueSetRegistry {
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/annotation/DatatypeDef.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/annotation/DatatypeDef.java
index 19d4fdfd4a5..9a005ecdaf6 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/annotation/DatatypeDef.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/api/annotation/DatatypeDef.java
@@ -5,10 +5,25 @@ import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
+import ca.uhn.fhir.model.primitive.BoundCodeDt;
+import ca.uhn.fhir.model.primitive.CodeDt;
+
@Retention(RetentionPolicy.RUNTIME)
@Target(value= {ElementType.TYPE})
public @interface DatatypeDef {
+ /**
+ * The defined name of this datatype
+ */
String name();
+ /**
+ * Set this to true (default is false) for any types that are
+ * really only a specialization of another type. For example,
+ * {@link BoundCodeDt} is really just a specific type of
+ * {@link CodeDt} and not a separate datatype, so it should
+ * have this set to true.
+ */
+ boolean isSpecialization() default false;
+
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/AddressDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/AddressDt.java
index 9159d021fd9..e9f886d3335 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/AddressDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/AddressDt.java
@@ -16,12 +16,16 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.dstu.valueset.AddressUseEnum;
+import ca.uhn.fhir.model.primitive.BoundCodeDt;
+import ca.uhn.fhir.model.primitive.CodeDt;
+import ca.uhn.fhir.model.primitive.StringDt;
/**
* HAPI/FHIR Address Datatype
@@ -61,7 +65,7 @@ public class AddressDt
shortDefinition="Street name, number, direction & P.O. Box etc",
formalDefinition="This component contains the house number, apartment number, street name, street direction, P.O. Box number, delivery hints, and similar address information"
)
- private List myLine;
+ private java.util.List myLine;
@Child(name="city", type=StringDt.class, order=3, min=0, max=1)
@Description(
@@ -103,6 +107,11 @@ public class AddressDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myUse, myText, myLine, myCity, myState, myZip, myCountry, myPeriod);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myUse, myText, myLine, myCity, myState, myZip, myCountry, myPeriod);
+ }
+
/**
* Gets the value(s) for use (home | work | temp | old - purpose of this address).
@@ -200,9 +209,9 @@ public class AddressDt
* This component contains the house number, apartment number, street name, street direction, P.O. Box number, delivery hints, and similar address information
*
*/
- public List getLine() {
+ public java.util.List getLine() {
if (myLine == null) {
- myLine = new ArrayList();
+ myLine = new java.util.ArrayList();
}
return myLine;
}
@@ -215,7 +224,7 @@ public class AddressDt
* This component contains the house number, apartment number, street name, street direction, P.O. Box number, delivery hints, and similar address information
*
*/
- public void setLine(List theValue) {
+ public void setLine(java.util.List theValue) {
myLine = theValue;
}
@@ -243,7 +252,7 @@ public class AddressDt
*/
public void addLine( String theString) {
if (myLine == null) {
- myLine = new ArrayList();
+ myLine = new java.util.ArrayList();
}
myLine.add(new StringDt(theString));
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/AttachmentDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/AttachmentDt.java
index e31060e9eba..a15a11ec18c 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/AttachmentDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/AttachmentDt.java
@@ -16,12 +16,17 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.primitive.Base64BinaryDt;
+import ca.uhn.fhir.model.primitive.CodeDt;
+import ca.uhn.fhir.model.primitive.IntegerDt;
+import ca.uhn.fhir.model.primitive.StringDt;
+import ca.uhn.fhir.model.primitive.UriDt;
/**
* HAPI/FHIR Attachment Datatype
@@ -96,6 +101,11 @@ public class AttachmentDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myContentType, myLanguage, myData, myUrl, mySize, myHash, myTitle);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myContentType, myLanguage, myData, myUrl, mySize, myHash, myTitle);
+ }
+
/**
* Gets the value(s) for contentType (Mime type of the content, with charset etc.).
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/CodeableConceptDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/CodeableConceptDt.java
index 2b363a3ca2d..6e9fb6fc982 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/CodeableConceptDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/CodeableConceptDt.java
@@ -16,12 +16,13 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.primitive.StringDt;
/**
* HAPI/FHIR CodeableConcept Datatype
@@ -47,7 +48,7 @@ public class CodeableConceptDt
shortDefinition="Code defined by a terminology system",
formalDefinition="A reference to a code defined by a terminology system"
)
- private List myCoding;
+ private java.util.List myCoding;
@Child(name="text", type=StringDt.class, order=1, min=0, max=1)
@Description(
@@ -61,6 +62,11 @@ public class CodeableConceptDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myCoding, myText);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myCoding, myText);
+ }
+
/**
* Gets the value(s) for coding (Code defined by a terminology system).
@@ -72,9 +78,9 @@ public class CodeableConceptDt
* A reference to a code defined by a terminology system
*
*/
- public List getCoding() {
+ public java.util.List getCoding() {
if (myCoding == null) {
- myCoding = new ArrayList();
+ myCoding = new java.util.ArrayList();
}
return myCoding;
}
@@ -87,7 +93,7 @@ public class CodeableConceptDt
* A reference to a code defined by a terminology system
*
*/
- public void setCoding(List theValue) {
+ public void setCoding(java.util.List theValue) {
myCoding = theValue;
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/CodingDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/CodingDt.java
index 028ea184375..d4a27762547 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/CodingDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/CodingDt.java
@@ -16,12 +16,17 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.IQueryParameterType;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.primitive.BooleanDt;
+import ca.uhn.fhir.model.primitive.CodeDt;
+import ca.uhn.fhir.model.primitive.StringDt;
+import ca.uhn.fhir.model.primitive.UriDt;
/**
* HAPI/FHIR Coding Datatype
@@ -39,8 +44,22 @@ import ca.uhn.fhir.model.dstu.resource.*;
*/
@DatatypeDef(name="Coding")
public class CodingDt
- extends BaseElement implements ICompositeDatatype {
+ extends BaseElement implements ICompositeDatatype , IQueryParameterType {
+ /**
+ * Creates a new Coding
+ */
+ public CodingDt() {
+ // nothing
+ }
+
+ /**
+ * Creates a new Coding with the given system and code
+ */
+ public CodingDt(String theSystem, String theCode) {
+ setSystem(theSystem);
+ setCode(theCode);
+ }
@Child(name="system", type=UriDt.class, order=0, min=0, max=1)
@Description(
@@ -78,7 +97,7 @@ public class CodingDt
private BooleanDt myPrimary;
@Child(name="valueSet", order=5, min=0, max=1, type={
- ValueSet.class,
+ ca.uhn.fhir.model.dstu.resource.ValueSet.class,
})
@Description(
shortDefinition="Set this coding was chosen from",
@@ -91,6 +110,11 @@ public class CodingDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( mySystem, myVersion, myCode, myDisplay, myPrimary, myValueSet);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( mySystem, myVersion, myCode, myDisplay, myPrimary, myValueSet);
+ }
+
/**
* Gets the value(s) for system (Identity of the terminology system).
@@ -339,6 +363,43 @@ public class CodingDt
+ /**
+ * Returns true if this
Coding has the same {@link CodingDt#getCode() Code}
+ * and {@link CodingDt#getSystem() system} (as compared by simple equals comparison).
+ * Does not compare other Codes (e.g. {@link CodingDt#getUse() use}) or any extensions.
+ */
+ public boolean matchesSystemAndCode(CodingDt theCoding) {
+ if (theCoding == null) {
+ return false;
+ }
+ return getCode().equals(theCoding.getCode()) && getSystem().equals(theCoding.getSystem());
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public String getValueAsQueryToken() {
+ if (org.apache.commons.lang3.StringUtils.isNotBlank(getSystem().getValueAsString())) {
+ return getSystem().getValueAsString() + '|' + getCode().getValueAsString();
+ } else {
+ return getCode().getValueAsString();
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public void setValueAsQueryToken(String theParameter) {
+ int barIndex = theParameter.indexOf('|');
+ if (barIndex != -1) {
+ setSystem(new UriDt(theParameter.substring(0, barIndex)));
+ setCode(theParameter.substring(barIndex + 1));
+ } else {
+ setCode(theParameter);
+ }
+ }
}
\ No newline at end of file
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ContactDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ContactDt.java
index 5daf48837b3..ec562036f6f 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ContactDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ContactDt.java
@@ -16,12 +16,17 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.dstu.valueset.ContactSystemEnum;
+import ca.uhn.fhir.model.dstu.valueset.ContactUseEnum;
+import ca.uhn.fhir.model.primitive.BoundCodeDt;
+import ca.uhn.fhir.model.primitive.CodeDt;
+import ca.uhn.fhir.model.primitive.StringDt;
/**
* HAPI/FHIR Contact Datatype
@@ -75,6 +80,11 @@ public class ContactDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( mySystem, myValue, myUse, myPeriod);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( mySystem, myValue, myUse, myPeriod);
+ }
+
/**
* Gets the value(s) for system (phone | fax | email | url).
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/DurationDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/DurationDt.java
index f7b73c42538..a9e415401e3 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/DurationDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/DurationDt.java
@@ -1,5 +1,8 @@
package ca.uhn.fhir.model.dstu.composite;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+
+@DatatypeDef(name = "duration")
public class DurationDt extends QuantityDt {
// TODO: implement restricions
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/HumanNameDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/HumanNameDt.java
index 282b1379f71..b55ecab1ce9 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/HumanNameDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/HumanNameDt.java
@@ -16,12 +16,16 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.dstu.valueset.NameUseEnum;
+import ca.uhn.fhir.model.primitive.BoundCodeDt;
+import ca.uhn.fhir.model.primitive.CodeDt;
+import ca.uhn.fhir.model.primitive.StringDt;
/**
* HAPI/FHIR HumanName Datatype
@@ -61,28 +65,28 @@ public class HumanNameDt
shortDefinition="Family name (often called 'Surname')",
formalDefinition="The part of a name that links to the genealogy. In some cultures (e.g. Eritrea) the family name of a son is the first name of his father."
)
- private List myFamily;
+ private java.util.List myFamily;
@Child(name="given", type=StringDt.class, order=3, min=0, max=Child.MAX_UNLIMITED)
@Description(
shortDefinition="Given names (not always 'first'). Includes middle names",
formalDefinition="Given name"
)
- private List myGiven;
+ private java.util.List myGiven;
@Child(name="prefix", type=StringDt.class, order=4, min=0, max=Child.MAX_UNLIMITED)
@Description(
shortDefinition="Parts that come before the name",
formalDefinition="Part of the name that is acquired as a title due to academic, legal, employment or nobility status, etc. and that appears at the start of the name"
)
- private List myPrefix;
+ private java.util.List myPrefix;
@Child(name="suffix", type=StringDt.class, order=5, min=0, max=Child.MAX_UNLIMITED)
@Description(
shortDefinition="Parts that come after the name",
formalDefinition="Part of the name that is acquired as a title due to academic, legal, employment or nobility status, etc. and that appears at the end of the name"
)
- private List mySuffix;
+ private java.util.List mySuffix;
@Child(name="period", type=PeriodDt.class, order=6, min=0, max=1)
@Description(
@@ -96,6 +100,11 @@ public class HumanNameDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myUse, myText, myFamily, myGiven, myPrefix, mySuffix, myPeriod);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myUse, myText, myFamily, myGiven, myPrefix, mySuffix, myPeriod);
+ }
+
/**
* Gets the value(s) for use (usual | official | temp | nickname | anonymous | old | maiden).
@@ -193,9 +202,9 @@ public class HumanNameDt
* The part of a name that links to the genealogy. In some cultures (e.g. Eritrea) the family name of a son is the first name of his father.
*
*/
- public List getFamily() {
+ public java.util.List getFamily() {
if (myFamily == null) {
- myFamily = new ArrayList();
+ myFamily = new java.util.ArrayList();
}
return myFamily;
}
@@ -208,7 +217,7 @@ public class HumanNameDt
* The part of a name that links to the genealogy. In some cultures (e.g. Eritrea) the family name of a son is the first name of his father.
*
*/
- public void setFamily(List theValue) {
+ public void setFamily(java.util.List theValue) {
myFamily = theValue;
}
@@ -236,7 +245,7 @@ public class HumanNameDt
*/
public void addFamily( String theString) {
if (myFamily == null) {
- myFamily = new ArrayList();
+ myFamily = new java.util.ArrayList();
}
myFamily.add(new StringDt(theString));
}
@@ -252,9 +261,9 @@ public class HumanNameDt
* Given name
*
*/
- public List getGiven() {
+ public java.util.List getGiven() {
if (myGiven == null) {
- myGiven = new ArrayList();
+ myGiven = new java.util.ArrayList();
}
return myGiven;
}
@@ -267,7 +276,7 @@ public class HumanNameDt
* Given name
*
*/
- public void setGiven(List theValue) {
+ public void setGiven(java.util.List theValue) {
myGiven = theValue;
}
@@ -295,7 +304,7 @@ public class HumanNameDt
*/
public void addGiven( String theString) {
if (myGiven == null) {
- myGiven = new ArrayList();
+ myGiven = new java.util.ArrayList();
}
myGiven.add(new StringDt(theString));
}
@@ -311,9 +320,9 @@ public class HumanNameDt
* Part of the name that is acquired as a title due to academic, legal, employment or nobility status, etc. and that appears at the start of the name
*
*/
- public List getPrefix() {
+ public java.util.List getPrefix() {
if (myPrefix == null) {
- myPrefix = new ArrayList();
+ myPrefix = new java.util.ArrayList();
}
return myPrefix;
}
@@ -326,7 +335,7 @@ public class HumanNameDt
* Part of the name that is acquired as a title due to academic, legal, employment or nobility status, etc. and that appears at the start of the name
*
*/
- public void setPrefix(List theValue) {
+ public void setPrefix(java.util.List theValue) {
myPrefix = theValue;
}
@@ -354,7 +363,7 @@ public class HumanNameDt
*/
public void addPrefix( String theString) {
if (myPrefix == null) {
- myPrefix = new ArrayList();
+ myPrefix = new java.util.ArrayList();
}
myPrefix.add(new StringDt(theString));
}
@@ -370,9 +379,9 @@ public class HumanNameDt
* Part of the name that is acquired as a title due to academic, legal, employment or nobility status, etc. and that appears at the end of the name
*
*/
- public List getSuffix() {
+ public java.util.List getSuffix() {
if (mySuffix == null) {
- mySuffix = new ArrayList();
+ mySuffix = new java.util.ArrayList();
}
return mySuffix;
}
@@ -385,7 +394,7 @@ public class HumanNameDt
* Part of the name that is acquired as a title due to academic, legal, employment or nobility status, etc. and that appears at the end of the name
*
*/
- public void setSuffix(List theValue) {
+ public void setSuffix(java.util.List theValue) {
mySuffix = theValue;
}
@@ -413,7 +422,7 @@ public class HumanNameDt
*/
public void addSuffix( String theString) {
if (mySuffix == null) {
- mySuffix = new ArrayList();
+ mySuffix = new java.util.ArrayList();
}
mySuffix.add(new StringDt(theString));
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/IdentifierDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/IdentifierDt.java
index 1cb8b3c8950..56155881895 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/IdentifierDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/IdentifierDt.java
@@ -16,12 +16,18 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.IQueryParameterType;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.dstu.valueset.IdentifierUseEnum;
+import ca.uhn.fhir.model.primitive.BoundCodeDt;
+import ca.uhn.fhir.model.primitive.CodeDt;
+import ca.uhn.fhir.model.primitive.StringDt;
+import ca.uhn.fhir.model.primitive.UriDt;
/**
* HAPI/FHIR Identifier Datatype
@@ -92,7 +98,7 @@ public class IdentifierDt
private PeriodDt myPeriod;
@Child(name="assigner", order=5, min=0, max=1, type={
- Organization.class,
+ ca.uhn.fhir.model.dstu.resource.Organization.class,
})
@Description(
shortDefinition="Organization that issued id (may be just text)",
@@ -105,6 +111,11 @@ public class IdentifierDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myUse, myLabel, mySystem, myValue, myPeriod, myAssigner);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myUse, myLabel, mySystem, myValue, myPeriod, myAssigner);
+ }
+
/**
* Gets the value(s) for use (usual | official | temp | secondary (If known)).
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/NarrativeDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/NarrativeDt.java
index 474577074dc..29eaf8b01b6 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/NarrativeDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/NarrativeDt.java
@@ -16,12 +16,17 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
+import java.util.List;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.dstu.valueset.NarrativeStatusEnum;
+import ca.uhn.fhir.model.primitive.BoundCodeDt;
+import ca.uhn.fhir.model.primitive.CodeDt;
+import ca.uhn.fhir.model.primitive.XhtmlDt;
/**
* HAPI/FHIR Narrative Datatype
@@ -51,6 +56,11 @@ public class NarrativeDt extends BaseElement implements ICompositeDatatype {
return ca.uhn.fhir.util.ElementUtil.isEmpty( myStatus, myDiv );
}
+ @Override
+ public List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myStatus, myDiv );
+ }
+
/**
* Gets the value(s) for status (generated | extensions | additional).
* creating it if it does
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/PeriodDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/PeriodDt.java
index b3bd50b223f..3ee4b5cbfcc 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/PeriodDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/PeriodDt.java
@@ -16,12 +16,16 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import java.util.Date;
+
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.TemporalPrecisionEnum;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.primitive.DateTimeDt;
/**
* HAPI/FHIR Period Datatype
@@ -61,6 +65,11 @@ public class PeriodDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myStart, myEnd);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myStart, myEnd);
+ }
+
/**
* Gets the value(s) for start (Starting time with inclusive boundary).
@@ -100,8 +109,8 @@ public class PeriodDt
* The start of the period. The boundary is inclusive.
*
*/
- public void setStartWithSecondsPrecision( Date theDate) {
- myStart = new DateTimeDt(theDate);
+ public void setStart( Date theDate, TemporalPrecisionEnum thePrecision) {
+ myStart = new DateTimeDt(theDate, thePrecision);
}
/**
@@ -112,8 +121,8 @@ public class PeriodDt
* The start of the period. The boundary is inclusive.
*
*/
- public void setStart( Date theDate, TemporalPrecisionEnum thePrecision) {
- myStart = new DateTimeDt(theDate, thePrecision);
+ public void setStartWithSecondsPrecision( Date theDate) {
+ myStart = new DateTimeDt(theDate);
}
@@ -155,8 +164,8 @@ public class PeriodDt
* The end of the period. If the end of the period is missing, it means that the period is ongoing
*
*/
- public void setEndWithSecondsPrecision( Date theDate) {
- myEnd = new DateTimeDt(theDate);
+ public void setEnd( Date theDate, TemporalPrecisionEnum thePrecision) {
+ myEnd = new DateTimeDt(theDate, thePrecision);
}
/**
@@ -167,8 +176,8 @@ public class PeriodDt
* The end of the period. If the end of the period is missing, it means that the period is ongoing
*
*/
- public void setEnd( Date theDate, TemporalPrecisionEnum thePrecision) {
- myEnd = new DateTimeDt(theDate, thePrecision);
+ public void setEndWithSecondsPrecision( Date theDate) {
+ myEnd = new DateTimeDt(theDate);
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/QuantityDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/QuantityDt.java
index 4e1a68a8fb6..4b07f34090a 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/QuantityDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/QuantityDt.java
@@ -16,12 +16,18 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.dstu.valueset.QuantityCompararatorEnum;
+import ca.uhn.fhir.model.primitive.BoundCodeDt;
+import ca.uhn.fhir.model.primitive.CodeDt;
+import ca.uhn.fhir.model.primitive.DecimalDt;
+import ca.uhn.fhir.model.primitive.StringDt;
+import ca.uhn.fhir.model.primitive.UriDt;
/**
* HAPI/FHIR Quantity Datatype
@@ -82,6 +88,11 @@ public class QuantityDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myValue, myComparator, myUnits, mySystem, myCode);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myValue, myComparator, myUnits, mySystem, myCode);
+ }
+
/**
* Gets the value(s) for value (Numerical value (with implicit precision)).
@@ -121,7 +132,7 @@ public class QuantityDt
* The value of the measured amount. The value includes an implicit precision in the presentation of the value
*
*/
- public void setValue( java.math.BigDecimal theValue) {
+ public void setValue( long theValue) {
myValue = new DecimalDt(theValue);
}
@@ -145,7 +156,7 @@ public class QuantityDt
* The value of the measured amount. The value includes an implicit precision in the presentation of the value
*
*/
- public void setValue( long theValue) {
+ public void setValue( java.math.BigDecimal theValue) {
myValue = new DecimalDt(theValue);
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/RangeDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/RangeDt.java
index 53f75792ad8..1cd873d6364 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/RangeDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/RangeDt.java
@@ -16,12 +16,12 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
/**
* HAPI/FHIR Range Datatype
@@ -61,6 +61,11 @@ public class RangeDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myLow, myHigh);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myLow, myHigh);
+ }
+
/**
* Gets the value(s) for low (Low limit).
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/RatioDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/RatioDt.java
index a4a7ea55260..e689cd42a60 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/RatioDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/RatioDt.java
@@ -16,12 +16,12 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
/**
* HAPI/FHIR Ratio Datatype
@@ -61,6 +61,11 @@ public class RatioDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myNumerator, myDenominator);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myNumerator, myDenominator);
+ }
+
/**
* Gets the value(s) for numerator (Numerator value).
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ResourceReferenceDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ResourceReferenceDt.java
index 46a73fc35c0..f38352de498 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ResourceReferenceDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ResourceReferenceDt.java
@@ -16,12 +16,13 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseResourceReference;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.primitive.StringDt;
/**
* HAPI/FHIR ResourceReference Datatype
@@ -61,6 +62,11 @@ public class ResourceReferenceDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myReference, myDisplay);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myReference, myDisplay);
+ }
+
/**
* Gets the value(s) for reference (Relative, internal or absolute URL reference).
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/SampledDataDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/SampledDataDt.java
index c4b4775e4f0..870a6531c07 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/SampledDataDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/SampledDataDt.java
@@ -16,12 +16,15 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.primitive.DecimalDt;
+import ca.uhn.fhir.model.primitive.IntegerDt;
+import ca.uhn.fhir.model.primitive.StringDt;
/**
* HAPI/FHIR SampledData Datatype
@@ -96,6 +99,11 @@ public class SampledDataDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myOrigin, myPeriod, myFactor, myLowerLimit, myUpperLimit, myDimensions, myData);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myOrigin, myPeriod, myFactor, myLowerLimit, myUpperLimit, myDimensions, myData);
+ }
+
/**
* Gets the value(s) for origin (Zero value and units).
@@ -166,7 +174,7 @@ public class SampledDataDt
* The length of time between sampling times, measured in milliseconds
*
*/
- public void setPeriod( java.math.BigDecimal theValue) {
+ public void setPeriod( long theValue) {
myPeriod = new DecimalDt(theValue);
}
@@ -190,7 +198,7 @@ public class SampledDataDt
* The length of time between sampling times, measured in milliseconds
*
*/
- public void setPeriod( long theValue) {
+ public void setPeriod( java.math.BigDecimal theValue) {
myPeriod = new DecimalDt(theValue);
}
@@ -233,7 +241,7 @@ public class SampledDataDt
* A correction factor that is applied to the sampled data points before they are added to the origin
*
*/
- public void setFactor( java.math.BigDecimal theValue) {
+ public void setFactor( long theValue) {
myFactor = new DecimalDt(theValue);
}
@@ -257,7 +265,7 @@ public class SampledDataDt
* A correction factor that is applied to the sampled data points before they are added to the origin
*
*/
- public void setFactor( long theValue) {
+ public void setFactor( java.math.BigDecimal theValue) {
myFactor = new DecimalDt(theValue);
}
@@ -300,7 +308,7 @@ public class SampledDataDt
* The lower limit of detection of the measured points. This is needed if any of the data points have the value \"L\" (lower than detection limit)
*
*/
- public void setLowerLimit( java.math.BigDecimal theValue) {
+ public void setLowerLimit( long theValue) {
myLowerLimit = new DecimalDt(theValue);
}
@@ -324,7 +332,7 @@ public class SampledDataDt
* The lower limit of detection of the measured points. This is needed if any of the data points have the value \"L\" (lower than detection limit)
*
*/
- public void setLowerLimit( long theValue) {
+ public void setLowerLimit( java.math.BigDecimal theValue) {
myLowerLimit = new DecimalDt(theValue);
}
@@ -367,7 +375,7 @@ public class SampledDataDt
* The upper limit of detection of the measured points. This is needed if any of the data points have the value \"U\" (higher than detection limit)
*
*/
- public void setUpperLimit( java.math.BigDecimal theValue) {
+ public void setUpperLimit( long theValue) {
myUpperLimit = new DecimalDt(theValue);
}
@@ -391,7 +399,7 @@ public class SampledDataDt
* The upper limit of detection of the measured points. This is needed if any of the data points have the value \"U\" (higher than detection limit)
*
*/
- public void setUpperLimit( long theValue) {
+ public void setUpperLimit( java.math.BigDecimal theValue) {
myUpperLimit = new DecimalDt(theValue);
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ScheduleDt.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ScheduleDt.java
index 94093399c8d..76fe3e56519 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ScheduleDt.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/composite/ScheduleDt.java
@@ -16,12 +16,24 @@
package ca.uhn.fhir.model.dstu.composite;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
-import ca.uhn.fhir.model.dstu.resource.*;
+import java.util.Date;
+
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.ICompositeDatatype;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.IResourceBlock;
+import ca.uhn.fhir.model.api.TemporalPrecisionEnum;
+import ca.uhn.fhir.model.api.annotation.Block;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.DatatypeDef;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.dstu.valueset.EventTimingEnum;
+import ca.uhn.fhir.model.dstu.valueset.UnitsOfTimeEnum;
+import ca.uhn.fhir.model.primitive.BoundCodeDt;
+import ca.uhn.fhir.model.primitive.CodeDt;
+import ca.uhn.fhir.model.primitive.DateTimeDt;
+import ca.uhn.fhir.model.primitive.DecimalDt;
+import ca.uhn.fhir.model.primitive.IntegerDt;
/**
* HAPI/FHIR Schedule Datatype
@@ -47,7 +59,7 @@ public class ScheduleDt
shortDefinition="When the event occurs",
formalDefinition="Identifies specific time periods when the event should occur"
)
- private List myEvent;
+ private java.util.List myEvent;
@Child(name="repeat", order=1, min=0, max=1)
@Description(
@@ -61,6 +73,11 @@ public class ScheduleDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myEvent, myRepeat);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myEvent, myRepeat);
+ }
+
/**
* Gets the value(s) for event (When the event occurs).
@@ -72,9 +89,9 @@ public class ScheduleDt
* Identifies specific time periods when the event should occur
*
*/
- public List getEvent() {
+ public java.util.List getEvent() {
if (myEvent == null) {
- myEvent = new ArrayList();
+ myEvent = new java.util.ArrayList();
}
return myEvent;
}
@@ -87,7 +104,7 @@ public class ScheduleDt
* Identifies specific time periods when the event should occur
*
*/
- public void setEvent(List theValue) {
+ public void setEvent(java.util.List theValue) {
myEvent = theValue;
}
@@ -195,6 +212,11 @@ public class ScheduleDt
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myFrequency, myWhen, myDuration, myUnits, myCount, myEnd);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myFrequency, myWhen, myDuration, myUnits, myCount, myEnd);
+ }
+
/**
* Gets the value(s) for frequency (Event occurs frequency times per duration).
@@ -320,7 +342,7 @@ public class ScheduleDt
* How long each repetition should last
*
*/
- public void setDuration( java.math.BigDecimal theValue) {
+ public void setDuration( long theValue) {
myDuration = new DecimalDt(theValue);
}
@@ -344,7 +366,7 @@ public class ScheduleDt
* How long each repetition should last
*
*/
- public void setDuration( long theValue) {
+ public void setDuration( java.math.BigDecimal theValue) {
myDuration = new DecimalDt(theValue);
}
@@ -473,8 +495,8 @@ public class ScheduleDt
* When to stop repeating the schedule
*
*/
- public void setEndWithSecondsPrecision( Date theDate) {
- myEnd = new DateTimeDt(theDate);
+ public void setEnd( Date theDate, TemporalPrecisionEnum thePrecision) {
+ myEnd = new DateTimeDt(theDate, thePrecision);
}
/**
@@ -485,8 +507,8 @@ public class ScheduleDt
* When to stop repeating the schedule
*
*/
- public void setEnd( Date theDate, TemporalPrecisionEnum thePrecision) {
- myEnd = new DateTimeDt(theDate, thePrecision);
+ public void setEndWithSecondsPrecision( Date theDate) {
+ myEnd = new DateTimeDt(theDate);
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/Binary.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/Binary.java
index 3b2479f76bf..381903341d8 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/Binary.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/Binary.java
@@ -1,10 +1,14 @@
package ca.uhn.fhir.model.dstu.resource;
+import java.util.List;
+
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.IElement;
import ca.uhn.fhir.model.api.IResource;
import ca.uhn.fhir.model.api.annotation.ResourceDef;
@ResourceDef(name="Binary", profile="http://hl7.org/fhir/profiles/Binary", id="binary")
-public class Binary implements IResource {
+public class Binary extends BaseElement implements IResource {
// TODO: implement binary
@@ -13,4 +17,10 @@ public class Binary implements IResource {
return true;
}
+ @Override
+ public List getAllPopulatedChildElements() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
}
diff --git a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/Conformance.java b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/Conformance.java
index ddc2afdbe81..38a86b27c19 100644
--- a/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/Conformance.java
+++ b/hapi-fhir-base/src/main/java/ca/uhn/fhir/model/dstu/resource/Conformance.java
@@ -16,12 +16,44 @@
package ca.uhn.fhir.model.dstu.resource;
-import java.util.*;
-import ca.uhn.fhir.model.api.*;
-import ca.uhn.fhir.model.api.annotation.*;
-import ca.uhn.fhir.model.primitive.*;
-import ca.uhn.fhir.model.dstu.composite.*;
-import ca.uhn.fhir.model.dstu.valueset.*;
+
+import java.util.Date;
+
+import ca.uhn.fhir.model.api.BaseElement;
+import ca.uhn.fhir.model.api.BaseResource;
+import ca.uhn.fhir.model.api.IElement;
+import ca.uhn.fhir.model.api.IResource;
+import ca.uhn.fhir.model.api.IResourceBlock;
+import ca.uhn.fhir.model.api.TemporalPrecisionEnum;
+import ca.uhn.fhir.model.api.annotation.Block;
+import ca.uhn.fhir.model.api.annotation.Child;
+import ca.uhn.fhir.model.api.annotation.Description;
+import ca.uhn.fhir.model.api.annotation.ResourceDef;
+import ca.uhn.fhir.model.dstu.composite.CodeableConceptDt;
+import ca.uhn.fhir.model.dstu.composite.CodingDt;
+import ca.uhn.fhir.model.dstu.composite.ContactDt;
+import ca.uhn.fhir.model.dstu.composite.ResourceReferenceDt;
+import ca.uhn.fhir.model.dstu.valueset.ConformanceEventModeEnum;
+import ca.uhn.fhir.model.dstu.valueset.ConformanceStatementStatusEnum;
+import ca.uhn.fhir.model.dstu.valueset.DocumentModeEnum;
+import ca.uhn.fhir.model.dstu.valueset.MessageSignificanceCategoryEnum;
+import ca.uhn.fhir.model.dstu.valueset.ResourceTypeEnum;
+import ca.uhn.fhir.model.dstu.valueset.RestfulConformanceModeEnum;
+import ca.uhn.fhir.model.dstu.valueset.RestfulOperationSystemEnum;
+import ca.uhn.fhir.model.dstu.valueset.RestfulOperationTypeEnum;
+import ca.uhn.fhir.model.dstu.valueset.RestfulSecurityServiceEnum;
+import ca.uhn.fhir.model.dstu.valueset.SearchParamTypeEnum;
+import ca.uhn.fhir.model.primitive.Base64BinaryDt;
+import ca.uhn.fhir.model.primitive.BooleanDt;
+import ca.uhn.fhir.model.primitive.BoundCodeDt;
+import ca.uhn.fhir.model.primitive.BoundCodeableConceptDt;
+import ca.uhn.fhir.model.primitive.CodeDt;
+import ca.uhn.fhir.model.primitive.DateTimeDt;
+import ca.uhn.fhir.model.primitive.IdDt;
+import ca.uhn.fhir.model.primitive.IntegerDt;
+import ca.uhn.fhir.model.primitive.StringDt;
+import ca.uhn.fhir.model.primitive.UriDt;
+
/**
* HAPI/FHIR Conformance Resource
@@ -234,7 +266,7 @@ public class Conformance extends BaseResource implements IResource {
shortDefinition="Contacts for Organization",
formalDefinition="Contacts for Organization relevant to this conformance statement. The contacts may be a website, email, phone numbers, etc."
)
- private List myTelecom;
+ private java.util.List myTelecom;
@Child(name="description", type=StringDt.class, order=5, min=0, max=1)
@Description(
@@ -297,43 +329,48 @@ public class Conformance extends BaseResource implements IResource {
shortDefinition="formats supported (xml | json | mime type)",
formalDefinition="A list of the formats supported by this implementation"
)
- private List myFormat;
+ private java.util.List myFormat;
@Child(name="profile", order=14, min=0, max=Child.MAX_UNLIMITED, type={
- Profile.class,
+ ca.uhn.fhir.model.dstu.resource.Profile.class,
})
@Description(
shortDefinition="Profiles supported by the system",
formalDefinition="A list of profiles supported by the system. For a server, \"supported by the system\" means the system hosts/produces a set of recourses, conformant to a particular profile, and allows its clients to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile."
)
- private List myProfile;
+ private java.util.List myProfile;
@Child(name="rest", order=15, min=0, max=Child.MAX_UNLIMITED)
@Description(
shortDefinition="If the endpoint is a RESTful one",
formalDefinition="A definition of the restful capabilities of the solution, if any"
)
- private List myRest;
+ private java.util.List myRest;
@Child(name="messaging", order=16, min=0, max=Child.MAX_UNLIMITED)
@Description(
shortDefinition="If messaging is supported",
formalDefinition="A description of the messaging capabilities of the solution"
)
- private List myMessaging;
+ private java.util.List myMessaging;
@Child(name="document", order=17, min=0, max=Child.MAX_UNLIMITED)
@Description(
shortDefinition="Document definition",
formalDefinition="A document definition"
)
- private List myDocument;
+ private java.util.List myDocument;
@Override
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myIdentifier, myVersion, myName, myPublisher, myTelecom, myDescription, myStatus, myExperimental, myDate, mySoftware, myImplementation, myFhirVersion, myAcceptUnknown, myFormat, myProfile, myRest, myMessaging, myDocument);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myIdentifier, myVersion, myName, myPublisher, myTelecom, myDescription, myStatus, myExperimental, myDate, mySoftware, myImplementation, myFhirVersion, myAcceptUnknown, myFormat, myProfile, myRest, myMessaging, myDocument);
+ }
+
/**
* Gets the value(s) for identifier (Logical id to reference this statement).
@@ -517,9 +554,9 @@ public class Conformance extends BaseResource implements IResource {
* Contacts for Organization relevant to this conformance statement. The contacts may be a website, email, phone numbers, etc.
*
*/
- public List getTelecom() {
+ public java.util.List getTelecom() {
if (myTelecom == null) {
- myTelecom = new ArrayList();
+ myTelecom = new java.util.ArrayList();
}
return myTelecom;
}
@@ -532,7 +569,7 @@ public class Conformance extends BaseResource implements IResource {
* Contacts for Organization relevant to this conformance statement. The contacts may be a website, email, phone numbers, etc.
*
*/
- public void setTelecom(List theValue) {
+ public void setTelecom(java.util.List theValue) {
myTelecom = theValue;
}
@@ -718,8 +755,8 @@ public class Conformance extends BaseResource implements IResource {
* The date when the conformance statement was published
*
*/
- public void setDateWithSecondsPrecision( Date theDate) {
- myDate = new DateTimeDt(theDate);
+ public void setDate( Date theDate, TemporalPrecisionEnum thePrecision) {
+ myDate = new DateTimeDt(theDate, thePrecision);
}
/**
@@ -730,8 +767,8 @@ public class Conformance extends BaseResource implements IResource {
* The date when the conformance statement was published
*
*/
- public void setDate( Date theDate, TemporalPrecisionEnum thePrecision) {
- myDate = new DateTimeDt(theDate, thePrecision);
+ public void setDateWithSecondsPrecision( Date theDate) {
+ myDate = new DateTimeDt(theDate);
}
@@ -893,9 +930,9 @@ public class Conformance extends BaseResource implements IResource {
* A list of the formats supported by this implementation
*
*/
- public List getFormat() {
+ public java.util.List getFormat() {
if (myFormat == null) {
- myFormat = new ArrayList();
+ myFormat = new java.util.ArrayList();
}
return myFormat;
}
@@ -908,7 +945,7 @@ public class Conformance extends BaseResource implements IResource {
* A list of the formats supported by this implementation
*
*/
- public void setFormat(List theValue) {
+ public void setFormat(java.util.List theValue) {
myFormat = theValue;
}
@@ -936,7 +973,7 @@ public class Conformance extends BaseResource implements IResource {
*/
public void addFormat( String theCode) {
if (myFormat == null) {
- myFormat = new ArrayList();
+ myFormat = new java.util.ArrayList();
}
myFormat.add(new CodeDt(theCode));
}
@@ -952,9 +989,9 @@ public class Conformance extends BaseResource implements IResource {
* A list of profiles supported by the system. For a server, \"supported by the system\" means the system hosts/produces a set of recourses, conformant to a particular profile, and allows its clients to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile.
*
*/
- public List getProfile() {
+ public java.util.List getProfile() {
if (myProfile == null) {
- myProfile = new ArrayList();
+ myProfile = new java.util.ArrayList();
}
return myProfile;
}
@@ -967,7 +1004,7 @@ public class Conformance extends BaseResource implements IResource {
* A list of profiles supported by the system. For a server, \"supported by the system\" means the system hosts/produces a set of recourses, conformant to a particular profile, and allows its clients to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile.
*
*/
- public void setProfile(List theValue) {
+ public void setProfile(java.util.List theValue) {
myProfile = theValue;
}
@@ -983,9 +1020,9 @@ public class Conformance extends BaseResource implements IResource {
* A definition of the restful capabilities of the solution, if any
*
*/
- public List getRest() {
+ public java.util.List getRest() {
if (myRest == null) {
- myRest = new ArrayList();
+ myRest = new java.util.ArrayList();
}
return myRest;
}
@@ -998,7 +1035,7 @@ public class Conformance extends BaseResource implements IResource {
* A definition of the restful capabilities of the solution, if any
*
*/
- public void setRest(List theValue) {
+ public void setRest(java.util.List theValue) {
myRest = theValue;
}
@@ -1027,9 +1064,9 @@ public class Conformance extends BaseResource implements IResource {
* A description of the messaging capabilities of the solution
*
*/
- public List getMessaging() {
+ public java.util.List getMessaging() {
if (myMessaging == null) {
- myMessaging = new ArrayList();
+ myMessaging = new java.util.ArrayList();
}
return myMessaging;
}
@@ -1042,7 +1079,7 @@ public class Conformance extends BaseResource implements IResource {
* A description of the messaging capabilities of the solution
*
*/
- public void setMessaging(List theValue) {
+ public void setMessaging(java.util.List theValue) {
myMessaging = theValue;
}
@@ -1071,9 +1108,9 @@ public class Conformance extends BaseResource implements IResource {
* A document definition
*
*/
- public List getDocument() {
+ public java.util.List getDocument() {
if (myDocument == null) {
- myDocument = new ArrayList();
+ myDocument = new java.util.ArrayList();
}
return myDocument;
}
@@ -1086,7 +1123,7 @@ public class Conformance extends BaseResource implements IResource {
* A document definition
*
*/
- public void setDocument(List theValue) {
+ public void setDocument(java.util.List theValue) {
myDocument = theValue;
}
@@ -1142,6 +1179,11 @@ public class Conformance extends BaseResource implements IResource {
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myName, myVersion, myReleaseDate);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myName, myVersion, myReleaseDate);
+ }
+
/**
* Gets the value(s) for name (A name the software is known by).
@@ -1267,8 +1309,8 @@ public class Conformance extends BaseResource implements IResource {
* Date this version of the software released
*
*/
- public void setReleaseDateWithSecondsPrecision( Date theDate) {
- myReleaseDate = new DateTimeDt(theDate);
+ public void setReleaseDate( Date theDate, TemporalPrecisionEnum thePrecision) {
+ myReleaseDate = new DateTimeDt(theDate, thePrecision);
}
/**
@@ -1279,8 +1321,8 @@ public class Conformance extends BaseResource implements IResource {
* Date this version of the software released
*
*/
- public void setReleaseDate( Date theDate, TemporalPrecisionEnum thePrecision) {
- myReleaseDate = new DateTimeDt(theDate, thePrecision);
+ public void setReleaseDateWithSecondsPrecision( Date theDate) {
+ myReleaseDate = new DateTimeDt(theDate);
}
@@ -1318,6 +1360,11 @@ public class Conformance extends BaseResource implements IResource {
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myDescription, myUrl);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myDescription, myUrl);
+ }
+
/**
* Gets the value(s) for description (Describes this specific instance).
@@ -1446,34 +1493,39 @@ public class Conformance extends BaseResource implements IResource {
shortDefinition="Resource served on the REST interface",
formalDefinition="A specification of the restful capabilities of the solution for a specific resource type"
)
- private List myResource;
+ private java.util.List myResource;
@Child(name="operation", order=4, min=0, max=Child.MAX_UNLIMITED)
@Description(
shortDefinition="What operations are supported?",
formalDefinition="A specification of restful operations supported by the system"
)
- private List myOperation;
+ private java.util.List myOperation;
@Child(name="query", order=5, min=0, max=Child.MAX_UNLIMITED)
@Description(
shortDefinition="Definition of a named query",
formalDefinition="Definition of a named query and its parameters and their meaning"
)
- private List myQuery;
+ private java.util.List myQuery;
@Child(name="documentMailbox", type=UriDt.class, order=6, min=0, max=Child.MAX_UNLIMITED)
@Description(
shortDefinition="How documents are accepted in /Mailbox",
formalDefinition="A list of profiles that this server implements for accepting documents in the mailbox. If this list is empty, then documents are not accepted. The base specification has the profile identifier \"http://hl7.org/fhir/documents/mailbox\". Other specifications can declare their own identifier for this purpose"
)
- private List myDocumentMailbox;
+ private java.util.List myDocumentMailbox;
@Override
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myMode, myDocumentation, mySecurity, myResource, myOperation, myQuery, myDocumentMailbox);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myMode, myDocumentation, mySecurity, myResource, myOperation, myQuery, myDocumentMailbox);
+ }
+
/**
* Gets the value(s) for mode (client | server).
@@ -1602,9 +1654,9 @@ public class Conformance extends BaseResource implements IResource {
* A specification of the restful capabilities of the solution for a specific resource type
*
*/
- public List getResource() {
+ public java.util.List getResource() {
if (myResource == null) {
- myResource = new ArrayList();
+ myResource = new java.util.ArrayList();
}
return myResource;
}
@@ -1617,7 +1669,7 @@ public class Conformance extends BaseResource implements IResource {
* A specification of the restful capabilities of the solution for a specific resource type
*
*/
- public void setResource(List theValue) {
+ public void setResource(java.util.List theValue) {
myResource = theValue;
}
@@ -1646,9 +1698,9 @@ public class Conformance extends BaseResource implements IResource {
* A specification of restful operations supported by the system
*
*/
- public List getOperation() {
+ public java.util.List getOperation() {
if (myOperation == null) {
- myOperation = new ArrayList();
+ myOperation = new java.util.ArrayList();
}
return myOperation;
}
@@ -1661,7 +1713,7 @@ public class Conformance extends BaseResource implements IResource {
* A specification of restful operations supported by the system
*
*/
- public void setOperation(List theValue) {
+ public void setOperation(java.util.List theValue) {
myOperation = theValue;
}
@@ -1690,9 +1742,9 @@ public class Conformance extends BaseResource implements IResource {
* Definition of a named query and its parameters and their meaning
*
*/
- public List getQuery() {
+ public java.util.List getQuery() {
if (myQuery == null) {
- myQuery = new ArrayList();
+ myQuery = new java.util.ArrayList();
}
return myQuery;
}
@@ -1705,7 +1757,7 @@ public class Conformance extends BaseResource implements IResource {
* Definition of a named query and its parameters and their meaning
*
*/
- public void setQuery(List theValue) {
+ public void setQuery(java.util.List theValue) {
myQuery = theValue;
}
@@ -1734,9 +1786,9 @@ public class Conformance extends BaseResource implements IResource {
* A list of profiles that this server implements for accepting documents in the mailbox. If this list is empty, then documents are not accepted. The base specification has the profile identifier \"http://hl7.org/fhir/documents/mailbox\". Other specifications can declare their own identifier for this purpose
*
*/
- public List getDocumentMailbox() {
+ public java.util.List getDocumentMailbox() {
if (myDocumentMailbox == null) {
- myDocumentMailbox = new ArrayList();
+ myDocumentMailbox = new java.util.ArrayList();
}
return myDocumentMailbox;
}
@@ -1749,7 +1801,7 @@ public class Conformance extends BaseResource implements IResource {
* A list of profiles that this server implements for accepting documents in the mailbox. If this list is empty, then documents are not accepted. The base specification has the profile identifier \"http://hl7.org/fhir/documents/mailbox\". Other specifications can declare their own identifier for this purpose
*
*/
- public void setDocumentMailbox(List theValue) {
+ public void setDocumentMailbox(java.util.List theValue) {
myDocumentMailbox = theValue;
}
@@ -1777,7 +1829,7 @@ public class Conformance extends BaseResource implements IResource {
*/
public void addDocumentMailbox( String theUri) {
if (myDocumentMailbox == null) {
- myDocumentMailbox = new ArrayList();
+ myDocumentMailbox = new java.util.ArrayList();
}
myDocumentMailbox.add(new UriDt(theUri));
}
@@ -1809,7 +1861,7 @@ public class Conformance extends BaseResource implements IResource {
shortDefinition="OAuth | OAuth2 | NTLM | Basic | Kerberos",
formalDefinition="Types of security services are supported/required by the system"
)
- private List> myService;
+ private java.util.List> myService;
@Child(name="description", type=StringDt.class, order=2, min=0, max=1)
@Description(
@@ -1823,13 +1875,18 @@ public class Conformance extends BaseResource implements IResource {
shortDefinition="Certificates associated with security profiles",
formalDefinition="Certificates associated with security profiles"
)
- private List myCertificate;
+ private java.util.List myCertificate;
@Override
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myCors, myService, myDescription, myCertificate);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myCors, myService, myDescription, myCertificate);
+ }
+
/**
* Gets the value(s) for cors (Adds CORS Headers (http://enable-cors.org/)).
@@ -1884,9 +1941,9 @@ public class Conformance extends BaseResource implements IResource {
* Types of security services are supported/required by the system
*
*/
- public List> getService() {
+ public java.util.List> getService() {
if (myService == null) {
- myService = new ArrayList>();
+ myService = new java.util.ArrayList>();
}
return myService;
}
@@ -1899,7 +1956,7 @@ public class Conformance extends BaseResource implements IResource {
* Types of security services are supported/required by the system
*
*/
- public void setService(List> theValue) {
+ public void setService(java.util.List> theValue) {
myService = theValue;
}
@@ -1983,9 +2040,9 @@ public class Conformance extends BaseResource implements IResource {
* Certificates associated with security profiles
*
*/
- public List getCertificate() {
+ public java.util.List getCertificate() {
if (myCertificate == null) {
- myCertificate = new ArrayList();
+ myCertificate = new java.util.ArrayList();
}
return myCertificate;
}
@@ -1998,7 +2055,7 @@ public class Conformance extends BaseResource implements IResource {
* Certificates associated with security profiles
*
*/
- public void setCertificate(List theValue) {
+ public void setCertificate(java.util.List theValue) {
myCertificate = theValue;
}
@@ -2050,6 +2107,11 @@ public class Conformance extends BaseResource implements IResource {
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myType, myBlob);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myType, myBlob);
+ }
+
/**
* Gets the value(s) for type (Mime type for certificate).
@@ -2161,7 +2223,7 @@ public class Conformance extends BaseResource implements IResource {
private BoundCodeDt myType;
@Child(name="profile", order=1, min=0, max=1, type={
- Profile.class,
+ ca.uhn.fhir.model.dstu.resource.Profile.class,
})
@Description(
shortDefinition="What structural features are supported",
@@ -2174,7 +2236,7 @@ public class Conformance extends BaseResource implements IResource {
shortDefinition="What operations are supported?",
formalDefinition="Identifies a restful operation supported by the solution"
)
- private List myOperation;
+ private java.util.List myOperation;
@Child(name="readHistory", type=BooleanDt.class, order=3, min=0, max=1)
@Description(
@@ -2195,20 +2257,25 @@ public class Conformance extends BaseResource implements IResource {
shortDefinition="_include values supported by the server",
formalDefinition="A list of _include values supported by the server"
)
- private List mySearchInclude;
+ private java.util.List mySearchInclude;
@Child(name="searchParam", order=6, min=0, max=Child.MAX_UNLIMITED)
@Description(
shortDefinition="Additional search params defined",
formalDefinition="Additional search parameters for implementations to support and/or make use of"
)
- private List mySearchParam;
+ private java.util.List mySearchParam;
@Override
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myType, myProfile, myOperation, myReadHistory, myUpdateCreate, mySearchInclude, mySearchParam);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myType, myProfile, myOperation, myReadHistory, myUpdateCreate, mySearchInclude, mySearchParam);
+ }
+
/**
* Gets the value(s) for type (A resource type that is supported).
@@ -2294,9 +2361,9 @@ public class Conformance extends BaseResource implements IResource {
* Identifies a restful operation supported by the solution
*
*/
- public List getOperation() {
+ public java.util.List getOperation() {
if (myOperation == null) {
- myOperation = new ArrayList();
+ myOperation = new java.util.ArrayList();
}
return myOperation;
}
@@ -2309,7 +2376,7 @@ public class Conformance extends BaseResource implements IResource {
* Identifies a restful operation supported by the solution
*
*/
- public void setOperation(List theValue) {
+ public void setOperation(java.util.List theValue) {
myOperation = theValue;
}
@@ -2424,9 +2491,9 @@ public class Conformance extends BaseResource implements IResource {
* A list of _include values supported by the server
*
*/
- public List getSearchInclude() {
+ public java.util.List getSearchInclude() {
if (mySearchInclude == null) {
- mySearchInclude = new ArrayList();
+ mySearchInclude = new java.util.ArrayList();
}
return mySearchInclude;
}
@@ -2439,7 +2506,7 @@ public class Conformance extends BaseResource implements IResource {
* A list of _include values supported by the server
*
*/
- public void setSearchInclude(List theValue) {
+ public void setSearchInclude(java.util.List theValue) {
mySearchInclude = theValue;
}
@@ -2467,7 +2534,7 @@ public class Conformance extends BaseResource implements IResource {
*/
public void addSearchInclude( String theString) {
if (mySearchInclude == null) {
- mySearchInclude = new ArrayList();
+ mySearchInclude = new java.util.ArrayList();
}
mySearchInclude.add(new StringDt(theString));
}
@@ -2483,9 +2550,9 @@ public class Conformance extends BaseResource implements IResource {
* Additional search parameters for implementations to support and/or make use of
*
*/
- public List getSearchParam() {
+ public java.util.List getSearchParam() {
if (mySearchParam == null) {
- mySearchParam = new ArrayList();
+ mySearchParam = new java.util.ArrayList();
}
return mySearchParam;
}
@@ -2498,7 +2565,7 @@ public class Conformance extends BaseResource implements IResource {
* Additional search parameters for implementations to support and/or make use of
*
*/
- public void setSearchParam(List theValue) {
+ public void setSearchParam(java.util.List theValue) {
mySearchParam = theValue;
}
@@ -2550,6 +2617,11 @@ public class Conformance extends BaseResource implements IResource {
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myCode, myDocumentation);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myCode, myDocumentation);
+ }
+
/**
* Gets the value(s) for code (read | vread | update | delete | history-instance | validate | history-type | create | search-type).
@@ -2685,20 +2757,25 @@ public class Conformance extends BaseResource implements IResource {
shortDefinition="Types of resource (if a resource reference)",
formalDefinition="Types of resource (if a resource is referenced)"
)
- private List> myTarget;
+ private java.util.List> myTarget;
@Child(name="chain", type=StringDt.class, order=5, min=0, max=Child.MAX_UNLIMITED)
@Description(
shortDefinition="Chained names supported",
formalDefinition=""
)
- private List myChain;
+ private java.util.List myChain;
@Override
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myName, myDefinition, myType, myDocumentation, myTarget, myChain);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myName, myDefinition, myType, myDocumentation, myTarget, myChain);
+ }
+
/**
* Gets the value(s) for name (Name of search parameter).
@@ -2882,9 +2959,9 @@ public class Conformance extends BaseResource implements IResource {
* Types of resource (if a resource is referenced)
*
*/
- public List> getTarget() {
+ public java.util.List> getTarget() {
if (myTarget == null) {
- myTarget = new ArrayList>();
+ myTarget = new java.util.ArrayList>();
}
return myTarget;
}
@@ -2897,7 +2974,7 @@ public class Conformance extends BaseResource implements IResource {
* Types of resource (if a resource is referenced)
*
*/
- public void setTarget(List> theValue) {
+ public void setTarget(java.util.List> theValue) {
myTarget = theValue;
}
@@ -2938,9 +3015,9 @@ public class Conformance extends BaseResource implements IResource {
*
*
*/
- public List getChain() {
+ public java.util.List getChain() {
if (myChain == null) {
- myChain = new ArrayList();
+ myChain = new java.util.ArrayList();
}
return myChain;
}
@@ -2953,7 +3030,7 @@ public class Conformance extends BaseResource implements IResource {
*
*
*/
- public void setChain(List theValue) {
+ public void setChain(java.util.List theValue) {
myChain = theValue;
}
@@ -2981,7 +3058,7 @@ public class Conformance extends BaseResource implements IResource {
*/
public void addChain( String theString) {
if (myChain == null) {
- myChain = new ArrayList();
+ myChain = new java.util.ArrayList();
}
myChain.add(new StringDt(theString));
}
@@ -3022,6 +3099,11 @@ public class Conformance extends BaseResource implements IResource {
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myCode, myDocumentation);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myCode, myDocumentation);
+ }
+
/**
* Gets the value(s) for code (transaction | search-system | history-system).
@@ -3150,13 +3232,18 @@ public class Conformance extends BaseResource implements IResource {
shortDefinition="Parameter for the named query",
formalDefinition="Identifies which of the parameters for the named query are supported"
)
- private List myParameter;
+ private java.util.List myParameter;
@Override
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myName, myDefinition, myDocumentation, myParameter);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myName, myDefinition, myDocumentation, myParameter);
+ }
+
/**
* Gets the value(s) for name (Special named queries (_query=)).
@@ -3297,9 +3384,9 @@ public class Conformance extends BaseResource implements IResource {
* Identifies which of the parameters for the named query are supported
*
*/
- public List getParameter() {
+ public java.util.List getParameter() {
if (myParameter == null) {
- myParameter = new ArrayList();
+ myParameter = new java.util.ArrayList();
}
return myParameter;
}
@@ -3312,7 +3399,7 @@ public class Conformance extends BaseResource implements IResource {
* Identifies which of the parameters for the named query are supported
*
*/
- public void setParameter(List theValue) {
+ public void setParameter(java.util.List theValue) {
myParameter = theValue;
}
@@ -3373,13 +3460,18 @@ public class Conformance extends BaseResource implements IResource {
shortDefinition="Declare support for this event",
formalDefinition="A description of the solution's support for an event at this end point."
)
- private List myEvent;
+ private java.util.List myEvent;
@Override
public boolean isEmpty() {
return super.isBaseEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty( myEndpoint, myReliableCache, myDocumentation, myEvent);
}
+
+ public java.util.List getAllPopulatedChildElements() {
+ return ca.uhn.fhir.util.ElementUtil.allPopulatedChildElements( myEndpoint, myReliableCache, myDocumentation, myEvent);
+ }
+
/**
* Gets the value(s) for endpoint (Actual endpoint being described).
@@ -3520,9 +3612,9 @@ public class Conformance extends BaseResource implements IResource {
* A description of the solution's support for an event at this end point.
*
*/
- public List getEvent() {
+ public java.util.List getEvent() {
if (myEvent == null) {
- myEvent = new ArrayList();
+ myEvent = new java.util.ArrayList();
}
return myEvent;
}
@@ -3535,7 +3627,7 @@ public class Conformance extends BaseResource implements IResource {
* A description of the solution's support for an event at this end point.
*
*/
- public void setEvent(List theValue) {
+ public void setEvent(java.util.List theValue) {
myEvent = theValue;
}
@@ -3594,7 +3686,7 @@ public class Conformance extends BaseResource implements IResource {
shortDefinition="http | ftp | mllp +",
formalDefinition="A list of the messaging transport protocol(s) identifiers, supported by this endpoint"
)
- private List