Class RecordAttribute.RecordComponentInfo

java.lang.Object
javassist.bytecode.RecordAttribute.RecordComponentInfo
Enclosing class:
RecordAttribute

public static class RecordAttribute.RecordComponentInfo extends Object
Represents a single record component within the Record attribute.
  • Field Details

    • constPool

      private ConstPool constPool
    • nameIndex

      int nameIndex
    • descriptorIndex

      int descriptorIndex
    • attributes

      private List<AttributeInfo> attributes
  • Constructor Details

    • RecordComponentInfo

      public RecordComponentInfo(ConstPool cp, int nameIndex, int descriptorIndex, List<AttributeInfo> attributes)
      Constructs a RecordComponentInfo.
      Parameters:
      cp - the constant pool
      nameIndex - the index into the constant pool of the component's name
      descriptorIndex - the index into the constant pool of the component's descriptor
      attributes - the list of attributes associated with the component
  • Method Details

    • getNameIndex

      public int getNameIndex()
      Returns the name Index of the component.
      Returns:
      the component name
    • getName

      public String getName()
      Returns the name of the component.
      Returns:
      the component name
    • getDescriptor

      public String getDescriptor()
      Returns the descriptor of the component.
      Returns:
      the component descriptor
    • getAttributes

      public List<AttributeInfo> getAttributes()
      Returns the list of attributes associated with the component.
      Returns:
      the list of AttributeInfo
    • setDescriptorIndex

      public void setDescriptorIndex(int index)
      Sets the descriptor index after renaming.
      Parameters:
      index - the new descriptor index
    • setNameIndex

      public void setNameIndex(int index)