Class AccessorGenerator

    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected AccessorInfo info
      Accessor info which describes the accessor
      protected boolean targetIsInterface
      True if the target is in an interface
      protected boolean targetIsStatic
      True for static target, false for instance target
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      protected void checkModifiers()  
      protected org.objectweb.asm.tree.MethodNode createMethod​(int maxLocals, int maxStack)
      Create an empty accessor method based on the source method
      abstract org.objectweb.asm.tree.MethodNode generate()
      Generate the accessor method
      void validate()
      Perform pre-flight checks on the accessor, to ensure it can be generated sanely
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • info

        protected final AccessorInfo info
        Accessor info which describes the accessor
      • targetIsStatic

        protected final boolean targetIsStatic
        True for static target, false for instance target
      • targetIsInterface

        protected final boolean targetIsInterface
        True if the target is in an interface
    • Constructor Detail

      • AccessorGenerator

        public AccessorGenerator​(AccessorInfo info,
                                 boolean isStatic)
    • Method Detail

      • checkModifiers

        protected void checkModifiers()
      • createMethod

        protected final org.objectweb.asm.tree.MethodNode createMethod​(int maxLocals,
                                                                       int maxStack)
        Create an empty accessor method based on the source method
        Parameters:
        maxLocals - max locals size for method
        maxStack - max stack size for method
        Returns:
        new method
      • validate

        public void validate()
        Perform pre-flight checks on the accessor, to ensure it can be generated sanely
      • generate

        public abstract org.objectweb.asm.tree.MethodNode generate()
        Generate the accessor method
        Returns:
        generated accessor method