Class AuditEvent.Agent.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.AuditEvent.Agent.Builder
-
- Enclosing class:
- AuditEvent.Agent
public static class AuditEvent.Agent.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 AuditEvent.Agent.Builder
altId(String altId)
Alternative agent Identifier.AuditEvent.Agent.Builder
altId(String altId)
Convenience method for settingaltId
.AuditEvent.Agent
build()
Build theAuditEvent.Agent
AuditEvent.Agent.Builder
extension(Extension... extension)
May be used to represent additional information that is not part of the basic definition of the element.AuditEvent.Agent.Builder
extension(Collection<Extension> extension)
May be used to represent additional information that is not part of the basic definition of the element.protected AuditEvent.Agent.Builder
from(AuditEvent.Agent agent)
AuditEvent.Agent.Builder
id(String id)
Unique id for the element within a resource (for internal references).AuditEvent.Agent.Builder
location(Reference location)
Where the event occurred.AuditEvent.Agent.Builder
media(Coding media)
Type of media involved.AuditEvent.Agent.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.AuditEvent.Agent.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.AuditEvent.Agent.Builder
name(String name)
Human-meaningful name for the agent.AuditEvent.Agent.Builder
name(String name)
Convenience method for settingname
.AuditEvent.Agent.Builder
network(AuditEvent.Agent.Network network)
Logical network location for application activity, if the activity has a network location.AuditEvent.Agent.Builder
policy(Uri... policy)
The policy or plan that authorized the activity being recorded.AuditEvent.Agent.Builder
policy(Collection<Uri> policy)
The policy or plan that authorized the activity being recorded.AuditEvent.Agent.Builder
purposeOfUse(CodeableConcept... purposeOfUse)
The reason (purpose of use), specific to this agent, that was used during the event being recorded.AuditEvent.Agent.Builder
purposeOfUse(Collection<CodeableConcept> purposeOfUse)
The reason (purpose of use), specific to this agent, that was used during the event being recorded.AuditEvent.Agent.Builder
requestor(Boolean requestor)
Indicator that the user is or is not the requestor, or initiator, for the event being audited.AuditEvent.Agent.Builder
requestor(Boolean requestor)
Convenience method for settingrequestor
.AuditEvent.Agent.Builder
role(CodeableConcept... role)
The security role that the user was acting under, that come from local codes defined by the access control security system (e.g.AuditEvent.Agent.Builder
role(Collection<CodeableConcept> role)
The security role that the user was acting under, that come from local codes defined by the access control security system (e.g.AuditEvent.Agent.Builder
type(CodeableConcept type)
Specification of the participation type the user plays when performing the event.protected void
validate(AuditEvent.Agent agent)
AuditEvent.Agent.Builder
who(Reference who)
Reference to who this agent is that was involved in the event.-
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 AuditEvent.Agent.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 AuditEvent.Agent.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 AuditEvent.Agent.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 AuditEvent.Agent.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 AuditEvent.Agent.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
-
type
public AuditEvent.Agent.Builder type(CodeableConcept type)
Specification of the participation type the user plays when performing the event.- Parameters:
type
- How agent participated- Returns:
- A reference to this Builder instance
-
role
public AuditEvent.Agent.Builder role(CodeableConcept... role)
The security role that the user was acting under, that come from local codes defined by the access control security system (e.g. RBAC, ABAC) used in the local context.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
role
- Agent role in the event- Returns:
- A reference to this Builder instance
-
role
public AuditEvent.Agent.Builder role(Collection<CodeableConcept> role)
The security role that the user was acting under, that come from local codes defined by the access control security system (e.g. RBAC, ABAC) used in the local context.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:
role
- Agent role in the event- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
who
public AuditEvent.Agent.Builder who(Reference who)
Reference to who this agent is that was involved in the event.Allowed resource types for this reference:
- Parameters:
who
- Identifier of who- Returns:
- A reference to this Builder instance
-
altId
public AuditEvent.Agent.Builder altId(String altId)
Convenience method for settingaltId
.- Parameters:
altId
- Alternative User identity- Returns:
- A reference to this Builder instance
- See Also:
altId(com.ibm.fhir.model.type.String)
-
altId
public AuditEvent.Agent.Builder altId(String altId)
Alternative agent Identifier. For a human, this should be a user identifier text string from authentication system. This identifier would be one known to a common authentication system (e.g. single sign-on), if available.- Parameters:
altId
- Alternative User identity- Returns:
- A reference to this Builder instance
-
name
public AuditEvent.Agent.Builder name(String name)
Convenience method for settingname
.- Parameters:
name
- Human friendly name for the agent- Returns:
- A reference to this Builder instance
- See Also:
name(com.ibm.fhir.model.type.String)
-
name
public AuditEvent.Agent.Builder name(String name)
Human-meaningful name for the agent.- Parameters:
name
- Human friendly name for the agent- Returns:
- A reference to this Builder instance
-
requestor
public AuditEvent.Agent.Builder requestor(Boolean requestor)
Convenience method for settingrequestor
.This element is required.
- Parameters:
requestor
- Whether user is initiator- Returns:
- A reference to this Builder instance
- See Also:
requestor(com.ibm.fhir.model.type.Boolean)
-
requestor
public AuditEvent.Agent.Builder requestor(Boolean requestor)
Indicator that the user is or is not the requestor, or initiator, for the event being audited.This element is required.
- Parameters:
requestor
- Whether user is initiator- Returns:
- A reference to this Builder instance
-
location
public AuditEvent.Agent.Builder location(Reference location)
Where the event occurred.Allowed resource types for this reference:
- Parameters:
location
- Where- Returns:
- A reference to this Builder instance
-
policy
public AuditEvent.Agent.Builder policy(Uri... policy)
The policy or plan that authorized the activity being recorded. Typically, a single activity may have multiple applicable policies, such as patient consent, guarantor funding, etc. The policy would also indicate the security token used.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
policy
- Policy that authorized event- Returns:
- A reference to this Builder instance
-
policy
public AuditEvent.Agent.Builder policy(Collection<Uri> policy)
The policy or plan that authorized the activity being recorded. Typically, a single activity may have multiple applicable policies, such as patient consent, guarantor funding, etc. The policy would also indicate the security token used.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:
policy
- Policy that authorized event- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
media
public AuditEvent.Agent.Builder media(Coding media)
Type of media involved. Used when the event is about exporting/importing onto media.- Parameters:
media
- Type of media- Returns:
- A reference to this Builder instance
-
network
public AuditEvent.Agent.Builder network(AuditEvent.Agent.Network network)
Logical network location for application activity, if the activity has a network location.- Parameters:
network
- Logical network location for application activity- Returns:
- A reference to this Builder instance
-
purposeOfUse
public AuditEvent.Agent.Builder purposeOfUse(CodeableConcept... purposeOfUse)
The reason (purpose of use), specific to this agent, that was used during the event being recorded.Adds new element(s) to the existing list. If any of the elements are null, calling
build()
will fail.- Parameters:
purposeOfUse
- Reason given for this user- Returns:
- A reference to this Builder instance
-
purposeOfUse
public AuditEvent.Agent.Builder purposeOfUse(Collection<CodeableConcept> purposeOfUse)
The reason (purpose of use), specific to this agent, that was used during the event being recorded.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:
purposeOfUse
- Reason given for this user- Returns:
- A reference to this Builder instance
- Throws:
NullPointerException
- If the passed collection is null
-
build
public AuditEvent.Agent build()
- Specified by:
build
in interfaceBuilder<Element>
- Specified by:
build
in classBackboneElement.Builder
- Returns:
- An immutable object of type
AuditEvent.Agent
- Throws:
IllegalStateException
- if the current state cannot be built into a valid Agent per the base specification
-
validate
protected void validate(AuditEvent.Agent agent)
-
from
protected AuditEvent.Agent.Builder from(AuditEvent.Agent agent)
-
-