
Class Medication
- java.lang.Object
-
- org.hl7.fhir.dstu3.model.Base
-
- org.hl7.fhir.dstu3.model.BaseResource
-
- org.hl7.fhir.dstu3.model.Resource
-
- org.hl7.fhir.dstu3.model.DomainResource
-
- org.hl7.fhir.dstu3.model.Medication
-
- 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
public class Medication extends DomainResource
This resource is primarily used for the identification and definition of a medication. It covers the ingredients and the packaging for a medication.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Medication.MedicationIngredientComponent
static class
Medication.MedicationPackageBatchComponent
static class
Medication.MedicationPackageComponent
static class
Medication.MedicationPackageContentComponent
static class
Medication.MedicationStatus
static class
Medication.MedicationStatusEnumFactory
-
Field Summary
Fields Modifier and Type Field Description protected CodeableConcept
code
A code (or set of codes) that specify this medication, or a textual description if no code is available.static ca.uhn.fhir.rest.gclient.TokenClientParam
CODE
Fluent Client search parameter constant for codestatic ca.uhn.fhir.rest.gclient.TokenClientParam
CONTAINER
Fluent Client search parameter constant for containerprotected CodeableConcept
form
Describes the form of the item.static ca.uhn.fhir.rest.gclient.TokenClientParam
FORM
Fluent Client search parameter constant for formprotected List<Attachment>
image
Photo(s) or graphic representation(s) of the medication.static ca.uhn.fhir.model.api.Include
INCLUDE_INGREDIENT
Constant for fluent queries to be used to add include statements.static ca.uhn.fhir.model.api.Include
INCLUDE_MANUFACTURER
Constant for fluent queries to be used to add include statements.static ca.uhn.fhir.model.api.Include
INCLUDE_PACKAGE_ITEM
Constant for fluent queries to be used to add include statements.protected List<Medication.MedicationIngredientComponent>
ingredient
Identifies a particular constituent of interest in the product.static ca.uhn.fhir.rest.gclient.ReferenceClientParam
INGREDIENT
Fluent Client search parameter constant for ingredientstatic ca.uhn.fhir.rest.gclient.TokenClientParam
INGREDIENT_CODE
Fluent Client search parameter constant for ingredient-codeprotected BooleanType
isBrand
Set to true if the item is attributable to a specific manufacturer.protected BooleanType
isOverTheCounter
Set to true if the medication can be obtained without an order from a prescriber.protected Reference
manufacturer
Describes the details of the manufacturer of the medication product.static ca.uhn.fhir.rest.gclient.ReferenceClientParam
MANUFACTURER
Fluent Client search parameter constant for manufacturerprotected Organization
manufacturerTarget
The actual object that is the target of the reference (Describes the details of the manufacturer of the medication product.static ca.uhn.fhir.rest.gclient.TokenClientParam
OVER_THE_COUNTER
Fluent Client search parameter constant for over-the-counterprotected Medication.MedicationPackageComponent
package_
Information that only applies to packages (not products).static ca.uhn.fhir.rest.gclient.ReferenceClientParam
PACKAGE_ITEM
Fluent Client search parameter constant for package-itemstatic ca.uhn.fhir.rest.gclient.TokenClientParam
PACKAGE_ITEM_CODE
Fluent Client search parameter constant for package-item-codestatic String
SP_CODE
Search parameter: codestatic String
SP_CONTAINER
Search parameter: containerstatic String
SP_FORM
Search parameter: formstatic String
SP_INGREDIENT
Search parameter: ingredientstatic String
SP_INGREDIENT_CODE
Search parameter: ingredient-codestatic String
SP_MANUFACTURER
Search parameter: manufacturerstatic String
SP_OVER_THE_COUNTER
Search parameter: over-the-counterstatic String
SP_PACKAGE_ITEM
Search parameter: package-itemstatic String
SP_PACKAGE_ITEM_CODE
Search parameter: package-item-codestatic String
SP_STATUS
Search parameter: statusprotected Enumeration<Medication.MedicationStatus>
status
A code to indicate if the medication is in active use.static ca.uhn.fhir.rest.gclient.TokenClientParam
STATUS
Fluent Client search parameter constant for status-
Fields inherited from class org.hl7.fhir.dstu3.model.DomainResource
contained, extension, modifierExtension, text
-
Fields inherited from class org.hl7.fhir.dstu3.model.Resource
id, implicitRules, language, meta
-
-
Constructor Summary
Constructors Constructor Description Medication()
Constructor
-
Method Summary
-
Methods inherited from class org.hl7.fhir.dstu3.model.DomainResource
addContained, addExtension, addExtension, addModifierExtension, addModifierExtension, copyValues, getContained, getExtension, getExtensionsByUrl, getModifierExtension, getModifierExtensionsByUrl, getText, hasContained, hasExtension, hasModifierExtension, hasText, setContained, setExtension, setModifierExtension, setText
-
Methods inherited from class org.hl7.fhir.dstu3.model.Resource
copyValues, getId, getIdBase, getIdElement, getImplicitRules, getImplicitRulesElement, 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.dstu3.model.BaseResource
getStructureFhirVersionEnum, isResource, setId
-
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, 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
-
-
-
-
Field Detail
-
code
protected CodeableConcept code
A code (or set of codes) that specify this medication, or a textual description if no code is available. Usage note: This could be a standard medication code such as a code from RxNorm, SNOMED CT, IDMP etc. It could also be a national or local formulary code, optionally with translations to other code systems.
-
status
protected Enumeration<Medication.MedicationStatus> status
A code to indicate if the medication is in active use.
-
isBrand
protected BooleanType isBrand
Set to true if the item is attributable to a specific manufacturer.
-
isOverTheCounter
protected BooleanType isOverTheCounter
Set to true if the medication can be obtained without an order from a prescriber.
-
manufacturer
protected Reference manufacturer
Describes the details of the manufacturer of the medication product. This is not intended to represent the distributor of a medication product.
-
manufacturerTarget
protected Organization manufacturerTarget
The actual object that is the target of the reference (Describes the details of the manufacturer of the medication product. This is not intended to represent the distributor of a medication product.)
-
form
protected CodeableConcept form
Describes the form of the item. Powder; tablets; capsule.
-
ingredient
protected List<Medication.MedicationIngredientComponent> ingredient
Identifies a particular constituent of interest in the product.
-
package_
protected Medication.MedicationPackageComponent package_
Information that only applies to packages (not products).
-
image
protected List<Attachment> image
Photo(s) or graphic representation(s) of the medication.
-
SP_INGREDIENT_CODE
public static final String SP_INGREDIENT_CODE
Search parameter: ingredient-codeDescription: The product contained
Type: token
Path: Medication.ingredient.itemCodeableConcept
- See Also:
- Constant Field Values
-
INGREDIENT_CODE
public static final ca.uhn.fhir.rest.gclient.TokenClientParam INGREDIENT_CODE
Fluent Client search parameter constant for ingredient-codeDescription: The product contained
Type: token
Path: Medication.ingredient.itemCodeableConcept
-
SP_CONTAINER
public static final String SP_CONTAINER
Search parameter: containerDescription: E.g. box, vial, blister-pack
Type: token
Path: Medication.package.container
- See Also:
- Constant Field Values
-
CONTAINER
public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTAINER
Fluent Client search parameter constant for containerDescription: E.g. box, vial, blister-pack
Type: token
Path: Medication.package.container
-
SP_PACKAGE_ITEM
public static final String SP_PACKAGE_ITEM
Search parameter: package-itemDescription: The item in the package
Type: reference
Path: Medication.package.content.itemReference
- See Also:
- Constant Field Values
-
PACKAGE_ITEM
public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PACKAGE_ITEM
Fluent Client search parameter constant for package-itemDescription: The item in the package
Type: reference
Path: Medication.package.content.itemReference
-
INCLUDE_PACKAGE_ITEM
public static final ca.uhn.fhir.model.api.Include INCLUDE_PACKAGE_ITEM
Constant for fluent queries to be used to add include statements. Specifies the path value of "Medication:package-item".
-
SP_CODE
public static final String SP_CODE
Search parameter: codeDescription: Codes that identify this medication
Type: token
Path: Medication.code
- See Also:
- Constant Field Values
-
CODE
public static final ca.uhn.fhir.rest.gclient.TokenClientParam CODE
Fluent Client search parameter constant for codeDescription: Codes that identify this medication
Type: token
Path: Medication.code
-
SP_INGREDIENT
public static final String SP_INGREDIENT
Search parameter: ingredientDescription: The product contained
Type: reference
Path: Medication.ingredient.itemReference
- See Also:
- Constant Field Values
-
INGREDIENT
public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam INGREDIENT
Fluent Client search parameter constant for ingredientDescription: The product contained
Type: reference
Path: Medication.ingredient.itemReference
-
INCLUDE_INGREDIENT
public static final ca.uhn.fhir.model.api.Include INCLUDE_INGREDIENT
Constant for fluent queries to be used to add include statements. Specifies the path value of "Medication:ingredient".
-
SP_FORM
public static final String SP_FORM
Search parameter: formDescription: powder | tablets | capsule +
Type: token
Path: Medication.form
- See Also:
- Constant Field Values
-
FORM
public static final ca.uhn.fhir.rest.gclient.TokenClientParam FORM
Fluent Client search parameter constant for formDescription: powder | tablets | capsule +
Type: token
Path: Medication.form
-
SP_PACKAGE_ITEM_CODE
public static final String SP_PACKAGE_ITEM_CODE
Search parameter: package-item-codeDescription: The item in the package
Type: token
Path: Medication.package.content.itemCodeableConcept
- See Also:
- Constant Field Values
-
PACKAGE_ITEM_CODE
public static final ca.uhn.fhir.rest.gclient.TokenClientParam PACKAGE_ITEM_CODE
Fluent Client search parameter constant for package-item-codeDescription: The item in the package
Type: token
Path: Medication.package.content.itemCodeableConcept
-
SP_MANUFACTURER
public static final String SP_MANUFACTURER
Search parameter: manufacturerDescription: Manufacturer of the item
Type: reference
Path: Medication.manufacturer
- See Also:
- Constant Field Values
-
MANUFACTURER
public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam MANUFACTURER
Fluent Client search parameter constant for manufacturerDescription: Manufacturer of the item
Type: reference
Path: Medication.manufacturer
-
INCLUDE_MANUFACTURER
public static final ca.uhn.fhir.model.api.Include INCLUDE_MANUFACTURER
Constant for fluent queries to be used to add include statements. Specifies the path value of "Medication:manufacturer".
-
SP_OVER_THE_COUNTER
public static final String SP_OVER_THE_COUNTER
Search parameter: over-the-counterDescription: True if medication does not require a prescription
Type: token
Path: Medication.isOverTheCounter
- See Also:
- Constant Field Values
-
OVER_THE_COUNTER
public static final ca.uhn.fhir.rest.gclient.TokenClientParam OVER_THE_COUNTER
Fluent Client search parameter constant for over-the-counterDescription: True if medication does not require a prescription
Type: token
Path: Medication.isOverTheCounter
-
SP_STATUS
public static final String SP_STATUS
Search parameter: statusDescription: active | inactive | entered-in-error
Type: token
Path: Medication.status
- See Also:
- Constant Field Values
-
STATUS
public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS
Fluent Client search parameter constant for statusDescription: active | inactive | entered-in-error
Type: token
Path: Medication.status
-
-
Constructor Detail
-
Medication
public Medication()
Constructor
-
-
Method Detail
-
getCode
public CodeableConcept getCode()
- Returns:
code
(A code (or set of codes) that specify this medication, or a textual description if no code is available. Usage note: This could be a standard medication code such as a code from RxNorm, SNOMED CT, IDMP etc. It could also be a national or local formulary code, optionally with translations to other code systems.)
-
hasCode
public boolean hasCode()
-
setCode
public Medication setCode(CodeableConcept value)
- Parameters:
value
-code
(A code (or set of codes) that specify this medication, or a textual description if no code is available. Usage note: This could be a standard medication code such as a code from RxNorm, SNOMED CT, IDMP etc. It could also be a national or local formulary code, optionally with translations to other code systems.)
-
getStatusElement
public Enumeration<Medication.MedicationStatus> getStatusElement()
- Returns:
status
(A code to indicate if the medication is in active use.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value
-
hasStatusElement
public boolean hasStatusElement()
-
hasStatus
public boolean hasStatus()
-
setStatusElement
public Medication setStatusElement(Enumeration<Medication.MedicationStatus> value)
- Parameters:
value
-status
(A code to indicate if the medication is in active use.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value
-
getStatus
public Medication.MedicationStatus getStatus()
- Returns:
- A code to indicate if the medication is in active use.
-
setStatus
public Medication setStatus(Medication.MedicationStatus value)
- Parameters:
value
- A code to indicate if the medication is in active use.
-
getIsBrandElement
public BooleanType getIsBrandElement()
- Returns:
isBrand
(Set to true if the item is attributable to a specific manufacturer.). This is the underlying object with id, value and extensions. The accessor "getIsBrand" gives direct access to the value
-
hasIsBrandElement
public boolean hasIsBrandElement()
-
hasIsBrand
public boolean hasIsBrand()
-
setIsBrandElement
public Medication setIsBrandElement(BooleanType value)
- Parameters:
value
-isBrand
(Set to true if the item is attributable to a specific manufacturer.). This is the underlying object with id, value and extensions. The accessor "getIsBrand" gives direct access to the value
-
getIsBrand
public boolean getIsBrand()
- Returns:
- Set to true if the item is attributable to a specific manufacturer.
-
setIsBrand
public Medication setIsBrand(boolean value)
- Parameters:
value
- Set to true if the item is attributable to a specific manufacturer.
-
getIsOverTheCounterElement
public BooleanType getIsOverTheCounterElement()
- Returns:
isOverTheCounter
(Set to true if the medication can be obtained without an order from a prescriber.). This is the underlying object with id, value and extensions. The accessor "getIsOverTheCounter" gives direct access to the value
-
hasIsOverTheCounterElement
public boolean hasIsOverTheCounterElement()
-
hasIsOverTheCounter
public boolean hasIsOverTheCounter()
-
setIsOverTheCounterElement
public Medication setIsOverTheCounterElement(BooleanType value)
- Parameters:
value
-isOverTheCounter
(Set to true if the medication can be obtained without an order from a prescriber.). This is the underlying object with id, value and extensions. The accessor "getIsOverTheCounter" gives direct access to the value
-
getIsOverTheCounter
public boolean getIsOverTheCounter()
- Returns:
- Set to true if the medication can be obtained without an order from a prescriber.
-
setIsOverTheCounter
public Medication setIsOverTheCounter(boolean value)
- Parameters:
value
- Set to true if the medication can be obtained without an order from a prescriber.
-
getManufacturer
public Reference getManufacturer()
- Returns:
manufacturer
(Describes the details of the manufacturer of the medication product. This is not intended to represent the distributor of a medication product.)
-
hasManufacturer
public boolean hasManufacturer()
-
setManufacturer
public Medication setManufacturer(Reference value)
- Parameters:
value
-manufacturer
(Describes the details of the manufacturer of the medication product. This is not intended to represent the distributor of a medication product.)
-
getManufacturerTarget
public Organization getManufacturerTarget()
- Returns:
manufacturer
The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (Describes the details of the manufacturer of the medication product. This is not intended to represent the distributor of a medication product.)
-
setManufacturerTarget
public Medication setManufacturerTarget(Organization value)
- Parameters:
value
-manufacturer
The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (Describes the details of the manufacturer of the medication product. This is not intended to represent the distributor of a medication product.)
-
getForm
public CodeableConcept getForm()
- Returns:
form
(Describes the form of the item. Powder; tablets; capsule.)
-
hasForm
public boolean hasForm()
-
setForm
public Medication setForm(CodeableConcept value)
- Parameters:
value
-form
(Describes the form of the item. Powder; tablets; capsule.)
-
getIngredient
public List<Medication.MedicationIngredientComponent> getIngredient()
- Returns:
ingredient
(Identifies a particular constituent of interest in the product.)
-
setIngredient
public Medication setIngredient(List<Medication.MedicationIngredientComponent> theIngredient)
- Returns:
- Returns a reference to
this
for easy method chaining
-
hasIngredient
public boolean hasIngredient()
-
addIngredient
public Medication.MedicationIngredientComponent addIngredient()
-
addIngredient
public Medication addIngredient(Medication.MedicationIngredientComponent t)
-
getIngredientFirstRep
public Medication.MedicationIngredientComponent getIngredientFirstRep()
- Returns:
- The first repetition of repeating field
ingredient
, creating it if it does not already exist
-
getPackage
public Medication.MedicationPackageComponent getPackage()
- Returns:
package_
(Information that only applies to packages (not products).)
-
hasPackage
public boolean hasPackage()
-
setPackage
public Medication setPackage(Medication.MedicationPackageComponent value)
- Parameters:
value
-package_
(Information that only applies to packages (not products).)
-
getImage
public List<Attachment> getImage()
- Returns:
image
(Photo(s) or graphic representation(s) of the medication.)
-
setImage
public Medication setImage(List<Attachment> theImage)
- Returns:
- Returns a reference to
this
for easy method chaining
-
hasImage
public boolean hasImage()
-
addImage
public Attachment addImage()
-
addImage
public Medication addImage(Attachment t)
-
getImageFirstRep
public Attachment getImageFirstRep()
- Returns:
- The first repetition of repeating field
image
, creating it if it does not already exist
-
listChildren
protected void listChildren(List<Property> children)
- Overrides:
listChildren
in classDomainResource
-
getNamedProperty
public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws org.hl7.fhir.exceptions.FHIRException
- Overrides:
getNamedProperty
in classDomainResource
- 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 classDomainResource
- 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 classDomainResource
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
setProperty
public Base setProperty(String name, Base value) throws org.hl7.fhir.exceptions.FHIRException
- Overrides:
setProperty
in classDomainResource
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
makeProperty
public Base makeProperty(int hash, String name) throws org.hl7.fhir.exceptions.FHIRException
- Overrides:
makeProperty
in classDomainResource
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
getTypesForProperty
public String[] getTypesForProperty(int hash, String name) throws org.hl7.fhir.exceptions.FHIRException
- Overrides:
getTypesForProperty
in classDomainResource
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
addChild
public Base addChild(String name) throws org.hl7.fhir.exceptions.FHIRException
- Overrides:
addChild
in classDomainResource
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
fhirType
public String fhirType()
- Specified by:
fhirType
in interfaceorg.hl7.fhir.instance.model.api.IBase
- Overrides:
fhirType
in classDomainResource
-
copy
public Medication copy()
- Specified by:
copy
in classDomainResource
-
typedCopy
protected Medication typedCopy()
-
equalsDeep
public boolean equalsDeep(Base other_)
- Overrides:
equalsDeep
in classDomainResource
-
equalsShallow
public boolean equalsShallow(Base other_)
- Overrides:
equalsShallow
in classDomainResource
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty
in interfaceorg.hl7.fhir.instance.model.api.IBase
- Overrides:
isEmpty
in classDomainResource
-
getResourceType
public ResourceType getResourceType()
- Specified by:
getResourceType
in classResource
-
-