Class BeanMap.Generator

    • Constructor Detail

      • Generator

        public Generator()
    • Method Detail

      • setBeanClass

        public void setBeanClass​(java.lang.Class beanClass)
        Set the class of the bean that the generated map should support. You must call either this method or setBeanClass(java.lang.Class) before create().
        Parameters:
        beanClass - the class of the bean
      • setRequire

        public void setRequire​(int require)
        Limit the properties reflected by the generated map.
        Parameters:
        require - any combination of BeanMap.REQUIRE_GETTER and BeanMap.REQUIRE_SETTER; default is zero (any property allowed)
      • getProtectionDomain

        protected java.security.ProtectionDomain getProtectionDomain()
        Description copied from class: AbstractClassGenerator
        Returns the protection domain to use when defining the class.

        Default implementation returns null for using a default protection domain. Sub-classes may override to use a more specific protection domain.

        Overrides:
        getProtectionDomain in class AbstractClassGenerator
        Returns:
        the protection domain (null for using a default)
      • create

        public BeanMap create()
        Create a new instance of the BeanMap. An existing generated class will be reused if possible.
      • generateClass

        public void generateClass​(org.objectweb.asm.ClassVisitor v)
                           throws java.lang.Exception
        Throws:
        java.lang.Exception