Class MedicinalProductPackaged.PackageItem.Builder
- java.lang.Object
-
- com.ibm.fhir.model.builder.AbstractBuilder<Element>
-
- com.ibm.fhir.model.type.Element.Builder
-
- com.ibm.fhir.model.type.BackboneElement.Builder
-
- com.ibm.fhir.model.resource.MedicinalProductPackaged.PackageItem.Builder
-
- Enclosing class:
- MedicinalProductPackaged.PackageItem
public static class MedicinalProductPackaged.PackageItem.Builder extends BackboneElement.Builder
-
-
Field Summary
-
Fields inherited from class com.ibm.fhir.model.type.BackboneElement.Builder
modifierExtension
-
Fields inherited from class com.ibm.fhir.model.type.Element.Builder
extension, id
-
Fields inherited from class com.ibm.fhir.model.builder.AbstractBuilder
validating
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description MedicinalProductPackaged.PackageItem.Builder
alternateMaterial(CodeableConcept... alternateMaterial)
A possible alternate material for the packaging.MedicinalProductPackaged.PackageItem.Builder
alternateMaterial(Collection<CodeableConcept> alternateMaterial)
A possible alternate material for the packaging.MedicinalProductPackaged.PackageItem
build()
Build theMedicinalProductPackaged.PackageItem
MedicinalProductPackaged.PackageItem.Builder
device(Reference... device)
A device accompanying a medicinal product.MedicinalProductPackaged.PackageItem.Builder
device(Collection<Reference> device)
A device accompanying a medicinal product.MedicinalProductPackaged.PackageItem.Builder
extension(Extension... extension)
May be used to represent additional information that is not part of the basic definition of the element.MedicinalProductPackaged.PackageItem.Builder
extension(Collection<Extension> extension)
May be used to represent additional information that is not part of the basic definition of the element.protected MedicinalProductPackaged.PackageItem.Builder
from(MedicinalProductPackaged.PackageItem packageItem)
MedicinalProductPackaged.PackageItem.Builder
id(String id)
Unique id for the element within a resource (for internal references).MedicinalProductPackaged.PackageItem.Builder
identifier(Identifier... identifier)
Including possibly Data Carrier Identifier.MedicinalProductPackaged.PackageItem.Builder
identifier(Collection<Identifier> identifier)
Including possibly Data Carrier Identifier.MedicinalProductPackaged.PackageItem.Builder
manufacturedItem(Reference... manufacturedItem)
The manufactured item as contained in the packaged medicinal product.MedicinalProductPackaged.PackageItem.Builder
manufacturedItem(Collection<Reference> manufacturedItem)
The manufactured item as contained in the packaged medicinal product.MedicinalProductPackaged.PackageItem.Builder
manufacturer(Reference... manufacturer)
Manufacturer of this Package Item.MedicinalProductPackaged.PackageItem.Builder
manufacturer(Collection<Reference> manufacturer)
Manufacturer of this Package Item.MedicinalProductPackaged.PackageItem.Builder
material(CodeableConcept... material)
Material type of the package item.MedicinalProductPackaged.PackageItem.Builder
material(Collection<CodeableConcept> material)
Material type of the package item.MedicinalProductPackaged.PackageItem.Builder
modifierExtension(Extension... modifierExtension)
May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants.MedicinalProductPackaged.PackageItem.Builder
modifierExtension(Collection<Extension> modifierExtension)
May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants.MedicinalProductPackaged.PackageItem.Builder
otherCharacteristics(CodeableConcept... otherCharacteristics)
Other codeable characteristics.MedicinalProductPackaged.PackageItem.Builder
otherCharacteristics(Collection<CodeableConcept> otherCharacteristics)
Other codeable characteristics.MedicinalProductPackaged.PackageItem.Builder
packageItem(MedicinalProductPackaged.PackageItem... packageItem)
Allows containers within containers.MedicinalProductPackaged.PackageItem.Builder
packageItem(Collection<MedicinalProductPackaged.PackageItem> packageItem)
Allows containers within containers.MedicinalProductPackaged.PackageItem.Builder
physicalCharacteristics(ProdCharacteristic physicalCharacteristics)
Dimensions, color etc.MedicinalProductPackaged.PackageItem.Builder
quantity(Quantity quantity)
The quantity of this package in the medicinal product, at the current level of packaging.MedicinalProductPackaged.PackageItem.Builder
shelfLifeStorage(ProductShelfLife... shelfLifeStorage)
Shelf Life and storage information.MedicinalProductPackaged.PackageItem.Builder
shelfLifeStorage(Collection<ProductShelfLife> shelfLifeStorage)
Shelf Life and storage information.MedicinalProductPackaged.PackageItem.Builder
type(CodeableConcept type)
The physical type of the container of the medicine.protected void
validate(MedicinalProductPackaged.PackageItem packageItem)
-
Methods inherited from class com.ibm.fhir.model.type.BackboneElement.Builder
from, validate
-
Methods inherited from class com.ibm.fhir.model.type.Element.Builder
from, validate
-
Methods inherited from class com.ibm.fhir.model.builder.AbstractBuilder
isValidating, setValidating
-
-
-
-
Method Detail
-
id
public MedicinalProductPackaged.PackageItem.Builder id(String id)
Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.- Overrides:
id
in classBackboneElement.Builder
- Parameters:
id
- Unique id for inter-element referencing- Returns:
- A reference to this Builder instance
-
extension
public MedicinalProductPackaged.PackageItem.Builder extension(Extension... extension)
May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Overrides:
extension
in classBackboneElement.Builder
- Parameters:
extension
- Additional content defined by implementations- Returns:
- A reference to this Builder instance
-
extension
public MedicinalProductPackaged.PackageItem.Builder extension(Collection<Extension> extension)
May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.Replaces the existing list with a new one containing elements from the Collection. If any of the elements are null, calling
build()
will fail.- Overrides:
extension
in classBackboneElement.Builder
- Parameters:
extension
- Additional content defined by implementations- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
modifierExtension
public MedicinalProductPackaged.PackageItem.Builder modifierExtension(Extension... modifierExtension)
May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Overrides:
modifierExtension
in classBackboneElement.Builder
- Parameters:
modifierExtension
- Extensions that cannot be ignored even if unrecognized- Returns:
- A reference to this Builder instance
-
modifierExtension
public MedicinalProductPackaged.PackageItem.Builder modifierExtension(Collection<Extension> modifierExtension)
May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
Replaces the existing list with a new one containing elements from the Collection. If any of the elements are null, calling
build()
will fail.- Overrides:
modifierExtension
in classBackboneElement.Builder
- Parameters:
modifierExtension
- Extensions that cannot be ignored even if unrecognized- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
identifier
public MedicinalProductPackaged.PackageItem.Builder identifier(Identifier... identifier)
Including possibly Data Carrier Identifier.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
identifier
- Including possibly Data Carrier Identifier- Returns:
- A reference to this Builder instance
-
identifier
public MedicinalProductPackaged.PackageItem.Builder identifier(Collection<Identifier> identifier)
Including possibly Data Carrier Identifier.Replaces the existing list with a new one containing elements from the Collection. If any of the elements are null, calling
build()
will fail.- Parameters:
identifier
- Including possibly Data Carrier Identifier- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
type
public MedicinalProductPackaged.PackageItem.Builder type(CodeableConcept type)
The physical type of the container of the medicine.This element is required.
- Parameters:
type
- The physical type of the container of the medicine- Returns:
- A reference to this Builder instance
-
quantity
public MedicinalProductPackaged.PackageItem.Builder quantity(Quantity quantity)
The quantity of this package in the medicinal product, at the current level of packaging. The outermost is always 1.This element is required.
- Parameters:
quantity
- The quantity of this package in the medicinal product, at the current level of packaging. The outermost is always 1- Returns:
- A reference to this Builder instance
-
material
public MedicinalProductPackaged.PackageItem.Builder material(CodeableConcept... material)
Material type of the package item.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
material
- Material type of the package item- Returns:
- A reference to this Builder instance
-
material
public MedicinalProductPackaged.PackageItem.Builder material(Collection<CodeableConcept> material)
Material type of the package item.Replaces the existing list with a new one containing elements from the Collection. If any of the elements are null, calling
build()
will fail.- Parameters:
material
- Material type of the package item- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
alternateMaterial
public MedicinalProductPackaged.PackageItem.Builder alternateMaterial(CodeableConcept... alternateMaterial)
A possible alternate material for the packaging.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
alternateMaterial
- A possible alternate material for the packaging- Returns:
- A reference to this Builder instance
-
alternateMaterial
public MedicinalProductPackaged.PackageItem.Builder alternateMaterial(Collection<CodeableConcept> alternateMaterial)
A possible alternate material for the packaging.Replaces the existing list with a new one containing elements from the Collection. If any of the elements are null, calling
build()
will fail.- Parameters:
alternateMaterial
- A possible alternate material for the packaging- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
device
public MedicinalProductPackaged.PackageItem.Builder device(Reference... device)
A device accompanying a medicinal product.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.Allowed resource types for the references:
- Parameters:
device
- A device accompanying a medicinal product- Returns:
- A reference to this Builder instance
-
device
public MedicinalProductPackaged.PackageItem.Builder device(Collection<Reference> device)
A device accompanying a medicinal product.Replaces the existing list with a new one containing elements from the Collection. If any of the elements are null, calling
build()
will fail.Allowed resource types for the references:
- Parameters:
device
- A device accompanying a medicinal product- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
manufacturedItem
public MedicinalProductPackaged.PackageItem.Builder manufacturedItem(Reference... manufacturedItem)
The manufactured item as contained in the packaged medicinal product.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.Allowed resource types for the references:
- Parameters:
manufacturedItem
- The manufactured item as contained in the packaged medicinal product- Returns:
- A reference to this Builder instance
-
manufacturedItem
public MedicinalProductPackaged.PackageItem.Builder manufacturedItem(Collection<Reference> manufacturedItem)
The manufactured item as contained in the packaged medicinal product.Replaces the existing list with a new one containing elements from the Collection. If any of the elements are null, calling
build()
will fail.Allowed resource types for the references:
- Parameters:
manufacturedItem
- The manufactured item as contained in the packaged medicinal product- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
packageItem
public MedicinalProductPackaged.PackageItem.Builder packageItem(MedicinalProductPackaged.PackageItem... packageItem)
Allows containers within containers.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
packageItem
- Allows containers within containers- Returns:
- A reference to this Builder instance
-
packageItem
public MedicinalProductPackaged.PackageItem.Builder packageItem(Collection<MedicinalProductPackaged.PackageItem> packageItem)
Allows containers within containers.Replaces the existing list with a new one containing elements from the Collection. If any of the elements are null, calling
build()
will fail.- Parameters:
packageItem
- Allows containers within containers- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
physicalCharacteristics
public MedicinalProductPackaged.PackageItem.Builder physicalCharacteristics(ProdCharacteristic physicalCharacteristics)
Dimensions, color etc.- Parameters:
physicalCharacteristics
- Dimensions, color etc.- Returns:
- A reference to this Builder instance
-
otherCharacteristics
public MedicinalProductPackaged.PackageItem.Builder otherCharacteristics(CodeableConcept... otherCharacteristics)
Other codeable characteristics.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
otherCharacteristics
- Other codeable characteristics- Returns:
- A reference to this Builder instance
-
otherCharacteristics
public MedicinalProductPackaged.PackageItem.Builder otherCharacteristics(Collection<CodeableConcept> otherCharacteristics)
Other codeable characteristics.Replaces the existing list with a new one containing elements from the Collection. If any of the elements are null, calling
build()
will fail.- Parameters:
otherCharacteristics
- Other codeable characteristics- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
shelfLifeStorage
public MedicinalProductPackaged.PackageItem.Builder shelfLifeStorage(ProductShelfLife... shelfLifeStorage)
Shelf Life and storage information.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
shelfLifeStorage
- Shelf Life and storage information- Returns:
- A reference to this Builder instance
-
shelfLifeStorage
public MedicinalProductPackaged.PackageItem.Builder shelfLifeStorage(Collection<ProductShelfLife> shelfLifeStorage)
Shelf Life and storage information.Replaces the existing list with a new one containing elements from the Collection. If any of the elements are null, calling
build()
will fail.- Parameters:
shelfLifeStorage
- Shelf Life and storage information- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
manufacturer
public MedicinalProductPackaged.PackageItem.Builder manufacturer(Reference... manufacturer)
Manufacturer of this Package Item.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.Allowed resource types for the references:
- Parameters:
manufacturer
- Manufacturer of this Package Item- Returns:
- A reference to this Builder instance
-
manufacturer
public MedicinalProductPackaged.PackageItem.Builder manufacturer(Collection<Reference> manufacturer)
Manufacturer of this Package Item.Replaces the existing list with a new one containing elements from the Collection. If any of the elements are null, calling
build()
will fail.Allowed resource types for the references:
- Parameters:
manufacturer
- Manufacturer of this Package Item- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
build
public MedicinalProductPackaged.PackageItem build()
- Specified by:
build
in interfaceBuilder<Element>
- Specified by:
build
in classBackboneElement.Builder
- Returns:
- An immutable object of type
MedicinalProductPackaged.PackageItem
- Throws:
IllegalStateException
- if the current state cannot be built into a valid PackageItem per the base specification
-
validate
protected void validate(MedicinalProductPackaged.PackageItem packageItem)
-
from
protected MedicinalProductPackaged.PackageItem.Builder from(MedicinalProductPackaged.PackageItem packageItem)
-
-