All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.hibernate.binder.AttributeBinder Maven / Gradle / Ivy

There is a newer version: 6.6.2.Final
Show newest version
/*
 * Hibernate, Relational Persistence for Idiomatic Java
 *
 * License: GNU Lesser General Public License (LGPL), version 2.1 or later.
 * See the lgpl.txt file in the root directory or .
 */
package org.hibernate.binder;

import org.hibernate.Incubating;
import org.hibernate.boot.spi.MetadataBuildingContext;
import org.hibernate.mapping.PersistentClass;
import org.hibernate.mapping.Property;

import java.lang.annotation.Annotation;

/**
 * Allows a user-written annotation to drive some customized model binding.
 * 

* An implementation of this interface interacts directly with model objects * like {@link PersistentClass} and {@link Property} to implement the * semantics of some {@linkplain org.hibernate.annotations.AttributeBinderType * custom mapping annotation}. * * @see org.hibernate.annotations.AttributeBinderType * @see TypeBinder * * @author Gavin King */ @Incubating public interface AttributeBinder { /** * Perform some custom configuration of the model relating to the given annotated * {@link Property} of the given {@linkplain PersistentClass entity class} or * {@linkplain org.hibernate.mapping.Component embeddable class}. * * @param annotation an annotation of the property that is declared as an * {@link org.hibernate.annotations.AttributeBinderType} * @param persistentClass the entity class acting as the ultimate container of the * property (differs from {@link Property#getPersistentClass()} * in the case of a property of an embeddable class) * @param property a {@link Property} object representing the annotated property */ void bind(A annotation, MetadataBuildingContext buildingContext, PersistentClass persistentClass, Property property); }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy