Interface AnnotationValueGeneration<A extends Annotation>

    • Method Detail

      • initialize

        void initialize​(A annotation,
                        Class<?> propertyType)
        Initializes this generation strategy for the given annotation instance.
        Parameters:
        annotation - an instance of the strategy's annotation type. Typically implementations will retrieve the annotation's attribute values and store them in fields.
        propertyType - the type of the property annotated with the generator annotation. Implementations may use the type to determine the right ValueGenerator to be applied.
        Throws:
        HibernateException - in case an error occurred during initialization, e.g. if an implementation can't create a value for the given property type.
      • initialize

        default void initialize​(A annotation,
                                Class<?> propertyType,
                                String entityName,
                                String propertyName)
        Initializes this generation strategy for the given annotation instance.
        Parameters:
        annotation - an instance of the strategy's annotation type. Typically implementations will retrieve the annotation's attribute values and store them in fields.
        propertyType - the type of the property annotated with the generator annotation. Implementations may use the type to determine the right ValueGenerator to be applied.
        entityName - the name of the entity to which the annotated property belongs
        propertyName - the name of the annotated property
        Throws:
        HibernateException - in case an error occurred during initialization, e.g. if an implementation can't create a value for the given property type.