Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -138,25 +138,6 @@ default NaturalIdLoadAccess<T> withLoadGraph(RootGraph<T> graph) {
*/
NaturalIdLoadAccess<T> using(Map<String,?> mappings);

/**
* Set multiple {@link org.hibernate.annotations.NaturalId @NaturalId}
* attribute values at once. An even number of arguments is expected,
* with each attribute name followed by its value, for example:
* <pre>
* Book book =
* session.byNaturalId(Book.class)
* .using(Book_.ISBN, isbn, Book_.PRINTING, printing)
* .load();
* </pre>
*
* @return {@code this}, for method chaining
*
* @deprecated use {@link #using(Map)} with {@link Map#of}, which is
* slightly more typesafe
*/
@Deprecated(since = "6.3")
NaturalIdLoadAccess<T> using(Object... mappings);

/**
* Determines if cached natural id cross-references are synchronized
* before query execution with unflushed modifications made in memory
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,10 @@
*/
package org.hibernate;

import java.util.List;
import java.util.Map;

import org.hibernate.graph.GraphSemantic;
import org.hibernate.graph.RootGraph;

import static org.hibernate.internal.util.collections.CollectionHelper.asMap;
import java.util.List;

/**
* Loads multiple instances of a given entity type at once, by
Expand Down Expand Up @@ -174,18 +171,4 @@ default NaturalIdMultiLoadAccess<T> with(RootGraph<T> graph) {
* @return The managed entities.
*/
List<T> multiLoad(List<?> ids);

/**
* Helper for creating a {@link Map} that represents the value of a
* composite natural id. An even number of arguments is expected,
* with each attribute name followed by its value.
*
* @see NaturalIdLoadAccess#using(Object...)
*
* @deprecated use {@link Map#of} instead
*/
@Deprecated(since = "6.3")
static Map<String,?> compoundValue(Object... elements) {
return asMap( elements );
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@
import org.hibernate.internal.CoreLogging;
import org.hibernate.internal.CoreMessageLogger;
import org.hibernate.internal.util.StringHelper;
import org.hibernate.internal.util.collections.CollectionHelper;
import org.hibernate.mapping.GeneratorCreator;
import org.hibernate.mapping.KeyValue;
import org.hibernate.mapping.PersistentClass;
Expand Down Expand Up @@ -74,6 +73,7 @@
import static org.hibernate.id.IdentifierGenerator.GENERATOR_NAME;
import static org.hibernate.internal.util.NullnessUtil.castNonNull;
import static org.hibernate.internal.util.StringHelper.qualify;
import static org.hibernate.internal.util.collections.CollectionHelper.combineUntyped;
import static org.hibernate.resource.beans.internal.Helper.allowExtensionsInCdi;

/**
Expand Down Expand Up @@ -883,7 +883,7 @@ static void createIdGeneratorsFromGeneratorAnnotations(
Locale.ROOT,
"Identifier attribute '%s' has too many generator annotations: %s",
getPath( propertyHolder, inferredData ),
CollectionHelper.combineUntyped( idGeneratorAnnotations, generatorAnnotations )
combineUntyped( idGeneratorAnnotations, generatorAnnotations )
) );
}
if ( !idGeneratorAnnotations.isEmpty() ) {
Expand Down
Loading
Loading