Package com.ibm.fhir.path
Class FHIRPathBooleanValue
- java.lang.Object
-
- com.ibm.fhir.path.FHIRPathAbstractNode
-
- com.ibm.fhir.path.FHIRPathAbstractSystemValue
-
- com.ibm.fhir.path.FHIRPathBooleanValue
-
- All Implemented Interfaces:
FHIRPathNode,FHIRPathSystemValue,java.lang.Comparable<FHIRPathNode>
public class FHIRPathBooleanValue extends FHIRPathAbstractSystemValue
AFHIRPathSystemValuenode that wraps aBooleanvalue
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classFHIRPathBooleanValue.Builder
-
Field Summary
Fields Modifier and Type Field Description static FHIRPathBooleanValueFALSEstatic FHIRPathBooleanValueTRUE
-
Constructor Summary
Constructors Modifier Constructor Description protectedFHIRPathBooleanValue(FHIRPathBooleanValue.Builder builder)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Boolean_boolean()The boolean value wrapped by this FHIRPathBooleanValue nodevoidaccept(FHIRPathNodeVisitor visitor)A method for accepting aFHIRPathNodeVisitorFHIRPathBooleanValueand(FHIRPathBooleanValue value)Perform a logical AND operation between this FHIRPathBooleanValue and the parameterstatic FHIRPathBooleanValuebooleanValue(java.lang.Boolean _boolean)Static factory method for creating FHIRPathBooleanValue instances from aBooleanvaluestatic FHIRPathBooleanValuebooleanValue(java.lang.String name, java.lang.Boolean _boolean)Static factory method for creating named FHIRPathBooleanValue instances from aBooleanvaluestatic FHIRPathBooleanValue.Builderbuilder(java.lang.Boolean _boolean)Static factory method for creating builder instances from aBooleanvalueintcompareTo(FHIRPathNode other)Compare the boolean value wrapped by this FHIRPathBooleanValue node to the parameterbooleanequals(java.lang.Object obj)Indicates whether the boolean value wrapped by this FHIRPathBooleanValue node is equal the parameter (or its primitive value)inthashCode()FHIRPathBooleanValueimplies(FHIRPathBooleanValue value)Perform a logical IMPLIES operation between this FHIRPathBooleanValue and the parameterbooleanisBooleanValue()Indicates whether this FHIRPathSystemValue is type compatible withFHIRPathBooleanValuebooleanisComparableTo(FHIRPathNode other)Indicates whether this FHIRPathBooleanValue is comparable to the parameterbooleanisFalse()Indicates whether the boolean value wrapped by this FHIRPathBooleanValue node is falsebooleanisTrue()Indicates whether the boolean value wrapped by this FHIRPathBooleanValue node is trueFHIRPathBooleanValuenot()Perform a logical NOT operation on this FHIRPathBooleanValueFHIRPathBooleanValueor(FHIRPathBooleanValue value)Perform a logical OR operation between this FHIRPathBooleanValue and the parameterFHIRPathBooleanValue.BuildertoBuilder()Convert thisFHIRPathNodeinstance into aFHIRPathNode.Builderinstancejava.lang.StringtoString()FHIRPathBooleanValuexor(FHIRPathBooleanValue value)Perform a logical XOR operation between this FHIRPathBooleanValue and the parameter-
Methods inherited from class com.ibm.fhir.path.FHIRPathAbstractSystemValue
children, descendants, getValue, hasValue, stream
-
Methods inherited from interface com.ibm.fhir.path.FHIRPathNode
as, asElementNode, asResourceNode, asSystemValue, asTermServiceNode, asTypeInfoNode, is, isElementNode, isResourceNode, isTermServiceNode, isTypeInfoNode, name, path, type
-
Methods inherited from interface com.ibm.fhir.path.FHIRPathSystemValue
asBooleanValue, asNumberValue, asQuantityValue, asStringValue, asTemporalValue, isNumberValue, isQuantityValue, isStringValue, isSystemValue, isTemporalValue
-
-
-
-
Field Detail
-
TRUE
public static final FHIRPathBooleanValue TRUE
-
FALSE
public static final FHIRPathBooleanValue FALSE
-
-
Constructor Detail
-
FHIRPathBooleanValue
protected FHIRPathBooleanValue(FHIRPathBooleanValue.Builder builder)
-
-
Method Detail
-
isBooleanValue
public boolean isBooleanValue()
Description copied from interface:FHIRPathSystemValueIndicates whether this FHIRPathSystemValue is type compatible withFHIRPathBooleanValue- Returns:
- true if this FHIRPathSystemValue is type compatible with
FHIRPathBooleanValue, otherwise false
-
_boolean
public java.lang.Boolean _boolean()
The boolean value wrapped by this FHIRPathBooleanValue node- Returns:
- the boolean value wrapped by this FHIRPathBooleanValue node
-
isTrue
public boolean isTrue()
Indicates whether the boolean value wrapped by this FHIRPathBooleanValue node is true- Returns:
- true if the boolean value wrapped by this FHIRPathBooleanValue node is true, otherwise false
-
isFalse
public boolean isFalse()
Indicates whether the boolean value wrapped by this FHIRPathBooleanValue node is false- Returns:
- true if the boolean value wrapped by this FHIRPathBooleanValue node is false, otherwise false
-
booleanValue
public static FHIRPathBooleanValue booleanValue(java.lang.Boolean _boolean)
Static factory method for creating FHIRPathBooleanValue instances from aBooleanvalue- Parameters:
_boolean- theBooleanvalue- Returns:
- a new FHIRPathBooleanValue instance
-
booleanValue
public static FHIRPathBooleanValue booleanValue(java.lang.String name, java.lang.Boolean _boolean)
Static factory method for creating named FHIRPathBooleanValue instances from aBooleanvalue- Parameters:
name- the name_boolean- theBooleanvalue- Returns:
- a new named FHIRPathBooleanValue instance
-
toBuilder
public FHIRPathBooleanValue.Builder toBuilder()
Description copied from class:FHIRPathAbstractNodeConvert thisFHIRPathNodeinstance into aFHIRPathNode.Builderinstance- Specified by:
toBuilderin classFHIRPathAbstractSystemValue- Returns:
- a new
FHIRPathNode.Builderinstance containing the fields from thisFHIRPathNodeinstance
-
builder
public static FHIRPathBooleanValue.Builder builder(java.lang.Boolean _boolean)
Static factory method for creating builder instances from aBooleanvalue- Parameters:
_boolean- the boolean value- Returns:
- a new builder for building FHIRPathBooleanValue instances
-
or
public FHIRPathBooleanValue or(FHIRPathBooleanValue value)
Perform a logical OR operation between this FHIRPathBooleanValue and the parameter- Parameters:
value- the right operand- Returns:
- the result of the logical OR operation
-
xor
public FHIRPathBooleanValue xor(FHIRPathBooleanValue value)
Perform a logical XOR operation between this FHIRPathBooleanValue and the parameter- Parameters:
value- the right operand- Returns:
- the result of the logical XOR operation
-
and
public FHIRPathBooleanValue and(FHIRPathBooleanValue value)
Perform a logical AND operation between this FHIRPathBooleanValue and the parameter- Parameters:
value- the right operand- Returns:
- the result of the logical AND operation
-
implies
public FHIRPathBooleanValue implies(FHIRPathBooleanValue value)
Perform a logical IMPLIES operation between this FHIRPathBooleanValue and the parameter- Parameters:
value- the right operand- Returns:
- the result of the logical IMPLIES operation
-
not
public FHIRPathBooleanValue not()
Perform a logical NOT operation on this FHIRPathBooleanValue- Parameters:
value- the right operand- Returns:
- the result of the logical NOT operation
-
isComparableTo
public boolean isComparableTo(FHIRPathNode other)
Indicates whether this FHIRPathBooleanValue is comparable to the parameter- Parameters:
the- otherFHIRPathNode- Returns:
- true if the parameter or its primitive value is a FHIRPathBooleanValue
-
compareTo
public int compareTo(FHIRPathNode other)
Compare the boolean value wrapped by this FHIRPathBooleanValue node to the parameter- Parameters:
other- the otherFHIRPathNode- Returns:
- 0 if the boolean value wrapped by this FHIRPathBooleanValue node is equal to the parameter; a positive value if this FHIRPathBooleanValue is true and the parameter is false; and a negative value if this FHIRPathBooleanValue is false and the parameter is true
-
equals
public boolean equals(java.lang.Object obj)
Indicates whether the boolean value wrapped by this FHIRPathBooleanValue node is equal the parameter (or its primitive value)- Overrides:
equalsin classjava.lang.Object- Parameters:
obj- the otherObject- Returns:
- true if the boolean value wrapped by this FHIRPathBooleanValue node is equal the parameter (or its primitive value), otherwise false
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
accept
public void accept(FHIRPathNodeVisitor visitor)
Description copied from interface:FHIRPathNodeA method for accepting aFHIRPathNodeVisitor- Parameters:
visitor- theFHIRPathNodeVisitorthat this FHIRPathNode is accepting
-
-