Class Medication
- java.lang.Object
-
- org.linuxforhealth.fhir.model.visitor.AbstractVisitable
-
- org.linuxforhealth.fhir.model.resource.Resource
-
- org.linuxforhealth.fhir.model.resource.DomainResource
-
- org.linuxforhealth.fhir.model.resource.Medication
-
- All Implemented Interfaces:
Visitable
@Generated("org.linuxforhealth.fhir.tools.CodeGenerator") public class Medication extends DomainResource
This resource is primarily used for the identification and definition of a medication for the purposes of prescribing, dispensing, and administering a medication as well as for making statements about medication use.Maturity level: FMM3 (Trial Use)
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Medication.Batch
Information that only applies to packages (not products).static class
Medication.Builder
static class
Medication.Ingredient
Identifies a particular constituent of interest in the product.
-
Field Summary
-
Fields inherited from class org.linuxforhealth.fhir.model.resource.DomainResource
contained, extension, modifierExtension, text
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
accept(java.lang.String elementName, int elementIndex, Visitor visitor)
Accept a Visitor and invoke the appropriate visit methods.static Medication.Builder
builder()
boolean
equals(java.lang.Object obj)
Ratio
getAmount()
Specific amount of the drug in the packaged product.Medication.Batch
getBatch()
Information that only applies to packages (not products).CodeableConcept
getCode()
A code (or set of codes) that specify this medication, or a textual description if no code is available.CodeableConcept
getForm()
Describes the form of the item.java.util.List<Identifier>
getIdentifier()
Business identifier for this medication.java.util.List<Medication.Ingredient>
getIngredient()
Identifies a particular constituent of interest in the product.Reference
getManufacturer()
Describes the details of the manufacturer of the medication product.MedicationStatus
getStatus()
A code to indicate if the medication is in active use.boolean
hasChildren()
int
hashCode()
Medication.Builder
toBuilder()
Create a new Builder from the contents of this Resource-
Methods inherited from class org.linuxforhealth.fhir.model.resource.DomainResource
getContained, getExtension, getModifierExtension, getText
-
Methods inherited from class org.linuxforhealth.fhir.model.resource.Resource
as, getId, getImplicitRules, getLanguage, getMeta, is
-
-
-
-
Method Detail
-
getIdentifier
public java.util.List<Identifier> getIdentifier()
Business identifier for this medication.- Returns:
- An unmodifiable list containing immutable objects of type
Identifier
that may be empty.
-
getCode
public CodeableConcept getCode()
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.- Returns:
- An immutable object of type
CodeableConcept
that may be null.
-
getStatus
public MedicationStatus getStatus()
A code to indicate if the medication is in active use.- Returns:
- An immutable object of type
MedicationStatus
that may be null.
-
getManufacturer
public Reference getManufacturer()
Describes the details of the manufacturer of the medication product. This is not intended to represent the distributor of a medication product.- Returns:
- An immutable object of type
Reference
that may be null.
-
getForm
public CodeableConcept getForm()
Describes the form of the item. Powder; tablets; capsule.- Returns:
- An immutable object of type
CodeableConcept
that may be null.
-
getAmount
public Ratio getAmount()
Specific amount of the drug in the packaged product. For example, when specifying a product that has the same strength (For example, Insulin glargine 100 unit per mL solution for injection), this attribute provides additional clarification of the package amount (For example, 3 mL, 10mL, etc.).- Returns:
- An immutable object of type
Ratio
that may be null.
-
getIngredient
public java.util.List<Medication.Ingredient> getIngredient()
Identifies a particular constituent of interest in the product.- Returns:
- An unmodifiable list containing immutable objects of type
Medication.Ingredient
that may be empty.
-
getBatch
public Medication.Batch getBatch()
Information that only applies to packages (not products).- Returns:
- An immutable object of type
Medication.Batch
that may be null.
-
hasChildren
public boolean hasChildren()
- Overrides:
hasChildren
in classDomainResource
-
accept
public void accept(java.lang.String elementName, int elementIndex, Visitor visitor)
Description copied from interface:Visitable
Accept a Visitor and invoke the appropriate visit methods. A typical implementation would look like this:if (visitor.preVisit(this)) { visitor.visitStart(elementName, elementIndex, this); if (visitor.visit(elementName, elementIndex, this)) { // visit children } visitor.visitEnd(elementName, elementIndex, this); visitor.postVisit(this); }
- Specified by:
accept
in interfaceVisitable
- Specified by:
accept
in classAbstractVisitable
- Parameters:
elementName
- the name of the element in the context of this visitelementIndex
- the index of the element in a list or -1 if it is not contained within a Listvisitor
- the visitor to use
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toBuilder
public Medication.Builder toBuilder()
Description copied from class:Resource
Create a new Builder from the contents of this Resource- Specified by:
toBuilder
in classDomainResource
-
builder
public static Medication.Builder builder()
-
-