Package pascal.taie.language.type
Record Class ArrayType
java.lang.Object
java.lang.Record
pascal.taie.language.type.ArrayType
- All Implemented Interfaces:
Serializable
,ReferenceType
,Type
public record ArrayType(Type baseType, int dimensions, Type elementType)
extends Record
implements ReferenceType
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbaseType()
Returns the value of thebaseType
record component.int
Returns the value of thedimensions
record component.Returns the value of theelementType
record component.final boolean
Indicates whether some other object is "equal to" this one.getName()
final int
hashCode()
Returns a hash code value for this object.toString()
Returns a string representation of this record class.
-
Constructor Details
-
ArrayType
Creates an instance of aArrayType
record class.- Parameters:
baseType
- the value for thebaseType
record componentdimensions
- the value for thedimensions
record componentelementType
- the value for theelementType
record component
-
-
Method Details
-
getName
-
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 '=='. -
baseType
Returns the value of thebaseType
record component.- Returns:
- the value of the
baseType
record component
-
dimensions
public int dimensions()Returns the value of thedimensions
record component.- Returns:
- the value of the
dimensions
record component
-
elementType
Returns the value of theelementType
record component.- Returns:
- the value of the
elementType
record component
-