Record Class CallMetaData
java.lang.Object
java.lang.Record
org.ek9lang.compiler.ir.CallMetaData
-
Constructor Summary
ConstructorsConstructorDescriptionCallMetaData
(boolean isPure, int complexityScore) Creates CallMetaData with no side effects.CallMetaData
(boolean isPure, int complexityScore, Set<String> sideEffects) Creates an instance of aCallMetaData
record class. -
Method Summary
Modifier and TypeMethodDescriptionint
Returns the value of thecomplexityScore
record component.static CallMetaData
Creates default CallMetaData for when no symbol information is available.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.boolean
isPure()
Returns the value of theisPure
record component.Returns the value of thesideEffects
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
CallMetaData
public CallMetaData(boolean isPure, int complexityScore) Creates CallMetaData with no side effects. -
CallMetaData
Creates an instance of aCallMetaData
record class.- Parameters:
isPure
- the value for theisPure
record componentcomplexityScore
- the value for thecomplexityScore
record componentsideEffects
- the value for thesideEffects
record component
-
-
Method Details
-
defaultMetaData
Creates default CallMetaData for when no symbol information is available. Assumes non-pure with zero complexity and no known side effects. -
toString
-
hashCode
-
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 thecompare
method from their corresponding wrapper classes. -
isPure
public boolean isPure()Returns the value of theisPure
record component.- Returns:
- the value of the
isPure
record component
-
complexityScore
public int complexityScore()Returns the value of thecomplexityScore
record component.- Returns:
- the value of the
complexityScore
record component
-
sideEffects
-