Package org.hl7.fhir.dstu3.model
Class Reference
java.lang.Object
org.hl7.fhir.dstu3.model.Base
org.hl7.fhir.dstu3.model.Element
org.hl7.fhir.dstu3.model.Type
org.hl7.fhir.dstu3.model.BaseReference
org.hl7.fhir.dstu3.model.Reference
- All Implemented Interfaces:
ca.uhn.fhir.model.api.IElement
,Serializable
,org.hl7.fhir.instance.model.api.IBase
,org.hl7.fhir.instance.model.api.IBaseDatatype
,org.hl7.fhir.instance.model.api.IBaseElement
,org.hl7.fhir.instance.model.api.IBaseHasExtensions
,org.hl7.fhir.instance.model.api.IBaseReference
,org.hl7.fhir.instance.model.api.ICompositeType
public class Reference
extends BaseReference
implements org.hl7.fhir.instance.model.api.IBaseReference, org.hl7.fhir.instance.model.api.ICompositeType
A reference from one resource to another.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionprotected StringType
Plain text narrative that identifies the resource in addition to the resource reference.protected Identifier
An identifier for the other resource.protected StringType
A reference to a location at which the other resource is found. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncopy()
boolean
equalsDeep
(Base other_) boolean
equalsShallow
(Base other_) fhirType()
getNamedProperty
(int _hash, String _name, boolean _checkValid) Base[]
getProperty
(int hash, String name, boolean checkValid) String[]
getTypesForProperty
(int hash, String name) boolean
boolean
boolean
boolean
boolean
boolean
isEmpty()
protected void
listChildren
(List<Property> children) makeProperty
(int hash, String name) setDisplay
(String value) setDisplayElement
(StringType value) setIdentifier
(Identifier value) setProperty
(int hash, String name, Base value) setProperty
(String name, Base value) setReference
(String value) setReferenceElement
(StringType value) setReferenceElement
(org.hl7.fhir.instance.model.api.IIdType theReference) Convenience setter which sets the reference to the completevalue
of the given reference.protected Reference
Methods inherited from class org.hl7.fhir.dstu3.model.BaseReference
copyValues, getReferenceElement, getResource, setResource
Methods inherited from class org.hl7.fhir.dstu3.model.Element
addExtension, addExtension, addExtension, getExtension, getExtensionByUrl, getExtensionFirstRep, getExtensionsByUrl, getExtensionString, getId, getIdBase, getIdElement, hasExtension, hasExtension, hasId, hasIdElement, setExtension, setId, setIdBase, setIdElement
Methods inherited from class org.hl7.fhir.dstu3.model.Base
castToAddress, castToAnnotation, castToAttachment, castToBase64Binary, castToBoolean, castToCode, castToCodeableConcept, castToCoding, castToContactDetail, castToContactPoint, castToContributor, castToDataRequirement, castToDate, castToDateTime, castToDecimal, castToDosage, castToDuration, castToElementDefinition, castToExtension, castToHumanName, castToId, castToIdentifier, castToInstant, castToInteger, castToMarkdown, castToMeta, castToMoney, castToNarrative, castToOid, castToParameterDefinition, castToPeriod, castToPositiveInt, castToQuantity, castToRange, castToRatio, castToReference, castToRelatedArtifact, castToResource, castToSampledData, castToSignature, castToSimpleQuantity, castToString, castToTime, castToTiming, castToTriggerDefinition, castToType, castToUnsignedInt, castToUri, castToUsageContext, castToXhtml, castToXhtmlString, children, clearUserData, compareDeep, compareDeep, compareDeep, compareValues, compareValues, equals, getChildByName, getFormatCommentsPost, getFormatCommentsPre, getNamedProperty, getUserData, getUserInt, getUserString, hasFormatComment, hasPrimitiveValue, hasType, hasUserData, isBooleanPrimitive, isMetadataBased, isPrimitive, isResource, 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.IBase
getFormatCommentsPost, getFormatCommentsPre, getUserData, hasFormatComment, setUserData
Methods inherited from interface org.hl7.fhir.instance.model.api.IBaseElement
getUserData, setUserData
Methods inherited from interface org.hl7.fhir.instance.model.api.IBaseReference
getReferenceElement, getResource, setResource
-
Field Details
-
reference
A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources. -
identifier
An identifier for the other resource. This is used when there is no way to reference the other resource directly, either because the entity is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference. -
display
Plain text narrative that identifies the resource in addition to the resource reference.
-
-
Constructor Details
-
Reference
public Reference()Constructor -
Reference
Constructor- Parameters:
theReference
- The given reference string (e.g. "Patient/123" or "http://example.com/Patient/123")
-
Reference
Constructor- Parameters:
theReference
- The given reference as an IdType (e.g. "Patient/123" or "http://example.com/Patient/123")
-
Reference
Constructor- Parameters:
theResource
- The resource represented by this reference
-
-
Method Details
-
getReferenceElement_
- Returns:
reference
(A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources.). This is the underlying object with id, value and extensions. The accessor "getReference" gives direct access to the value
-
hasReferenceElement
-
hasReference
-
setReferenceElement
- Parameters:
value
-reference
(A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources.). This is the underlying object with id, value and extensions. The accessor "getReference" gives direct access to the value
-
getReference
- Returns:
- A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources.
-
setReference
- Specified by:
setReference
in interfaceorg.hl7.fhir.instance.model.api.IBaseReference
- Parameters:
value
- A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources.
-
getIdentifier
- Returns:
identifier
(An identifier for the other resource. This is used when there is no way to reference the other resource directly, either because the entity is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference.)
-
hasIdentifier
- Specified by:
hasIdentifier
in interfaceorg.hl7.fhir.instance.model.api.IBaseReference
-
setIdentifier
- Parameters:
value
-identifier
(An identifier for the other resource. This is used when there is no way to reference the other resource directly, either because the entity is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference.)
-
getDisplayElement
- Specified by:
getDisplayElement
in interfaceorg.hl7.fhir.instance.model.api.IBaseReference
- Returns:
display
(Plain text narrative that identifies the resource in addition to the resource reference.). This is the underlying object with id, value and extensions. The accessor "getDisplay" gives direct access to the value
-
hasDisplayElement
-
hasDisplay
-
setDisplayElement
- Parameters:
value
-display
(Plain text narrative that identifies the resource in addition to the resource reference.). This is the underlying object with id, value and extensions. The accessor "getDisplay" gives direct access to the value
-
getDisplay
- Returns:
- Plain text narrative that identifies the resource in addition to the resource reference.
-
setDisplay
- Specified by:
setDisplay
in interfaceorg.hl7.fhir.instance.model.api.IBaseReference
- Parameters:
value
- Plain text narrative that identifies the resource in addition to the resource reference.
-
setReferenceElement
Convenience setter which sets the reference to the completevalue
of the given reference.- Parameters:
theReference
- The reference, ornull
- Returns:
-
listChildren
- Overrides:
listChildren
in classElement
-
getNamedProperty
public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws org.hl7.fhir.exceptions.FHIRException - Overrides:
getNamedProperty
in classElement
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
getProperty
public Base[] getProperty(int hash, String name, boolean checkValid) throws org.hl7.fhir.exceptions.FHIRException - Overrides:
getProperty
in classElement
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
setProperty
public Base setProperty(int hash, String name, Base value) throws org.hl7.fhir.exceptions.FHIRException - Overrides:
setProperty
in classElement
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
setProperty
- Overrides:
setProperty
in classElement
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
makeProperty
- Overrides:
makeProperty
in classElement
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
getTypesForProperty
public String[] getTypesForProperty(int hash, String name) throws org.hl7.fhir.exceptions.FHIRException - Overrides:
getTypesForProperty
in classElement
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
addChild
-
fhirType
-
copy
-
typedCopy
-
equalsDeep
- Overrides:
equalsDeep
in classElement
-
equalsShallow
- Overrides:
equalsShallow
in classElement
-
isEmpty
- Specified by:
isEmpty
in interfaceorg.hl7.fhir.instance.model.api.IBase
- Overrides:
isEmpty
in classBaseReference
-