note uniqueness of names in the Javadoc

This commit is contained in:
Gavin King 2023-06-20 17:53:04 +02:00
parent a63eed837d
commit 4e7c5df4fe
4 changed files with 11 additions and 4 deletions

View File

@ -82,7 +82,10 @@ import static org.hibernate.annotations.FetchMode.JOIN;
@Repeatable(FetchProfiles.class)
public @interface FetchProfile {
/**
* The name of the fetch profile.
* The name of the fetch profile. Must be unique within a persistence
* unit.
*
* @see org.hibernate.SessionFactory#getDefinedFetchProfileNames()
*/
String name();

View File

@ -5,6 +5,7 @@
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.annotations;
import java.lang.annotation.Repeatable;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
@ -64,7 +65,10 @@ import static java.lang.annotation.RetentionPolicy.RUNTIME;
@Repeatable(FilterDefs.class)
public @interface FilterDef {
/**
* The name of the declared filter.
* The name of the declared filter. Must be unique within a
* persistence unit.
*
* @see org.hibernate.SessionFactory#getDefinedFilterNames()
*/
String name();

View File

@ -38,7 +38,7 @@ import static java.lang.annotation.RetentionPolicy.RUNTIME;
@Repeatable(NamedNativeQueries.class)
public @interface NamedNativeQuery {
/**
* The name of this query.
* The name of this query. Must be unique within a persistence unit.
*
* @see org.hibernate.SessionFactory#addNamedQuery
* @see org.hibernate.Session#createNamedQuery

View File

@ -38,7 +38,7 @@ import static java.lang.annotation.RetentionPolicy.RUNTIME;
public @interface NamedQuery {
/**
* The name of this query.
* The name of this query. Must be unique within a persistence unit.
*/
String name();