Class Encounter.Builder
- java.lang.Object
-
- org.linuxforhealth.fhir.model.builder.AbstractBuilder<Resource>
-
- org.linuxforhealth.fhir.model.resource.Resource.Builder
-
- org.linuxforhealth.fhir.model.resource.DomainResource.Builder
-
- org.linuxforhealth.fhir.model.resource.Encounter.Builder
-
- Enclosing class:
- Encounter
public static class Encounter.Builder extends DomainResource.Builder
-
-
Field Summary
-
Fields inherited from class org.linuxforhealth.fhir.model.resource.DomainResource.Builder
contained, extension, modifierExtension, text
-
Fields inherited from class org.linuxforhealth.fhir.model.resource.Resource.Builder
id, implicitRules, language, meta
-
Fields inherited from class org.linuxforhealth.fhir.model.builder.AbstractBuilder
validating
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Encounter.Builder
account(java.util.Collection<Reference> account)
The set of accounts that may be used for billing for this Encounter.Encounter.Builder
account(Reference... account)
The set of accounts that may be used for billing for this Encounter.Encounter.Builder
appointment(java.util.Collection<Reference> appointment)
The appointment that scheduled this encounter.Encounter.Builder
appointment(Reference... appointment)
The appointment that scheduled this encounter.Encounter.Builder
basedOn(java.util.Collection<Reference> basedOn)
The request this encounter satisfies (e.g.Encounter.Builder
basedOn(Reference... basedOn)
The request this encounter satisfies (e.g.Encounter
build()
Build theEncounter
Encounter.Builder
classHistory(java.util.Collection<Encounter.ClassHistory> classHistory)
The class history permits the tracking of the encounters transitions without needing to go through the resource history.Encounter.Builder
classHistory(Encounter.ClassHistory... classHistory)
The class history permits the tracking of the encounters transitions without needing to go through the resource history.Encounter.Builder
clazz(Coding clazz)
Concepts representing classification of patient encounter such as ambulatory (outpatient), inpatient, emergency, home health or others due to local variations.Encounter.Builder
contained(java.util.Collection<Resource> contained)
These resources do not have an independent existence apart from the resource that contains them - they cannot be identified independently, and nor can they have their own independent transaction scope.Encounter.Builder
contained(Resource... contained)
These resources do not have an independent existence apart from the resource that contains them - they cannot be identified independently, and nor can they have their own independent transaction scope.Encounter.Builder
diagnosis(java.util.Collection<Encounter.Diagnosis> diagnosis)
The list of diagnosis relevant to this encounter.Encounter.Builder
diagnosis(Encounter.Diagnosis... diagnosis)
The list of diagnosis relevant to this encounter.Encounter.Builder
episodeOfCare(java.util.Collection<Reference> episodeOfCare)
Where a specific encounter should be classified as a part of a specific episode(s) of care this field should be used.Encounter.Builder
episodeOfCare(Reference... episodeOfCare)
Where a specific encounter should be classified as a part of a specific episode(s) of care this field should be used.Encounter.Builder
extension(java.util.Collection<Extension> extension)
May be used to represent additional information that is not part of the basic definition of the resource.Encounter.Builder
extension(Extension... extension)
May be used to represent additional information that is not part of the basic definition of the resource.protected Encounter.Builder
from(Encounter encounter)
Encounter.Builder
hospitalization(Encounter.Hospitalization hospitalization)
Details about the admission to a healthcare service.Encounter.Builder
id(java.lang.String id)
The logical id of the resource, as used in the URL for the resource.Encounter.Builder
identifier(java.util.Collection<Identifier> identifier)
Identifier(s) by which this encounter is known.Encounter.Builder
identifier(Identifier... identifier)
Identifier(s) by which this encounter is known.Encounter.Builder
implicitRules(Uri implicitRules)
A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content.Encounter.Builder
language(Code language)
The base language in which the resource is written.Encounter.Builder
length(Duration length)
Quantity of time the encounter lasted.Encounter.Builder
location(java.util.Collection<Encounter.Location> location)
List of locations where the patient has been during this encounter.Encounter.Builder
location(Encounter.Location... location)
List of locations where the patient has been during this encounter.Encounter.Builder
meta(Meta meta)
The metadata about the resource.Encounter.Builder
modifierExtension(java.util.Collection<Extension> modifierExtension)
May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants.Encounter.Builder
modifierExtension(Extension... modifierExtension)
May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants.Encounter.Builder
participant(java.util.Collection<Encounter.Participant> participant)
The list of people responsible for providing the service.Encounter.Builder
participant(Encounter.Participant... participant)
The list of people responsible for providing the service.Encounter.Builder
partOf(Reference partOf)
Another Encounter of which this encounter is a part of (administratively or in time).Encounter.Builder
period(Period period)
The start and end time of the encounter.Encounter.Builder
priority(CodeableConcept priority)
Indicates the urgency of the encounter.Encounter.Builder
reasonCode(java.util.Collection<CodeableConcept> reasonCode)
Reason the encounter takes place, expressed as a code.Encounter.Builder
reasonCode(CodeableConcept... reasonCode)
Reason the encounter takes place, expressed as a code.Encounter.Builder
reasonReference(java.util.Collection<Reference> reasonReference)
Reason the encounter takes place, expressed as a code.Encounter.Builder
reasonReference(Reference... reasonReference)
Reason the encounter takes place, expressed as a code.Encounter.Builder
serviceProvider(Reference serviceProvider)
The organization that is primarily responsible for this Encounter's services.Encounter.Builder
serviceType(CodeableConcept serviceType)
Broad categorization of the service that is to be provided (e.g.Encounter.Builder
status(EncounterStatus status)
planned | arrived | triaged | in-progress | onleave | finished | cancelled +.Encounter.Builder
statusHistory(java.util.Collection<Encounter.StatusHistory> statusHistory)
The status history permits the encounter resource to contain the status history without needing to read through the historical versions of the resource, or even have the server store them.Encounter.Builder
statusHistory(Encounter.StatusHistory... statusHistory)
The status history permits the encounter resource to contain the status history without needing to read through the historical versions of the resource, or even have the server store them.Encounter.Builder
subject(Reference subject)
The patient or group present at the encounter.Encounter.Builder
text(Narrative text)
A human-readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human.Encounter.Builder
type(java.util.Collection<CodeableConcept> type)
Specific type of encounter (e.g.Encounter.Builder
type(CodeableConcept... type)
Specific type of encounter (e.g.protected void
validate(Encounter encounter)
-
Methods inherited from class org.linuxforhealth.fhir.model.resource.DomainResource.Builder
from, validate
-
Methods inherited from class org.linuxforhealth.fhir.model.resource.Resource.Builder
from, validate
-
Methods inherited from class org.linuxforhealth.fhir.model.builder.AbstractBuilder
isValidating, setValidating
-
-
-
-
Method Detail
-
id
public Encounter.Builder id(java.lang.String id)
The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes.- Overrides:
id
in classDomainResource.Builder
- Parameters:
id
- Logical id of this artifact- Returns:
- A reference to this Builder instance
-
meta
public Encounter.Builder meta(Meta meta)
The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.- Overrides:
meta
in classDomainResource.Builder
- Parameters:
meta
- Metadata about the resource- Returns:
- A reference to this Builder instance
-
implicitRules
public Encounter.Builder implicitRules(Uri implicitRules)
A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc.- Overrides:
implicitRules
in classDomainResource.Builder
- Parameters:
implicitRules
- A set of rules under which this content was created- Returns:
- A reference to this Builder instance
-
language
public Encounter.Builder language(Code language)
The base language in which the resource is written.- Overrides:
language
in classDomainResource.Builder
- Parameters:
language
- Language of the resource content- Returns:
- A reference to this Builder instance
-
text
public Encounter.Builder text(Narrative text)
A human-readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it "clinically safe" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.- Overrides:
text
in classDomainResource.Builder
- Parameters:
text
- Text summary of the resource, for human interpretation- Returns:
- A reference to this Builder instance
-
contained
public Encounter.Builder contained(Resource... contained)
These resources do not have an independent existence apart from the resource that contains them - they cannot be identified independently, and nor can they have their own independent transaction scope.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Overrides:
contained
in classDomainResource.Builder
- Parameters:
contained
- Contained, inline Resources- Returns:
- A reference to this Builder instance
-
contained
public Encounter.Builder contained(java.util.Collection<Resource> contained)
These resources do not have an independent existence apart from the resource that contains them - they cannot be identified independently, and nor can they have their own independent transaction scope.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:
contained
in classDomainResource.Builder
- Parameters:
contained
- Contained, inline Resources- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
extension
public Encounter.Builder extension(Extension... extension)
May be used to represent additional information that is not part of the basic definition of the resource. 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 classDomainResource.Builder
- Parameters:
extension
- Additional content defined by implementations- Returns:
- A reference to this Builder instance
-
extension
public Encounter.Builder extension(java.util.Collection<Extension> extension)
May be used to represent additional information that is not part of the basic definition of the resource. 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 classDomainResource.Builder
- Parameters:
extension
- Additional content defined by implementations- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
modifierExtension
public Encounter.Builder modifierExtension(Extension... modifierExtension)
May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it 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 is allowed to 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 classDomainResource.Builder
- Parameters:
modifierExtension
- Extensions that cannot be ignored- Returns:
- A reference to this Builder instance
-
modifierExtension
public Encounter.Builder modifierExtension(java.util.Collection<Extension> modifierExtension)
May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it 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 is allowed to 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 classDomainResource.Builder
- Parameters:
modifierExtension
- Extensions that cannot be ignored- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
identifier
public Encounter.Builder identifier(Identifier... identifier)
Identifier(s) by which this encounter is known.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
identifier
- Identifier(s) by which this encounter is known- Returns:
- A reference to this Builder instance
-
identifier
public Encounter.Builder identifier(java.util.Collection<Identifier> identifier)
Identifier(s) by which this encounter is known.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
- Identifier(s) by which this encounter is known- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
status
public Encounter.Builder status(EncounterStatus status)
planned | arrived | triaged | in-progress | onleave | finished | cancelled +.This element is required.
- Parameters:
status
- planned | arrived | triaged | in-progress | onleave | finished | cancelled +- Returns:
- A reference to this Builder instance
-
statusHistory
public Encounter.Builder statusHistory(Encounter.StatusHistory... statusHistory)
The status history permits the encounter resource to contain the status history without needing to read through the historical versions of the resource, or even have the server store them.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
statusHistory
- List of past encounter statuses- Returns:
- A reference to this Builder instance
-
statusHistory
public Encounter.Builder statusHistory(java.util.Collection<Encounter.StatusHistory> statusHistory)
The status history permits the encounter resource to contain the status history without needing to read through the historical versions of the resource, or even have the server store them.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:
statusHistory
- List of past encounter statuses- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
clazz
public Encounter.Builder clazz(Coding clazz)
Concepts representing classification of patient encounter such as ambulatory (outpatient), inpatient, emergency, home health or others due to local variations.This element is required.
- Parameters:
clazz
- Classification of patient encounter- Returns:
- A reference to this Builder instance
-
classHistory
public Encounter.Builder classHistory(Encounter.ClassHistory... classHistory)
The class history permits the tracking of the encounters transitions without needing to go through the resource history. This would be used for a case where an admission starts of as an emergency encounter, then transitions into an inpatient scenario. Doing this and not restarting a new encounter ensures that any lab/diagnostic results can more easily follow the patient and not require re-processing and not get lost or cancelled during a kind of discharge from emergency to inpatient.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
classHistory
- List of past encounter classes- Returns:
- A reference to this Builder instance
-
classHistory
public Encounter.Builder classHistory(java.util.Collection<Encounter.ClassHistory> classHistory)
The class history permits the tracking of the encounters transitions without needing to go through the resource history. This would be used for a case where an admission starts of as an emergency encounter, then transitions into an inpatient scenario. Doing this and not restarting a new encounter ensures that any lab/diagnostic results can more easily follow the patient and not require re-processing and not get lost or cancelled during a kind of discharge from emergency to inpatient.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:
classHistory
- List of past encounter classes- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
type
public Encounter.Builder type(CodeableConcept... type)
Specific type of encounter (e.g. e-mail consultation, surgical day-care, skilled nursing, rehabilitation).Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
type
- Specific type of encounter- Returns:
- A reference to this Builder instance
-
type
public Encounter.Builder type(java.util.Collection<CodeableConcept> type)
Specific type of encounter (e.g. e-mail consultation, surgical day-care, skilled nursing, rehabilitation).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:
type
- Specific type of encounter- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
serviceType
public Encounter.Builder serviceType(CodeableConcept serviceType)
Broad categorization of the service that is to be provided (e.g. cardiology).- Parameters:
serviceType
- Specific type of service- Returns:
- A reference to this Builder instance
-
priority
public Encounter.Builder priority(CodeableConcept priority)
Indicates the urgency of the encounter.- Parameters:
priority
- Indicates the urgency of the encounter- Returns:
- A reference to this Builder instance
-
subject
public Encounter.Builder subject(Reference subject)
The patient or group present at the encounter.Allowed resource types for this reference:
- Parameters:
subject
- The patient or group present at the encounter- Returns:
- A reference to this Builder instance
-
episodeOfCare
public Encounter.Builder episodeOfCare(Reference... episodeOfCare)
Where a specific encounter should be classified as a part of a specific episode(s) of care this field should be used. This association can facilitate grouping of related encounters together for a specific purpose, such as government reporting, issue tracking, association via a common problem. The association is recorded on the encounter as these are typically created after the episode of care and grouped on entry rather than editing the episode of care to append another encounter to it (the episode of care could span years).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:
episodeOfCare
- Episode(s) of care that this encounter should be recorded against- Returns:
- A reference to this Builder instance
-
episodeOfCare
public Encounter.Builder episodeOfCare(java.util.Collection<Reference> episodeOfCare)
Where a specific encounter should be classified as a part of a specific episode(s) of care this field should be used. This association can facilitate grouping of related encounters together for a specific purpose, such as government reporting, issue tracking, association via a common problem. The association is recorded on the encounter as these are typically created after the episode of care and grouped on entry rather than editing the episode of care to append another encounter to it (the episode of care could span years).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:
episodeOfCare
- Episode(s) of care that this encounter should be recorded against- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
basedOn
public Encounter.Builder basedOn(Reference... basedOn)
The request this encounter satisfies (e.g. incoming referral or procedure request).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:
basedOn
- The ServiceRequest that initiated this encounter- Returns:
- A reference to this Builder instance
-
basedOn
public Encounter.Builder basedOn(java.util.Collection<Reference> basedOn)
The request this encounter satisfies (e.g. incoming referral or procedure request).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:
basedOn
- The ServiceRequest that initiated this encounter- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
participant
public Encounter.Builder participant(Encounter.Participant... participant)
The list of people responsible for providing the service.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
participant
- List of participants involved in the encounter- Returns:
- A reference to this Builder instance
-
participant
public Encounter.Builder participant(java.util.Collection<Encounter.Participant> participant)
The list of people responsible for providing the service.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:
participant
- List of participants involved in the encounter- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
appointment
public Encounter.Builder appointment(Reference... appointment)
The appointment that scheduled this encounter.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:
appointment
- The appointment that scheduled this encounter- Returns:
- A reference to this Builder instance
-
appointment
public Encounter.Builder appointment(java.util.Collection<Reference> appointment)
The appointment that scheduled this encounter.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:
appointment
- The appointment that scheduled this encounter- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
period
public Encounter.Builder period(Period period)
The start and end time of the encounter.- Parameters:
period
- The start and end time of the encounter- Returns:
- A reference to this Builder instance
-
length
public Encounter.Builder length(Duration length)
Quantity of time the encounter lasted. This excludes the time during leaves of absence.- Parameters:
length
- Quantity of time the encounter lasted (less time absent)- Returns:
- A reference to this Builder instance
-
reasonCode
public Encounter.Builder reasonCode(CodeableConcept... reasonCode)
Reason the encounter takes place, expressed as a code. For admissions, this can be used for a coded admission diagnosis.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
reasonCode
- Coded reason the encounter takes place- Returns:
- A reference to this Builder instance
-
reasonCode
public Encounter.Builder reasonCode(java.util.Collection<CodeableConcept> reasonCode)
Reason the encounter takes place, expressed as a code. For admissions, this can be used for a coded admission diagnosis.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:
reasonCode
- Coded reason the encounter takes place- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
reasonReference
public Encounter.Builder reasonReference(Reference... reasonReference)
Reason the encounter takes place, expressed as a code. For admissions, this can be used for a coded admission diagnosis.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:
reasonReference
- Reason the encounter takes place (reference)- Returns:
- A reference to this Builder instance
-
reasonReference
public Encounter.Builder reasonReference(java.util.Collection<Reference> reasonReference)
Reason the encounter takes place, expressed as a code. For admissions, this can be used for a coded admission diagnosis.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:
reasonReference
- Reason the encounter takes place (reference)- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
diagnosis
public Encounter.Builder diagnosis(Encounter.Diagnosis... diagnosis)
The list of diagnosis relevant to this encounter.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
diagnosis
- The list of diagnosis relevant to this encounter- Returns:
- A reference to this Builder instance
-
diagnosis
public Encounter.Builder diagnosis(java.util.Collection<Encounter.Diagnosis> diagnosis)
The list of diagnosis relevant to this encounter.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:
diagnosis
- The list of diagnosis relevant to this encounter- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
account
public Encounter.Builder account(Reference... account)
The set of accounts that may be used for billing for this Encounter.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:
account
- The set of accounts that may be used for billing for this Encounter- Returns:
- A reference to this Builder instance
-
account
public Encounter.Builder account(java.util.Collection<Reference> account)
The set of accounts that may be used for billing for this Encounter.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:
account
- The set of accounts that may be used for billing for this Encounter- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
hospitalization
public Encounter.Builder hospitalization(Encounter.Hospitalization hospitalization)
Details about the admission to a healthcare service.- Parameters:
hospitalization
- Details about the admission to a healthcare service- Returns:
- A reference to this Builder instance
-
location
public Encounter.Builder location(Encounter.Location... location)
List of locations where the patient has been during this encounter.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
location
- List of locations where the patient has been- Returns:
- A reference to this Builder instance
-
location
public Encounter.Builder location(java.util.Collection<Encounter.Location> location)
List of locations where the patient has been during this encounter.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:
location
- List of locations where the patient has been- Returns:
- A reference to this Builder instance
- Throws:
java.lang.NullPointerException
- If the passed collection is null
-
serviceProvider
public Encounter.Builder serviceProvider(Reference serviceProvider)
The organization that is primarily responsible for this Encounter's services. This MAY be the same as the organization on the Patient record, however it could be different, such as if the actor performing the services was from an external organization (which may be billed seperately) for an external consultation. Refer to the example bundle showing an abbreviated set of Encounters for a colonoscopy.Allowed resource types for this reference:
- Parameters:
serviceProvider
- The organization (facility) responsible for this encounter- Returns:
- A reference to this Builder instance
-
partOf
public Encounter.Builder partOf(Reference partOf)
Another Encounter of which this encounter is a part of (administratively or in time).Allowed resource types for this reference:
- Parameters:
partOf
- Another Encounter this encounter is part of- Returns:
- A reference to this Builder instance
-
build
public Encounter build()
-
validate
protected void validate(Encounter encounter)
-
from
protected Encounter.Builder from(Encounter encounter)
-
-