Package serp.bytecode

Class PrimitiveState


  • class PrimitiveState
    extends State
    State implementing the behavior of a primitive class.
    • Field Detail

      • _type

        private final java.lang.Class _type
    • Constructor Detail

      • PrimitiveState

        public PrimitiveState​(java.lang.Class type,
                              NameCache names)
    • Method Detail

      • getMagic

        public int getMagic()
        Description copied from class: State
        Return the magic number of the bytecode class.
        Overrides:
        getMagic in class State
      • getMajorVersion

        public int getMajorVersion()
        Description copied from class: State
        Return the major number of the bytecode class.
        Overrides:
        getMajorVersion in class State
      • getMinorVersion

        public int getMinorVersion()
        Description copied from class: State
        Return the minor number of the bytecode class.
        Overrides:
        getMinorVersion in class State
      • getAccessFlags

        public int getAccessFlags()
        Description copied from class: State
        Return the access flags of the bytecode class.
        Overrides:
        getAccessFlags in class State
      • getInterfacesHolder

        public java.util.List getInterfacesHolder()
        Description copied from class: State
        Return the ConstantPool indexes of the ClassEntrys for the indexes of this class, or empty list if none. If the state does not support changing the interfaces, the returned list should be immutable.
        Overrides:
        getInterfacesHolder in class State
      • getFieldsHolder

        public java.util.List getFieldsHolder()
        Description copied from class: State
        Return the BCFields of this class, or empty list if none. If the state does not support changing the fields, the returned list should be immutable.
        Overrides:
        getFieldsHolder in class State
      • getMethodsHolder

        public java.util.List getMethodsHolder()
        Description copied from class: State
        Return the BCMethods of this class, or empty list if none. If the state does not support changing the methods, the returned list should be immutable.
        Overrides:
        getMethodsHolder in class State
      • getAttributesHolder

        public java.util.Collection getAttributesHolder()
        Description copied from class: State
        Return the Attributes of this class, or empty list if none. If the state does not support changing the attributes, the returned list should be immutable.
        Overrides:
        getAttributesHolder in class State
      • getName

        public java.lang.String getName()
        Description copied from class: State
        Return the name of the class. The name should be in a form suitable for a Class.forName(java.lang.String) call.
        Overrides:
        getName in class State
      • getSuperclassName

        public java.lang.String getSuperclassName()
        Description copied from class: State
        Return the name of the superclass. The name should be in a form suitable for a Class.forName(java.lang.String) call, or null if none.
        Overrides:
        getSuperclassName in class State
      • getComponentName

        public java.lang.String getComponentName()
        Description copied from class: State
        Return the name of the component type of this array, or null if not an array. The name should be in a form suitable for a Class.forName(java.lang.String) call.
        Overrides:
        getComponentName in class State
      • isPrimitive

        public boolean isPrimitive()
        Description copied from class: State
        Return true if this class is a primitive.
        Overrides:
        isPrimitive in class State
      • isArray

        public boolean isArray()
        Description copied from class: State
        Return true if this class is an array.
        Overrides:
        isArray in class State