Interface SignatureAttribute

All Superinterfaces:
Attribute<SignatureAttribute>, ClassElement, ClassfileElement, FieldElement, MethodElement, WritableElement<SignatureAttribute>
All Known Implementing Classes:
BoundAttribute.BoundSignatureAttribute, UnboundAttribute.UnboundSignatureAttribute

Models the Signature attribute , which can appear on classes, methods, or fields. Delivered as a ClassElement, FieldElement, or MethodElement when traversing the corresponding model type.
  • Method Details

    • signature

      Utf8Entry signature()
      Returns the signature for the class, method, or field.
      Returns:
      the signature for the class, method, or field
    • asClassSignature

      default ClassSignature asClassSignature()
      Parse the siganture as a class signature.
      Returns:
      the class signature
    • asMethodSignature

      default MethodSignature asMethodSignature()
      Parse the signature as a method signature.
      Returns:
      the method signature
    • asTypeSignature

      default Signature asTypeSignature()
      Parse the siganture as a type signature.
      Returns:
      the type signature
    • of

      static SignatureAttribute of(ClassSignature classSignature)
      Returns a Signature attribute for a class.
      Parameters:
      classSignature - the signature
      Returns:
      a Signature attribute for a class
    • of

      static SignatureAttribute of(MethodSignature methodSignature)
      Returns a Signature attribute for a method.
      Parameters:
      methodSignature - the signature
      Returns:
      a Signature attribute for a method
    • of

      static SignatureAttribute of(Signature signature)
      Returns a Signature attribute.
      Parameters:
      signature - the signature
      Returns:
      a Signature attribute
    • of

      static SignatureAttribute of(Utf8Entry signature)
      Returns a Signature attribute.
      Parameters:
      signature - the signature
      Returns:
      a Signature attribute