Record Class ConstantPoolParser.ReferenceToken

java.lang.Object
java.lang.Record
com.ibm.wala.shrike.shrikeCT.ConstantPoolParser.ReferenceToken
Enclosing class:
ConstantPoolParser

public static record ConstantPoolParser.ReferenceToken(byte kind, String className, String elementName, String descriptor) extends Record
  • Constructor Summary

    Constructors
    Constructor
    Description
    ReferenceToken(byte kind, String className, String elementName, String descriptor)
    Creates an instance of a ReferenceToken record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the value of the className record component.
    Returns the value of the descriptor record component.
    Returns the value of the elementName record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    Deprecated, for removal: This API element is subject to removal in a future version.
    Use className() instead
    Deprecated, for removal: This API element is subject to removal in a future version.
    Use descriptor() instead
    Deprecated, for removal: This API element is subject to removal in a future version.
    Use elementName() instead
    byte
    Deprecated, for removal: This API element is subject to removal in a future version.
    Use kind() instead
    int
    Returns a hash code value for this object.
    byte
    Returns the value of the kind record component.
    final String
    Returns a string representation of this record class.

    Methods inherited from class Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • ReferenceToken

      public ReferenceToken(byte kind, String className, String elementName, String descriptor)
      Creates an instance of a ReferenceToken record class.
      Parameters:
      kind - the value for the kind record component
      className - the value for the className record component
      elementName - the value for the elementName record component
      descriptor - the value for the descriptor record component
  • Method Details

    • getKind

      @Deprecated(forRemoval=true, since="1.8.0") public byte getKind()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Use kind() instead
    • getClassName

      @Deprecated(forRemoval=true, since="1.8.0") public String getClassName()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Use className() instead
    • getElementName

      @Deprecated(forRemoval=true, since="1.8.0") public String getElementName()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Use elementName() instead
    • getDescriptor

      @Deprecated(forRemoval=true, since="1.8.0") public String getDescriptor()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Use descriptor() instead
    • hashCode

      public int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • equals

      public final boolean equals(Object o)
      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 with Objects::equals(Object,Object); primitive components are compared with the compare method from their corresponding wrapper classes.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • kind

      public byte kind()
      Returns the value of the kind record component.
      Returns:
      the value of the kind record component
    • className

      public String className()
      Returns the value of the className record component.
      Returns:
      the value of the className record component
    • elementName

      public String elementName()
      Returns the value of the elementName record component.
      Returns:
      the value of the elementName record component
    • descriptor

      public String descriptor()
      Returns the value of the descriptor record component.
      Returns:
      the value of the descriptor record component