Record Class PlainMustSupportElement
java.lang.Object
java.lang.Record
org.fhirfrog.frog.profilecompiler.model.PlainMustSupportElement
- Record Components:
typeCode- the element's first declared type code (used to fold the boolean-specificexists() or ... = falsepresence rule into the emitted expression, algorithm.md §7.1)targetProfiles- non-null, possibly-empty; populated only when the element's type includesReference(algorithm.md §3.4 rule 1 / §3.5)
public record PlainMustSupportElement(String elementId, String path, String typeCode, boolean mandatory, FixedValueConstraint fixedValue, List<String> targetProfiles)
extends Record
A "plain" must-support element (algorithm.md §3.4) - whatever's left after extensions, slices,
and choice-type must-support elements (§3.3) are removed.
path is the resource-type-
prefix-stripped element path as it will be checked; it may already have been rewritten by
fixed-value detection (fixedValue, whose own pathSuffix is appended to the
*pre-rewrite* element path to get here) or by choice-ancestor rewriting (algorithm.md §3.4
rule 3).-
Constructor Summary
ConstructorsConstructorDescriptionPlainMustSupportElement(String elementId, String path, String typeCode, boolean mandatory, FixedValueConstraint fixedValue, List<String> targetProfiles) Creates an instance of aPlainMustSupportElementrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theelementIdrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefixedValuerecord component.final inthashCode()Returns a hash code value for this object.booleanReturns the value of themandatoryrecord component.path()Returns the value of thepathrecord component.Returns the value of thetargetProfilesrecord component.final StringtoString()Returns a string representation of this record class.typeCode()Returns the value of thetypeCoderecord component.
-
Constructor Details
-
PlainMustSupportElement
public PlainMustSupportElement(String elementId, String path, String typeCode, boolean mandatory, FixedValueConstraint fixedValue, List<String> targetProfiles) Creates an instance of aPlainMustSupportElementrecord class.- Parameters:
elementId- the value for theelementIdrecord componentpath- the value for thepathrecord componenttypeCode- the value for thetypeCoderecord componentmandatory- the value for themandatoryrecord componentfixedValue- the value for thefixedValuerecord componenttargetProfiles- the value for thetargetProfilesrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
elementId
Returns the value of theelementIdrecord component.- Returns:
- the value of the
elementIdrecord component
-
path
Returns the value of thepathrecord component.- Returns:
- the value of the
pathrecord component
-
typeCode
Returns the value of thetypeCoderecord component.- Returns:
- the value of the
typeCoderecord component
-
mandatory
public boolean mandatory()Returns the value of themandatoryrecord component.- Returns:
- the value of the
mandatoryrecord component
-
fixedValue
Returns the value of thefixedValuerecord component.- Returns:
- the value of the
fixedValuerecord component
-
targetProfiles
Returns the value of thetargetProfilesrecord component.- Returns:
- the value of the
targetProfilesrecord component
-