Class ChEmedEprCompositionPre
java.lang.Object
org.hl7.fhir.r4.model.Base
org.hl7.fhir.r4.model.BaseResource
org.hl7.fhir.r4.model.Resource
org.hl7.fhir.r4.model.DomainResource
org.hl7.fhir.r4.model.Composition
org.projecthusky.fhir.emed.ch.epr.resource.ChEmedEprComposition
org.projecthusky.fhir.emed.ch.epr.resource.pre.ChEmedEprCompositionPre
- All Implemented Interfaces:
ca.uhn.fhir.model.api.IElement
,Serializable
,org.hl7.fhir.instance.model.api.IAnyResource
,org.hl7.fhir.instance.model.api.IBase
,org.hl7.fhir.instance.model.api.IBaseHasExtensions
,org.hl7.fhir.instance.model.api.IBaseHasModifierExtensions
,org.hl7.fhir.instance.model.api.IBaseResource
,org.hl7.fhir.instance.model.api.IDomainResource
The HAPI custom structure for the CH-EMED-EPR PRE Composition.
- Author:
- Quentin Ligier
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.projecthusky.fhir.emed.ch.epr.resource.ChEmedEprComposition
ChEmedEprComposition.VitalSignsSection
Nested classes/interfaces inherited from class org.hl7.fhir.r4.model.Composition
org.hl7.fhir.r4.model.Composition.CompositionAttestationMode, org.hl7.fhir.r4.model.Composition.CompositionAttestationModeEnumFactory, org.hl7.fhir.r4.model.Composition.CompositionAttesterComponent, org.hl7.fhir.r4.model.Composition.CompositionEventComponent, org.hl7.fhir.r4.model.Composition.CompositionRelatesToComponent, org.hl7.fhir.r4.model.Composition.CompositionStatus, org.hl7.fhir.r4.model.Composition.CompositionStatusEnumFactory, org.hl7.fhir.r4.model.Composition.DocumentConfidentiality, org.hl7.fhir.r4.model.Composition.DocumentConfidentialityEnumFactory, org.hl7.fhir.r4.model.Composition.DocumentRelationshipType, org.hl7.fhir.r4.model.Composition.DocumentRelationshipTypeEnumFactory, org.hl7.fhir.r4.model.Composition.SectionComponent, org.hl7.fhir.r4.model.Composition.SectionMode, org.hl7.fhir.r4.model.Composition.SectionModeEnumFactory
-
Field Summary
Fields inherited from class org.projecthusky.fhir.emed.ch.epr.resource.ChEmedEprComposition
ANNOTATION_SECTION_CODE_VALUE, CARD_SECTION_CODE_VALUE, dataEnterer, DISPENSE_SECTION_CODE_VALUE, informationRecipient, LIST_SECTION_CODE_VALUE, ORIGINAL_REPR_SECTION_CODE_VALUE, PHARMACEUTICAL_ADVICE_SECTION_CODE_VALUE, PRESCRIPTION_SECTION_CODE_VALUE, TREATMENT_PLAN_SECTION_CODE_VALUE, versionNumber, VITAL_SIGNS_SECTION_CODE_VALUE
Fields inherited from class org.hl7.fhir.r4.model.Composition
attester, ATTESTER, author, AUTHOR, authorTarget, category, CATEGORY, confidentiality, CONFIDENTIALITY, CONTEXT, custodian, custodianTarget, date, DATE, encounter, ENCOUNTER, encounterTarget, ENTRY, event, identifier, IDENTIFIER, INCLUDE_ATTESTER, INCLUDE_AUTHOR, INCLUDE_ENCOUNTER, INCLUDE_ENTRY, INCLUDE_PATIENT, INCLUDE_RELATED_REF, INCLUDE_SUBJECT, PATIENT, PERIOD, RELATED_ID, RELATED_REF, relatesTo, section, SECTION, SP_ATTESTER, SP_AUTHOR, SP_CATEGORY, SP_CONFIDENTIALITY, SP_CONTEXT, SP_DATE, SP_ENCOUNTER, SP_ENTRY, SP_IDENTIFIER, SP_PATIENT, SP_PERIOD, SP_RELATED_ID, SP_RELATED_REF, SP_SECTION, SP_STATUS, SP_SUBJECT, SP_TITLE, SP_TYPE, status, STATUS, subject, SUBJECT, subjectTarget, title, TITLE, type, TYPE
Fields inherited from class org.hl7.fhir.r4.model.DomainResource
contained, extension, modifierExtension, text
Fields inherited from class org.hl7.fhir.r4.model.Resource
id, implicitRules, language, meta
Fields inherited from interface org.hl7.fhir.instance.model.api.IAnyResource
RES_ID, SP_RES_ID
Fields inherited from interface org.hl7.fhir.instance.model.api.IBaseResource
INCLUDE_ALL, WILDCARD_ALL_SET
-
Constructor Summary
ConstructorsConstructorDescriptionEmpty constructor for the parser.ChEmedEprCompositionPre
(UUID compositionId, Instant date, LanguageCode language) Constructor that pre-populates fields. -
Method Summary
Modifier and TypeMethodDescriptionaddAuthor
(ChCorePatientEpr author) Adds aChCorePatientEpr
to the list of document authors.addAuthor
(ChEmedEprPractitionerRole author) Adds aChEmedEprPractitionerRole
to the list of document authors.addMedicationRequest
(ChEmedEprMedicationRequestPre medicationRequest) Adds aChEmedEprMedicationRequestPre
.copy()
org.hl7.fhir.r4.model.Composition.SectionComponent
Returns the prescription section; if missing, it creates it.boolean
Returns whether the annotation section exists.boolean
Returns whether the prescription section exists.List<org.hl7.fhir.r4.model.DomainResource>
org.hl7.fhir.r4.model.Resource
Resolves the main human author of the document.Returns the list medication requests or throws.Methods inherited from class org.projecthusky.fhir.emed.ch.epr.resource.ChEmedEprComposition
copyValues, getAnnotationSection, getDataEnterer, getInformationRecipient, getOriginalRepresentationPdf, getOriginalRepresentationSection, getSectionByLoincCode, getVersionNumber, getVersionNumberElement, hasDataEnterer, hasInformationRecipient, hasOriginalRepresentationSection, hasVersionNumber, hasVitalSignsSection, resolveCustodian, resolveDate, resolveFirstHumanAuthor, resolveFirstHumanAuthorTime, resolveIdentifier, resolveLanguage, resolvePatient, resolvePatientWeightObservation, setDataEnterer, setIdentifier, setInformationRecipient, setLanguage, setOriginalRepresentationPdf, setOriginalRepresentationPdf, setPatient, setVersionNumber, setVersionNumberElement
Methods inherited from class org.hl7.fhir.r4.model.Composition
addAttester, addAttester, addAuthor, addAuthor, addCategory, addCategory, addChild, addEvent, addEvent, addRelatesTo, addRelatesTo, addSection, addSection, equalsDeep, equalsShallow, fhirType, getAttester, getAttesterFirstRep, getAuthor, getAuthorFirstRep, getAuthorTarget, getCategory, getCategoryFirstRep, getConfidentiality, getConfidentialityElement, getCustodian, getCustodianTarget, getDate, getDateElement, getEncounter, getEncounterTarget, getEvent, getEventFirstRep, getIdentifier, getNamedProperty, getProperty, getRelatesTo, getRelatesToFirstRep, getResourceType, getSection, getSectionFirstRep, getStatus, getStatusElement, getSubject, getSubjectTarget, getTitle, getTitleElement, getType, getTypesForProperty, hasAttester, hasAuthor, hasCategory, hasConfidentiality, hasConfidentialityElement, hasCustodian, hasDate, hasDateElement, hasEncounter, hasEvent, hasIdentifier, hasRelatesTo, hasSection, hasStatus, hasStatusElement, hasSubject, hasTitle, hasTitleElement, hasType, isEmpty, listChildren, makeProperty, removeChild, setAttester, setAuthor, setCategory, setConfidentiality, setConfidentialityElement, setCustodian, setCustodianTarget, setDate, setDateElement, setEncounter, setEncounterTarget, setEvent, setIdentifier, setProperty, setProperty, setRelatesTo, setSection, setStatus, setStatusElement, setSubject, setSubjectTarget, setTitle, setTitleElement, setType, typedCopy
Methods inherited from class org.hl7.fhir.r4.model.DomainResource
addContained, addExtension, addExtension, addExtension, addModifierExtension, addModifierExtension, checkNoModifiers, copyValues, getContained, getExtension, getExtensionByUrl, getExtensionsByUrl, getModifierExtension, getModifierExtensionsByUrl, getText, hasContained, hasExtension, hasExtension, hasModifierExtension, hasText, setContained, setExtension, setModifierExtension, setText
Methods inherited from class org.hl7.fhir.r4.model.Resource
copyValues, getId, getIdBase, getIdElement, getIdPart, getImplicitRules, getImplicitRulesElement, getLanguage, getLanguage, getLanguageElement, getMeta, hasId, hasIdElement, hasImplicitRules, hasImplicitRulesElement, hasLanguage, hasLanguageElement, hasMeta, setId, setIdBase, setIdElement, setImplicitRules, setImplicitRulesElement, setLanguage, setLanguageElement, setMeta
Methods inherited from class org.hl7.fhir.r4.model.BaseResource
getStructureFhirVersionEnum, isResource, setId
Methods inherited from class org.hl7.fhir.r4.model.Base
castToAddress, castToAnnotation, castToAttachment, castToBase64Binary, castToBoolean, castToCanonical, castToCode, castToCodeableConcept, castToCoding, castToContactDetail, castToContactPoint, castToContributor, castToDataRequirement, castToDate, castToDateTime, castToDecimal, castToDosage, castToDuration, castToElementDefinition, castToExpression, castToExtension, castToHumanName, castToId, castToIdentifier, castToInstant, castToInteger, castToMarkdown, castToMarketingStatus, castToMeta, castToMoney, castToNarrative, castToOid, castToParameterDefinition, castToPeriod, castToPopulation, castToPositiveInt, castToProdCharacteristic, castToProductShelfLife, castToQuantity, castToRange, castToRatio, castToReference, castToRelatedArtifact, castToResource, castToSampledData, castToSignature, castToSimpleQuantity, castToString, castToSubstanceAmount, castToTime, castToTiming, castToTriggerDefinition, castToType, castToUnsignedInt, castToUri, castToUrl, castToUsageContext, castToXhtml, castToXhtmlString, children, clearUserData, compareDeep, compareDeep, compareDeep, compareDeep, compareValues, compareValues, copyValues, dateTimeValue, equals, getChildByName, getFormatCommentsPost, getFormatCommentsPre, getNamedProperty, getUserData, getUserInt, getUserString, getXhtml, hasFormatComment, hasPrimitiveValue, hasType, hasUserData, isBooleanPrimitive, isDateTime, isMetadataBased, isPrimitive, listChildrenByName, listChildrenByName, primitiveValue, setUserData, setUserDataINN
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.hl7.fhir.instance.model.api.IAnyResource
getId, getIdElement, getLanguageElement, getUserData, setId, setUserData
Methods inherited from interface org.hl7.fhir.instance.model.api.IBase
getFormatCommentsPost, getFormatCommentsPre, hasFormatComment
Methods inherited from interface org.hl7.fhir.instance.model.api.IBaseResource
getMeta, getStructureFhirVersionEnum, isDeleted, setId
-
Constructor Details
-
ChEmedEprCompositionPre
public ChEmedEprCompositionPre()Empty constructor for the parser. -
ChEmedEprCompositionPre
Constructor that pre-populates fields.- Parameters:
compositionId
- Version-independent identifier for the Compositiondate
- The document's creation date and time
-
-
Method Details
-
resolveAuthors
@ExpectsValidResource public List<org.hl7.fhir.r4.model.DomainResource> resolveAuthors() throws InvalidEmedContentException- Returns:
- the list with the authors of the document.
- Throws:
InvalidEmedContentException
- if no author is specified or if an author is not of typeChEmedEprPractitionerRole
,ChCorePatientEpr
orDevice
.
-
resolveMainHumanAuthor
Resolves the main human author of the document.- Returns:
- the main human author.
- Throws:
InvalidEmedContentException
- if no author is specified or if an author is not of typeChEmedEprPractitionerRole
orChCorePatientEpr
.
-
getPrescriptionSection
public org.hl7.fhir.r4.model.Composition.SectionComponent getPrescriptionSection()Returns the prescription section; if missing, it creates it.- Returns:
- the prescription section.
-
resolveMedicationRequests
@ExpectsValidResource public List<ChEmedEprMedicationRequestPre> resolveMedicationRequests() throws InvalidEmedContentExceptionReturns the list medication requests or throws.- Returns:
- the list with medication requests.
- Throws:
InvalidEmedContentException
- if the medication requests is missing or invalid.
-
hasPrescriptionSection
public boolean hasPrescriptionSection()Returns whether the prescription section exists.- Returns:
true
if the prescription section exists,false
otherwise.
-
hasAnnotationSection
public boolean hasAnnotationSection()Returns whether the annotation section exists.- Returns:
true
if the annotation section exists,false
otherwise.
-
addAuthor
Adds aChEmedEprPractitionerRole
to the list of document authors.- Parameters:
author
- the author od the document.- Returns:
- this.
-
addAuthor
Adds aChCorePatientEpr
to the list of document authors.- Parameters:
author
- the author od the document.- Returns:
- this.
-
addMedicationRequest
public ChEmedEprCompositionPre addMedicationRequest(ChEmedEprMedicationRequestPre medicationRequest) Adds aChEmedEprMedicationRequestPre
.- Parameters:
medicationRequest
- the medication request.
-
copy
- Overrides:
copy
in classorg.hl7.fhir.r4.model.Composition
-