Class ServiceRequest.Builder
- java.lang.Object
-
- com.ibm.fhir.model.builder.AbstractBuilder<Resource>
-
- com.ibm.fhir.model.resource.Resource.Builder
-
- com.ibm.fhir.model.resource.DomainResource.Builder
-
- com.ibm.fhir.model.resource.ServiceRequest.Builder
-
- Enclosing class:
- ServiceRequest
public static class ServiceRequest.Builder extends DomainResource.Builder
-
-
Field Summary
-
Fields inherited from class com.ibm.fhir.model.resource.DomainResource.Builder
contained, extension, modifierExtension, text
-
Fields inherited from class com.ibm.fhir.model.resource.Resource.Builder
id, implicitRules, language, meta
-
Fields inherited from class com.ibm.fhir.model.builder.AbstractBuilder
validating
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ServiceRequest.Builder
asNeeded(Element asNeeded)
If a CodeableConcept is present, it indicates the pre-condition for performing the service.ServiceRequest.Builder
authoredOn(DateTime authoredOn)
When the request transitioned to being actionable.ServiceRequest.Builder
basedOn(Reference... basedOn)
Plan/proposal/order fulfilled by this request.ServiceRequest.Builder
basedOn(Collection<Reference> basedOn)
Plan/proposal/order fulfilled by this request.ServiceRequest.Builder
bodySite(CodeableConcept... bodySite)
Anatomic location where the procedure should be performed.ServiceRequest.Builder
bodySite(Collection<CodeableConcept> bodySite)
Anatomic location where the procedure should be performed.ServiceRequest
build()
Build theServiceRequest
ServiceRequest.Builder
category(CodeableConcept... category)
A code that classifies the service for searching, sorting and display purposes (e.g.ServiceRequest.Builder
category(Collection<CodeableConcept> category)
A code that classifies the service for searching, sorting and display purposes (e.g.ServiceRequest.Builder
code(CodeableConcept code)
A code that identifies a particular service (i.e., procedure, diagnostic investigation, or panel of investigations) that have been requested.ServiceRequest.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.ServiceRequest.Builder
contained(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.ServiceRequest.Builder
doNotPerform(Boolean doNotPerform)
Set this to true if the record is saying that the service/procedure should NOT be performed.ServiceRequest.Builder
encounter(Reference encounter)
An encounter that provides additional information about the healthcare context in which this request is made.ServiceRequest.Builder
extension(Extension... extension)
May be used to represent additional information that is not part of the basic definition of the resource.ServiceRequest.Builder
extension(Collection<Extension> extension)
May be used to represent additional information that is not part of the basic definition of the resource.protected ServiceRequest.Builder
from(ServiceRequest serviceRequest)
ServiceRequest.Builder
id(String id)
The logical id of the resource, as used in the URL for the resource.ServiceRequest.Builder
identifier(Identifier... identifier)
Identifiers assigned to this order instance by the orderer and/or the receiver and/or order fulfiller.ServiceRequest.Builder
identifier(Collection<Identifier> identifier)
Identifiers assigned to this order instance by the orderer and/or the receiver and/or order fulfiller.ServiceRequest.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.ServiceRequest.Builder
instantiatesCanonical(Canonical... instantiatesCanonical)
The URL pointing to a FHIR-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this ServiceRequest.ServiceRequest.Builder
instantiatesCanonical(Collection<Canonical> instantiatesCanonical)
The URL pointing to a FHIR-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this ServiceRequest.ServiceRequest.Builder
instantiatesUri(Uri... instantiatesUri)
The URL pointing to an externally maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this ServiceRequest.ServiceRequest.Builder
instantiatesUri(Collection<Uri> instantiatesUri)
The URL pointing to an externally maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this ServiceRequest.ServiceRequest.Builder
insurance(Reference... insurance)
Insurance plans, coverage extensions, pre-authorizations and/or pre-determinations that may be needed for delivering the requested service.ServiceRequest.Builder
insurance(Collection<Reference> insurance)
Insurance plans, coverage extensions, pre-authorizations and/or pre-determinations that may be needed for delivering the requested service.ServiceRequest.Builder
intent(ServiceRequestIntent intent)
Whether the request is a proposal, plan, an original order or a reflex order.ServiceRequest.Builder
language(Code language)
The base language in which the resource is written.ServiceRequest.Builder
locationCode(CodeableConcept... locationCode)
The preferred location(s) where the procedure should actually happen in coded or free text form.ServiceRequest.Builder
locationCode(Collection<CodeableConcept> locationCode)
The preferred location(s) where the procedure should actually happen in coded or free text form.ServiceRequest.Builder
locationReference(Reference... locationReference)
A reference to the the preferred location(s) where the procedure should actually happen.ServiceRequest.Builder
locationReference(Collection<Reference> locationReference)
A reference to the the preferred location(s) where the procedure should actually happen.ServiceRequest.Builder
meta(Meta meta)
The metadata about the resource.ServiceRequest.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.ServiceRequest.Builder
modifierExtension(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.ServiceRequest.Builder
note(Annotation... note)
Any other notes and comments made about the service request.ServiceRequest.Builder
note(Collection<Annotation> note)
Any other notes and comments made about the service request.ServiceRequest.Builder
occurrence(Element occurrence)
The date/time at which the requested service should occur.ServiceRequest.Builder
orderDetail(CodeableConcept... orderDetail)
Additional details and instructions about the how the services are to be delivered.ServiceRequest.Builder
orderDetail(Collection<CodeableConcept> orderDetail)
Additional details and instructions about the how the services are to be delivered.ServiceRequest.Builder
patientInstruction(String patientInstruction)
Instructions in terms that are understood by the patient or consumer.ServiceRequest.Builder
performer(Reference... performer)
The desired performer for doing the requested service.ServiceRequest.Builder
performer(Collection<Reference> performer)
The desired performer for doing the requested service.ServiceRequest.Builder
performerType(CodeableConcept performerType)
Desired type of performer for doing the requested service.ServiceRequest.Builder
priority(ServiceRequestPriority priority)
Indicates how quickly the ServiceRequest should be addressed with respect to other requests.ServiceRequest.Builder
quantity(Element quantity)
An amount of service being requested which can be a quantity ( for example $1,500 home modification), a ratio ( for example, 20 half day visits per month), or a range (2.0 to 1.8 Gy per fraction).ServiceRequest.Builder
reasonCode(CodeableConcept... reasonCode)
An explanation or justification for why this service is being requested in coded or textual form.ServiceRequest.Builder
reasonCode(Collection<CodeableConcept> reasonCode)
An explanation or justification for why this service is being requested in coded or textual form.ServiceRequest.Builder
reasonReference(Reference... reasonReference)
Indicates another resource that provides a justification for why this service is being requested.ServiceRequest.Builder
reasonReference(Collection<Reference> reasonReference)
Indicates another resource that provides a justification for why this service is being requested.ServiceRequest.Builder
relevantHistory(Reference... relevantHistory)
Key events in the history of the request.ServiceRequest.Builder
relevantHistory(Collection<Reference> relevantHistory)
Key events in the history of the request.ServiceRequest.Builder
replaces(Reference... replaces)
The request takes the place of the referenced completed or terminated request(s).ServiceRequest.Builder
replaces(Collection<Reference> replaces)
The request takes the place of the referenced completed or terminated request(s).ServiceRequest.Builder
requester(Reference requester)
The individual who initiated the request and has responsibility for its activation.ServiceRequest.Builder
requisition(Identifier requisition)
A shared identifier common to all service requests that were authorized more or less simultaneously by a single author, representing the composite or group identifier.ServiceRequest.Builder
specimen(Reference... specimen)
One or more specimens that the laboratory procedure will use.ServiceRequest.Builder
specimen(Collection<Reference> specimen)
One or more specimens that the laboratory procedure will use.ServiceRequest.Builder
status(ServiceRequestStatus status)
The status of the order.ServiceRequest.Builder
subject(Reference subject)
On whom or what the service is to be performed.ServiceRequest.Builder
supportingInfo(Reference... supportingInfo)
Additional clinical information about the patient or specimen that may influence the services or their interpretations.ServiceRequest.Builder
supportingInfo(Collection<Reference> supportingInfo)
Additional clinical information about the patient or specimen that may influence the services or their interpretations.ServiceRequest.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.protected void
validate(ServiceRequest serviceRequest)
-
Methods inherited from class com.ibm.fhir.model.resource.DomainResource.Builder
from, validate
-
Methods inherited from class com.ibm.fhir.model.resource.Resource.Builder
from, validate
-
Methods inherited from class com.ibm.fhir.model.builder.AbstractBuilder
isValidating, setValidating
-
-
-
-
Method Detail
-
id
public ServiceRequest.Builder id(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 ServiceRequest.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 ServiceRequest.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 ServiceRequest.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 ServiceRequest.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 ServiceRequest.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
- Overrides:
contained
in classDomainResource.Builder
- Parameters:
contained
- Contained, inline Resources- Returns:
- A reference to this Builder instance
-
contained
public ServiceRequest.Builder contained(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
- Overrides:
contained
in classDomainResource.Builder
- Parameters:
contained
- Contained, inline Resources- Returns:
- A reference to this Builder instance
-
extension
public ServiceRequest.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
- Overrides:
extension
in classDomainResource.Builder
- Parameters:
extension
- Additional content defined by implementations- Returns:
- A reference to this Builder instance
-
extension
public ServiceRequest.Builder extension(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
- Overrides:
extension
in classDomainResource.Builder
- Parameters:
extension
- Additional content defined by implementations- Returns:
- A reference to this Builder instance
-
modifierExtension
public ServiceRequest.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
- Overrides:
modifierExtension
in classDomainResource.Builder
- Parameters:
modifierExtension
- Extensions that cannot be ignored- Returns:
- A reference to this Builder instance
-
modifierExtension
public ServiceRequest.Builder modifierExtension(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
- Overrides:
modifierExtension
in classDomainResource.Builder
- Parameters:
modifierExtension
- Extensions that cannot be ignored- Returns:
- A reference to this Builder instance
-
identifier
public ServiceRequest.Builder identifier(Identifier... identifier)
Identifiers assigned to this order instance by the orderer and/or the receiver and/or order fulfiller.Adds new element(s) to the existing list
- Parameters:
identifier
- Identifiers assigned to this order- Returns:
- A reference to this Builder instance
-
identifier
public ServiceRequest.Builder identifier(Collection<Identifier> identifier)
Identifiers assigned to this order instance by the orderer and/or the receiver and/or order fulfiller.Replaces the existing list with a new one containing elements from the Collection
- Parameters:
identifier
- Identifiers assigned to this order- Returns:
- A reference to this Builder instance
-
instantiatesCanonical
public ServiceRequest.Builder instantiatesCanonical(Canonical... instantiatesCanonical)
The URL pointing to a FHIR-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this ServiceRequest.Adds new element(s) to the existing list
- Parameters:
instantiatesCanonical
- Instantiates FHIR protocol or definition- Returns:
- A reference to this Builder instance
-
instantiatesCanonical
public ServiceRequest.Builder instantiatesCanonical(Collection<Canonical> instantiatesCanonical)
The URL pointing to a FHIR-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this ServiceRequest.Replaces the existing list with a new one containing elements from the Collection
- Parameters:
instantiatesCanonical
- Instantiates FHIR protocol or definition- Returns:
- A reference to this Builder instance
-
instantiatesUri
public ServiceRequest.Builder instantiatesUri(Uri... instantiatesUri)
The URL pointing to an externally maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this ServiceRequest.Adds new element(s) to the existing list
- Parameters:
instantiatesUri
- Instantiates external protocol or definition- Returns:
- A reference to this Builder instance
-
instantiatesUri
public ServiceRequest.Builder instantiatesUri(Collection<Uri> instantiatesUri)
The URL pointing to an externally maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this ServiceRequest.Replaces the existing list with a new one containing elements from the Collection
- Parameters:
instantiatesUri
- Instantiates external protocol or definition- Returns:
- A reference to this Builder instance
-
basedOn
public ServiceRequest.Builder basedOn(Reference... basedOn)
Plan/proposal/order fulfilled by this request.Adds new element(s) to the existing list
Allowed resource types for the references:
- Parameters:
basedOn
- What request fulfills- Returns:
- A reference to this Builder instance
-
basedOn
public ServiceRequest.Builder basedOn(Collection<Reference> basedOn)
Plan/proposal/order fulfilled by this request.Replaces the existing list with a new one containing elements from the Collection
Allowed resource types for the references:
- Parameters:
basedOn
- What request fulfills- Returns:
- A reference to this Builder instance
-
replaces
public ServiceRequest.Builder replaces(Reference... replaces)
The request takes the place of the referenced completed or terminated request(s).Adds new element(s) to the existing list
Allowed resource types for the references:
- Parameters:
replaces
- What request replaces- Returns:
- A reference to this Builder instance
-
replaces
public ServiceRequest.Builder replaces(Collection<Reference> replaces)
The request takes the place of the referenced completed or terminated request(s).Replaces the existing list with a new one containing elements from the Collection
Allowed resource types for the references:
- Parameters:
replaces
- What request replaces- Returns:
- A reference to this Builder instance
-
requisition
public ServiceRequest.Builder requisition(Identifier requisition)
A shared identifier common to all service requests that were authorized more or less simultaneously by a single author, representing the composite or group identifier.- Parameters:
requisition
- Composite Request ID- Returns:
- A reference to this Builder instance
-
status
public ServiceRequest.Builder status(ServiceRequestStatus status)
The status of the order.This element is required.
- Parameters:
status
- draft | active | on-hold | revoked | completed | entered-in-error | unknown- Returns:
- A reference to this Builder instance
-
intent
public ServiceRequest.Builder intent(ServiceRequestIntent intent)
Whether the request is a proposal, plan, an original order or a reflex order.This element is required.
- Parameters:
intent
- proposal | plan | directive | order | original-order | reflex-order | filler-order | instance-order | option- Returns:
- A reference to this Builder instance
-
category
public ServiceRequest.Builder category(CodeableConcept... category)
A code that classifies the service for searching, sorting and display purposes (e.g. "Surgical Procedure").Adds new element(s) to the existing list
- Parameters:
category
- Classification of service- Returns:
- A reference to this Builder instance
-
category
public ServiceRequest.Builder category(Collection<CodeableConcept> category)
A code that classifies the service for searching, sorting and display purposes (e.g. "Surgical Procedure").Replaces the existing list with a new one containing elements from the Collection
- Parameters:
category
- Classification of service- Returns:
- A reference to this Builder instance
-
priority
public ServiceRequest.Builder priority(ServiceRequestPriority priority)
Indicates how quickly the ServiceRequest should be addressed with respect to other requests.- Parameters:
priority
- routine | urgent | asap | stat- Returns:
- A reference to this Builder instance
-
doNotPerform
public ServiceRequest.Builder doNotPerform(Boolean doNotPerform)
Set this to true if the record is saying that the service/procedure should NOT be performed.- Parameters:
doNotPerform
- True if service/procedure should not be performed- Returns:
- A reference to this Builder instance
-
code
public ServiceRequest.Builder code(CodeableConcept code)
A code that identifies a particular service (i.e., procedure, diagnostic investigation, or panel of investigations) that have been requested.- Parameters:
code
- What is being requested/ordered- Returns:
- A reference to this Builder instance
-
orderDetail
public ServiceRequest.Builder orderDetail(CodeableConcept... orderDetail)
Additional details and instructions about the how the services are to be delivered. For example, and order for a urinary catheter may have an order detail for an external or indwelling catheter, or an order for a bandage may require additional instructions specifying how the bandage should be applied.Adds new element(s) to the existing list
- Parameters:
orderDetail
- Additional order information- Returns:
- A reference to this Builder instance
-
orderDetail
public ServiceRequest.Builder orderDetail(Collection<CodeableConcept> orderDetail)
Additional details and instructions about the how the services are to be delivered. For example, and order for a urinary catheter may have an order detail for an external or indwelling catheter, or an order for a bandage may require additional instructions specifying how the bandage should be applied.Replaces the existing list with a new one containing elements from the Collection
- Parameters:
orderDetail
- Additional order information- Returns:
- A reference to this Builder instance
-
quantity
public ServiceRequest.Builder quantity(Element quantity)
An amount of service being requested which can be a quantity ( for example $1,500 home modification), a ratio ( for example, 20 half day visits per month), or a range (2.0 to 1.8 Gy per fraction).This is a choice element with the following allowed types:
- Parameters:
quantity
- Service amount- Returns:
- A reference to this Builder instance
-
subject
public ServiceRequest.Builder subject(Reference subject)
On whom or what the service is to be performed. This is usually a human patient, but can also be requested on animals, groups of humans or animals, devices such as dialysis machines, or even locations (typically for environmental scans).This element is required.
Allowed resource types for this reference:
- Parameters:
subject
- Individual or Entity the service is ordered for- Returns:
- A reference to this Builder instance
-
encounter
public ServiceRequest.Builder encounter(Reference encounter)
An encounter that provides additional information about the healthcare context in which this request is made.Allowed resource types for this reference:
- Parameters:
encounter
- Encounter in which the request was created- Returns:
- A reference to this Builder instance
-
occurrence
public ServiceRequest.Builder occurrence(Element occurrence)
The date/time at which the requested service should occur.This is a choice element with the following allowed types:
- Parameters:
occurrence
- When service should occur- Returns:
- A reference to this Builder instance
-
asNeeded
public ServiceRequest.Builder asNeeded(Element asNeeded)
If a CodeableConcept is present, it indicates the pre-condition for performing the service. For example "pain", "on flare-up", etc.This is a choice element with the following allowed types:
- Parameters:
asNeeded
- Preconditions for service- Returns:
- A reference to this Builder instance
-
authoredOn
public ServiceRequest.Builder authoredOn(DateTime authoredOn)
When the request transitioned to being actionable.- Parameters:
authoredOn
- Date request signed- Returns:
- A reference to this Builder instance
-
requester
public ServiceRequest.Builder requester(Reference requester)
The individual who initiated the request and has responsibility for its activation.Allowed resource types for this reference:
- Parameters:
requester
- Who/what is requesting service- Returns:
- A reference to this Builder instance
-
performerType
public ServiceRequest.Builder performerType(CodeableConcept performerType)
Desired type of performer for doing the requested service.- Parameters:
performerType
- Performer role- Returns:
- A reference to this Builder instance
-
performer
public ServiceRequest.Builder performer(Reference... performer)
The desired performer for doing the requested service. For example, the surgeon, dermatopathologist, endoscopist, etc.Adds new element(s) to the existing list
Allowed resource types for the references:
- Parameters:
performer
- Requested performer- Returns:
- A reference to this Builder instance
-
performer
public ServiceRequest.Builder performer(Collection<Reference> performer)
The desired performer for doing the requested service. For example, the surgeon, dermatopathologist, endoscopist, etc.Replaces the existing list with a new one containing elements from the Collection
Allowed resource types for the references:
- Parameters:
performer
- Requested performer- Returns:
- A reference to this Builder instance
-
locationCode
public ServiceRequest.Builder locationCode(CodeableConcept... locationCode)
The preferred location(s) where the procedure should actually happen in coded or free text form. E.g. at home or nursing day care center.Adds new element(s) to the existing list
- Parameters:
locationCode
- Requested location- Returns:
- A reference to this Builder instance
-
locationCode
public ServiceRequest.Builder locationCode(Collection<CodeableConcept> locationCode)
The preferred location(s) where the procedure should actually happen in coded or free text form. E.g. at home or nursing day care center.Replaces the existing list with a new one containing elements from the Collection
- Parameters:
locationCode
- Requested location- Returns:
- A reference to this Builder instance
-
locationReference
public ServiceRequest.Builder locationReference(Reference... locationReference)
A reference to the the preferred location(s) where the procedure should actually happen. E.g. at home or nursing day care center.Adds new element(s) to the existing list
Allowed resource types for the references:
- Parameters:
locationReference
- Requested location- Returns:
- A reference to this Builder instance
-
locationReference
public ServiceRequest.Builder locationReference(Collection<Reference> locationReference)
A reference to the the preferred location(s) where the procedure should actually happen. E.g. at home or nursing day care center.Replaces the existing list with a new one containing elements from the Collection
Allowed resource types for the references:
- Parameters:
locationReference
- Requested location- Returns:
- A reference to this Builder instance
-
reasonCode
public ServiceRequest.Builder reasonCode(CodeableConcept... reasonCode)
An explanation or justification for why this service is being requested in coded or textual form. This is often for billing purposes. May relate to the resources referred to in `supportingInfo`.Adds new element(s) to the existing list
- Parameters:
reasonCode
- Explanation/Justification for procedure or service- Returns:
- A reference to this Builder instance
-
reasonCode
public ServiceRequest.Builder reasonCode(Collection<CodeableConcept> reasonCode)
An explanation or justification for why this service is being requested in coded or textual form. This is often for billing purposes. May relate to the resources referred to in `supportingInfo`.Replaces the existing list with a new one containing elements from the Collection
- Parameters:
reasonCode
- Explanation/Justification for procedure or service- Returns:
- A reference to this Builder instance
-
reasonReference
public ServiceRequest.Builder reasonReference(Reference... reasonReference)
Indicates another resource that provides a justification for why this service is being requested. May relate to the resources referred to in `supportingInfo`.Adds new element(s) to the existing list
Allowed resource types for the references:
- Parameters:
reasonReference
- Explanation/Justification for service or service- Returns:
- A reference to this Builder instance
-
reasonReference
public ServiceRequest.Builder reasonReference(Collection<Reference> reasonReference)
Indicates another resource that provides a justification for why this service is being requested. May relate to the resources referred to in `supportingInfo`.Replaces the existing list with a new one containing elements from the Collection
Allowed resource types for the references:
- Parameters:
reasonReference
- Explanation/Justification for service or service- Returns:
- A reference to this Builder instance
-
insurance
public ServiceRequest.Builder insurance(Reference... insurance)
Insurance plans, coverage extensions, pre-authorizations and/or pre-determinations that may be needed for delivering the requested service.Adds new element(s) to the existing list
Allowed resource types for the references:
- Parameters:
insurance
- Associated insurance coverage- Returns:
- A reference to this Builder instance
-
insurance
public ServiceRequest.Builder insurance(Collection<Reference> insurance)
Insurance plans, coverage extensions, pre-authorizations and/or pre-determinations that may be needed for delivering the requested service.Replaces the existing list with a new one containing elements from the Collection
Allowed resource types for the references:
- Parameters:
insurance
- Associated insurance coverage- Returns:
- A reference to this Builder instance
-
supportingInfo
public ServiceRequest.Builder supportingInfo(Reference... supportingInfo)
Additional clinical information about the patient or specimen that may influence the services or their interpretations. This information includes diagnosis, clinical findings and other observations. In laboratory ordering these are typically referred to as "ask at order entry questions (AOEs)". This includes observations explicitly requested by the producer (filler) to provide context or supporting information needed to complete the order. For example, reporting the amount of inspired oxygen for blood gas measurements.Adds new element(s) to the existing list
- Parameters:
supportingInfo
- Additional clinical information- Returns:
- A reference to this Builder instance
-
supportingInfo
public ServiceRequest.Builder supportingInfo(Collection<Reference> supportingInfo)
Additional clinical information about the patient or specimen that may influence the services or their interpretations. This information includes diagnosis, clinical findings and other observations. In laboratory ordering these are typically referred to as "ask at order entry questions (AOEs)". This includes observations explicitly requested by the producer (filler) to provide context or supporting information needed to complete the order. For example, reporting the amount of inspired oxygen for blood gas measurements.Replaces the existing list with a new one containing elements from the Collection
- Parameters:
supportingInfo
- Additional clinical information- Returns:
- A reference to this Builder instance
-
specimen
public ServiceRequest.Builder specimen(Reference... specimen)
One or more specimens that the laboratory procedure will use.Adds new element(s) to the existing list
Allowed resource types for the references:
- Parameters:
specimen
- Procedure Samples- Returns:
- A reference to this Builder instance
-
specimen
public ServiceRequest.Builder specimen(Collection<Reference> specimen)
One or more specimens that the laboratory procedure will use.Replaces the existing list with a new one containing elements from the Collection
Allowed resource types for the references:
- Parameters:
specimen
- Procedure Samples- Returns:
- A reference to this Builder instance
-
bodySite
public ServiceRequest.Builder bodySite(CodeableConcept... bodySite)
Anatomic location where the procedure should be performed. This is the target site.Adds new element(s) to the existing list
- Parameters:
bodySite
- Location on Body- Returns:
- A reference to this Builder instance
-
bodySite
public ServiceRequest.Builder bodySite(Collection<CodeableConcept> bodySite)
Anatomic location where the procedure should be performed. This is the target site.Replaces the existing list with a new one containing elements from the Collection
- Parameters:
bodySite
- Location on Body- Returns:
- A reference to this Builder instance
-
note
public ServiceRequest.Builder note(Annotation... note)
Any other notes and comments made about the service request. For example, internal billing notes.Adds new element(s) to the existing list
- Parameters:
note
- Comments- Returns:
- A reference to this Builder instance
-
note
public ServiceRequest.Builder note(Collection<Annotation> note)
Any other notes and comments made about the service request. For example, internal billing notes.Replaces the existing list with a new one containing elements from the Collection
- Parameters:
note
- Comments- Returns:
- A reference to this Builder instance
-
patientInstruction
public ServiceRequest.Builder patientInstruction(String patientInstruction)
Instructions in terms that are understood by the patient or consumer.- Parameters:
patientInstruction
- Patient or consumer-oriented instructions- Returns:
- A reference to this Builder instance
-
relevantHistory
public ServiceRequest.Builder relevantHistory(Reference... relevantHistory)
Key events in the history of the request.Adds new element(s) to the existing list
Allowed resource types for the references:
- Parameters:
relevantHistory
- Request provenance- Returns:
- A reference to this Builder instance
-
relevantHistory
public ServiceRequest.Builder relevantHistory(Collection<Reference> relevantHistory)
Key events in the history of the request.Replaces the existing list with a new one containing elements from the Collection
Allowed resource types for the references:
- Parameters:
relevantHistory
- Request provenance- Returns:
- A reference to this Builder instance
-
build
public ServiceRequest build()
- Specified by:
build
in interfaceBuilder<Resource>
- Specified by:
build
in classDomainResource.Builder
- Returns:
- An immutable object of type
ServiceRequest
- Throws:
IllegalStateException
- if the current state cannot be built into a valid ServiceRequest per the base specification
-
validate
protected void validate(ServiceRequest serviceRequest)
-
from
protected ServiceRequest.Builder from(ServiceRequest serviceRequest)
-
-