Data Model Libraries
    Preparing search index...

    Substance Class

    A homogeneous material with a definite composition.

    FHIR Specification

    • Short: A homogeneous material with a definite composition
    • Definition: A homogeneous material with a definite composition.
    • FHIR Version: 5.0.0

    Hierarchy (View Summary)

    Implements

    Index

    Constructors

    Properties

    Methods

    parse getIdentifier setIdentifier addIdentifier hasIdentifier getInstanceElement setInstanceElement hasInstanceElement getInstance setInstance hasInstance getStatusEnumType setStatusEnumType hasStatusEnumType getStatusElement setStatusElement hasStatusElement getStatus setStatus hasStatus getCategory setCategory addCategory hasCategory getCode setCode hasCode getDescriptionElement setDescriptionElement hasDescriptionElement getDescription setDescription hasDescription getExpiryElement setExpiryElement hasExpiryElement getExpiry setExpiry hasExpiry getQuantity setQuantity hasQuantity getIngredient setIngredient addIngredient hasIngredient fhirType isEmpty isRequiredFieldsEmpty copy toJSON getText setText hasText getContained setContained addContained hasContained getExtension setExtension hasExtension getExtensionByUrl addExtension removeExtension getModifierExtension setModifierExtension hasModifierExtension getModifierExtensionByUrl addModifierExtension removeModifierExtension resourceType getIdElement setIdElement hasIdElement getId setId hasId getMeta setMeta hasMeta getImplicitRulesElement setImplicitRulesElement hasImplicitRulesElement getImplicitRules setImplicitRules hasImplicitRules getLanguageElement setLanguageElement hasLanguageElement getLanguage setLanguage hasLanguage isResource isDataType isComplexDataType isPrimitive isBooleanPrimitive isStringPrimitive isNumberPrimitive isBigIntPrimitive isDateTimePrimitive copyValues initIdentifier initCategory initIngredient

    Constructors

    Properties

    identifier?: Identifier[]

    Substance.identifier Element

    FHIR Specification

    • Short: Unique identifier
    • Definition: Unique identifier for the substance. For an instance, an identifier associated with the package/container (usually a label affixed directly).
    • FHIR Type: Identifier
    • Cardinality: 0..*
    • isModifier: false
    • isSummary: true
    instance_: null | BooleanType

    Substance.instance Element

    FHIR Specification

    • Short: Is this an instance of a substance or a kind of one
    • Definition: A boolean to indicate if this an instance of a substance or a kind of one (a definition).
    • FHIR Type: boolean
    • Cardinality: 1..1
    • isModifier: true
    • isModifierReason: Not known why this is labelled a modifier
    • isSummary: true
    substanceStatusEnum: SubstanceStatusEnum

    FHIR CodeSystem: SubstanceStatus

    status?: EnumCodeType

    Substance.status Element

    FHIR Specification

    • Short: active | inactive | entered-in-error
    • Definition: A code to indicate if the substance is actively used.
    • FHIR Type: code
    • Cardinality: 0..1
    • isModifier: true
    • isModifierReason: This element is labelled as a modifier because it is a status element that contains status entered-in-error which means that the resource should not be treated as valid
    • isSummary: true

    CodeSystem Enumeration: SubstanceStatusEnum

    category?: CodeableConcept[]

    Substance.category Element

    FHIR Specification

    • Short: What class/type of substance this is
    • Definition: A code that classifies the general type of substance. This is used for searching, sorting and display purposes.
    • Comment: The level of granularity is defined by the category concepts in the value set. More fine-grained filtering can be performed using the metadata and/or terminology hierarchy in Substance.code.
    • FHIR Type: CodeableConcept
    • Cardinality: 0..*
    • isModifier: false
    • isSummary: true
    code: null | CodeableReference

    Substance.code Element

    FHIR Specification

    • Short: What substance this is
    • Definition: A code (or set of codes) that identify this substance.
    • Comment: This could be a reference to an externally defined code. It could also be a locally assigned code (e.g. a formulary), optionally with translations to the standard drug codes.
    • FHIR Type: CodeableReference
    • Cardinality: 1..1
    • isModifier: false
    • isSummary: true
    description?: MarkdownType

    Substance.description Element

    FHIR Specification

    • Short: Textual description of the substance, comments
    • Definition: A description of the substance - its appearance, handling requirements, and other usage notes.
    • FHIR Type: markdown
    • Cardinality: 0..1
    • isModifier: false
    • isSummary: true
    expiry?: DateTimeType

    Substance.expiry Element

    FHIR Specification

    • Short: When no longer valid to use
    • Definition: When the substance is no longer valid to use. For some substances, a single arbitrary date is used for expiry.
    • FHIR Type: dateTime
    • Cardinality: 0..1
    • isModifier: false
    • isSummary: true
    quantity?: Quantity

    Substance.quantity Element

    FHIR Specification

    • Short: Amount of substance in the package
    • Definition: The amount of the substance.
    • FHIR Type: Quantity
    • Cardinality: 0..1
    • isModifier: false
    • isSummary: true

    Substance.ingredient Element

    FHIR Specification

    • Short: Composition information about the substance
    • Definition: A substance can be composed of other substances.
    • FHIR Type: BackboneElement
    • Cardinality: 0..*
    • isModifier: false
    • isSummary: true

    Methods

    • Parse the provided Substance JSON to instantiate the Substance data model.

      Parameters

      • sourceJson: Value

        JSON representing FHIR Substance

      • OptionaloptSourceField: string

        Optional data source field (e.g. <complexTypeName>.<complexTypeFieldName>); defaults to Substance

      Returns undefined | Substance

      Substance data model or undefined for Substance

      JsonError if the provided JSON is not a valid JSON object

    • Assigns the provided value to the text property.

      Parameters

      Returns this

      this

    • Returns boolean

      true if the text property exists and has a value; false otherwise

    • Assigns the provided Resource array value to the contained property.

      Parameters

      • value: undefined | IResource[]

        the contained array value

      Returns this

      this

    • Returns boolean

      true if the contained property exists and has a value; false otherwise

    • Assigns the provided array of Extension values to the extension property.

      Parameters

      • extension: undefined | IExtension[]

        array of Extensions

      Returns this

      this

    • Determines if the extension property exists.

      Parameters

      • Optionalurl: string

        the url that identifies a specific Extension

      Returns boolean

      true if an Extension has the provided url; false otherwise

      If the url is provided, determines if an Extension having the provided url exists. If the url is not provided, determines if the extension property exists and has any values.

      AssertionError for invalid url

    • Adds the provided Extension to the extension property array.

      Parameters

      • extension: undefined | IExtension

        the Extension value to add to the extension property array

      Returns this

      this

    • Removes the Extension having the provided url from the extension property array.

      Parameters

      • url: string

        the url that identifies a specific Extension to remove

      Returns void

      AssertionError for invalid url

    • Determines if the modifierExtension property exists.

      Parameters

      • Optionalurl: string

        the url that identifies a specific Extension

      Returns boolean

      true if an Extension has the provided url

      If the url is provided, determines if an Extension having the provided url exists. If the url is not provided, determines if the modifierExtension property exists and has any values.

      AssertionError for invalid url

    • Assigns the provided PrimitiveType value to the id property.

      Parameters

      • element: undefined | IdType

        the id value

      Returns this

      this

    • Returns undefined | string

      the id property value as a primitive value

    • Assigns the provided primitive value to the id property.

      Parameters

      • value: undefined | string

        the id value

      Returns this

      this

      PrimitiveTypeError for invalid primitive types

    • Returns boolean

      true if the id property exists and has a value; false otherwise

    • Assigns the provided value to the meta property.

      Parameters

      • value: undefined | Meta

        the meta value

      Returns this

      this

    • Returns boolean

      true if the meta property exists and has a value; false otherwise

    • Assigns the provided primitive value to the implicitRules property.

      Parameters

      • value: undefined | string

        the implicitRules value

      Returns this

      this

      PrimitiveTypeError for invalid primitive types

    • Returns undefined | string

      the language property value as a primitive value

    • Assigns the provided primitive value to the language property.

      Parameters

      • value: undefined | string

        the language value

      Returns this

      this

      PrimitiveTypeError for invalid primitive types

    • Returns boolean

      true if the language property exists and has a value; false otherwise

    • Returns boolean

      true if the instance is a FHIR complex or primitive datatype; false otherwise