From a79891a426f6e8ea3fb8ef539b2f6e026d80f6e0 Mon Sep 17 00:00:00 2001 From: Gavin King Date: Fri, 21 Jan 2022 14:21:28 +0100 Subject: [PATCH] the the in Javadoc and comments --- hibernate-core/src/main/java/org/hibernate/LockOptions.java | 2 +- .../src/main/java/org/hibernate/SessionException.java | 2 +- .../org/hibernate/boot/model/source/spi/EntitySource.java | 2 +- .../org/hibernate/context/internal/JTASessionContext.java | 6 +++--- .../context/internal/ThreadLocalSessionContext.java | 4 ++-- .../src/main/java/org/hibernate/dialect/H2Dialect.java | 2 +- .../src/main/java/org/hibernate/dialect/MySQLDialect.java | 2 +- .../org/hibernate/engine/jdbc/SerializableNClobProxy.java | 2 +- .../hibernate/engine/jdbc/dialect/spi/DialectResolver.java | 2 +- .../org/hibernate/engine/jdbc/internal/FormatStyle.java | 2 +- .../java/org/hibernate/id/IdentifierGeneratorHelper.java | 2 +- .../src/main/java/org/hibernate/jpa/spi/JpaCompliance.java | 2 +- .../metamodel/model/domain/AbstractManagedType.java | 2 +- .../hibernate/persister/entity/AbstractEntityPersister.java | 4 ++-- .../src/main/java/org/hibernate/query/TemporalUnit.java | 2 +- .../jta/internal/synchronization/AfterCompletionAction.java | 2 +- .../service/spi/SessionFactoryServiceInitiator.java | 4 ++-- .../src/main/java/org/hibernate/sql/Template.java | 4 ++-- .../tool/schema/spi/SchemaManagementToolCoordinator.java | 2 +- .../type/descriptor/java/spi/JavaTypeRegistry.java | 2 +- .../orm/test/readonly/ReadOnlyVersionedNodesTest.java | 4 ++-- .../bidirectional/EntityWithBidirectionalOneToOneTest.java | 2 +- .../hibernate/testing/orm/domain/DomainModelDescriptor.java | 4 ++-- 23 files changed, 31 insertions(+), 31 deletions(-) diff --git a/hibernate-core/src/main/java/org/hibernate/LockOptions.java b/hibernate-core/src/main/java/org/hibernate/LockOptions.java index 98367f118e..71d86b89f4 100644 --- a/hibernate-core/src/main/java/org/hibernate/LockOptions.java +++ b/hibernate-core/src/main/java/org/hibernate/LockOptions.java @@ -304,7 +304,7 @@ public class LockOptions implements Serializable { } /** - * Set the the follow-on-locking setting. + * Set the follow-on-locking setting. * @param followOnLocking The new follow-on-locking setting * @return this (for method chaining). */ diff --git a/hibernate-core/src/main/java/org/hibernate/SessionException.java b/hibernate-core/src/main/java/org/hibernate/SessionException.java index a3e287e87b..463fc6b0a3 100644 --- a/hibernate-core/src/main/java/org/hibernate/SessionException.java +++ b/hibernate-core/src/main/java/org/hibernate/SessionException.java @@ -8,7 +8,7 @@ package org.hibernate; /** * Thrown when the user calls a method of a {@link Session} that is in an inappropriate state for the given call (for - * example, the the session is closed or disconnected). + * example, the session is closed or disconnected). * * @author Gavin King */ diff --git a/hibernate-core/src/main/java/org/hibernate/boot/model/source/spi/EntitySource.java b/hibernate-core/src/main/java/org/hibernate/boot/model/source/spi/EntitySource.java index f9c0dfc03b..ab482b84df 100644 --- a/hibernate-core/src/main/java/org/hibernate/boot/model/source/spi/EntitySource.java +++ b/hibernate-core/src/main/java/org/hibernate/boot/model/source/spi/EntitySource.java @@ -60,7 +60,7 @@ public interface EntitySource extends IdentifiableTypeSource, ToolingHintContext /** * Obtain the batch-size to be applied when initializing proxies of this entity. * - * @return returns the the batch-size. + * @return returns the batch-size. */ int getBatchSize(); diff --git a/hibernate-core/src/main/java/org/hibernate/context/internal/JTASessionContext.java b/hibernate-core/src/main/java/org/hibernate/context/internal/JTASessionContext.java index d19ab79435..1315eade4b 100644 --- a/hibernate-core/src/main/java/org/hibernate/context/internal/JTASessionContext.java +++ b/hibernate-core/src/main/java/org/hibernate/context/internal/JTASessionContext.java @@ -118,7 +118,7 @@ public class JTASessionContext extends AbstractCurrentSessionContext { } /** - * Builds a {@link CleanupSync} capable of cleaning up the the current session map as an after transaction + * Builds a {@link CleanupSync} capable of cleaning up the current session map as an after transaction * callback. * * @param transactionIdentifier The transaction identifier under which the current session is registered. @@ -146,7 +146,7 @@ public class JTASessionContext extends AbstractCurrentSessionContext { /** * Mainly for subclass usage. This impl always returns true. * - * @return Whether or not the the session should be closed by transaction completion. + * @return Whether the session should be closed by transaction completion. */ protected boolean isAutoCloseEnabled() { return true; @@ -155,7 +155,7 @@ public class JTASessionContext extends AbstractCurrentSessionContext { /** * Mainly for subclass usage. This impl always returns true. * - * @return Whether or not the the session should be flushed prior transaction completion. + * @return Whether the session should be flushed prior transaction completion. */ protected boolean isAutoFlushEnabled() { return true; diff --git a/hibernate-core/src/main/java/org/hibernate/context/internal/ThreadLocalSessionContext.java b/hibernate-core/src/main/java/org/hibernate/context/internal/ThreadLocalSessionContext.java index 05e181266a..508503e68a 100644 --- a/hibernate-core/src/main/java/org/hibernate/context/internal/ThreadLocalSessionContext.java +++ b/hibernate-core/src/main/java/org/hibernate/context/internal/ThreadLocalSessionContext.java @@ -151,7 +151,7 @@ public class ThreadLocalSessionContext extends AbstractCurrentSessionContext { /** * Mainly for subclass usage. This impl always returns true. * - * @return Whether or not the the session should be closed by transaction completion. + * @return Whether the session should be closed by transaction completion. */ protected boolean isAutoCloseEnabled() { return true; @@ -160,7 +160,7 @@ public class ThreadLocalSessionContext extends AbstractCurrentSessionContext { /** * Mainly for subclass usage. This impl always returns true. * - * @return Whether or not the the session should be flushed prior to transaction completion. + * @return Whether the session should be flushed prior to transaction completion. */ protected boolean isAutoFlushEnabled() { return true; diff --git a/hibernate-core/src/main/java/org/hibernate/dialect/H2Dialect.java b/hibernate-core/src/main/java/org/hibernate/dialect/H2Dialect.java index d6ea9d5ecb..c1b6eb6517 100644 --- a/hibernate-core/src/main/java/org/hibernate/dialect/H2Dialect.java +++ b/hibernate-core/src/main/java/org/hibernate/dialect/H2Dialect.java @@ -325,7 +325,7 @@ public class H2Dialect extends Dialect { /** * In H2, the extract() function does not return - * fractional seconds for the the field + * fractional seconds for the field * {@link TemporalUnit#SECOND}. We work around * this here with two calls to extract(). */ diff --git a/hibernate-core/src/main/java/org/hibernate/dialect/MySQLDialect.java b/hibernate-core/src/main/java/org/hibernate/dialect/MySQLDialect.java index 7c5b87fda2..b3163f29a0 100644 --- a/hibernate-core/src/main/java/org/hibernate/dialect/MySQLDialect.java +++ b/hibernate-core/src/main/java/org/hibernate/dialect/MySQLDialect.java @@ -99,7 +99,7 @@ public class MySQLDialect extends Dialect { Long length) { switch ( jdbcType.getDefaultSqlTypeCode() ) { case Types.BIT: - // MySQL allows BIT with a length up to 64 (less the the default length 255) + // MySQL allows BIT with a length up to 64 (less the default length 255) if ( length != null ) { return Size.length( Math.min( Math.max( length, 1 ), 64 ) ); } diff --git a/hibernate-core/src/main/java/org/hibernate/engine/jdbc/SerializableNClobProxy.java b/hibernate-core/src/main/java/org/hibernate/engine/jdbc/SerializableNClobProxy.java index e7a7755bdd..3160c43c39 100644 --- a/hibernate-core/src/main/java/org/hibernate/engine/jdbc/SerializableNClobProxy.java +++ b/hibernate-core/src/main/java/org/hibernate/engine/jdbc/SerializableNClobProxy.java @@ -23,7 +23,7 @@ public class SerializableNClobProxy extends SerializableClobProxy { * * @param clob The possible NClob reference * - * @return {@code true} if the the Clob is a NClob as well + * @return {@code true} if the Clob is a NClob as well * * @deprecated ORM baselines on JDK 1.6, so optional support for NClob (JDK 1,6 addition) is no longer needed. */ diff --git a/hibernate-core/src/main/java/org/hibernate/engine/jdbc/dialect/spi/DialectResolver.java b/hibernate-core/src/main/java/org/hibernate/engine/jdbc/dialect/spi/DialectResolver.java index 5c9ee26151..16aba8e99b 100644 --- a/hibernate-core/src/main/java/org/hibernate/engine/jdbc/dialect/spi/DialectResolver.java +++ b/hibernate-core/src/main/java/org/hibernate/engine/jdbc/dialect/spi/DialectResolver.java @@ -18,7 +18,7 @@ import org.hibernate.service.Service; public interface DialectResolver extends Service { /** * Determine the {@link Dialect} to use based on the given information. Implementations are expected to return - * the {@link Dialect} instance to use, or {@code null} if the they did not locate a match. + * the {@link Dialect} instance to use, or {@code null} if they did not locate a match. * * @param info Access to the information about the database/driver needed to perform the resolution * diff --git a/hibernate-core/src/main/java/org/hibernate/engine/jdbc/internal/FormatStyle.java b/hibernate-core/src/main/java/org/hibernate/engine/jdbc/internal/FormatStyle.java index 5ac437639f..720b76e654 100644 --- a/hibernate-core/src/main/java/org/hibernate/engine/jdbc/internal/FormatStyle.java +++ b/hibernate-core/src/main/java/org/hibernate/engine/jdbc/internal/FormatStyle.java @@ -7,7 +7,7 @@ package org.hibernate.engine.jdbc.internal; /** - * Represents the the understood types or styles of formatting. + * Represents the understood types or styles of formatting. * * @author Steve Ebersole */ diff --git a/hibernate-core/src/main/java/org/hibernate/id/IdentifierGeneratorHelper.java b/hibernate-core/src/main/java/org/hibernate/id/IdentifierGeneratorHelper.java index f12f0273ab..c872064d73 100644 --- a/hibernate-core/src/main/java/org/hibernate/id/IdentifierGeneratorHelper.java +++ b/hibernate-core/src/main/java/org/hibernate/id/IdentifierGeneratorHelper.java @@ -59,7 +59,7 @@ public final class IdentifierGeneratorHelper { /** * Get the generated identifier when using identity columns * - * @param rs The result set from which to extract the the generated identity. + * @param rs The result set from which to extract the generated identity. * @param identifier The name of the identifier column * @param type The expected type mapping for the identity value. * @param dialect The current database dialect. diff --git a/hibernate-core/src/main/java/org/hibernate/jpa/spi/JpaCompliance.java b/hibernate-core/src/main/java/org/hibernate/jpa/spi/JpaCompliance.java index 3078718be4..18e45eb04d 100644 --- a/hibernate-core/src/main/java/org/hibernate/jpa/spi/JpaCompliance.java +++ b/hibernate-core/src/main/java/org/hibernate/jpa/spi/JpaCompliance.java @@ -92,7 +92,7 @@ public interface JpaCompliance { boolean isJpaCacheComplianceEnabled(); /** - * Should the the scope of {@link jakarta.persistence.TableGenerator#name()} and + * Should the scope of {@link jakarta.persistence.TableGenerator#name()} and * {@link jakarta.persistence.SequenceGenerator#name()} be considered globally or locally * defined? * diff --git a/hibernate-core/src/main/java/org/hibernate/metamodel/model/domain/AbstractManagedType.java b/hibernate-core/src/main/java/org/hibernate/metamodel/model/domain/AbstractManagedType.java index 6db0d33bb1..f468b9c200 100644 --- a/hibernate-core/src/main/java/org/hibernate/metamodel/model/domain/AbstractManagedType.java +++ b/hibernate-core/src/main/java/org/hibernate/metamodel/model/domain/AbstractManagedType.java @@ -240,7 +240,7 @@ public abstract class AbstractManagedType if ( attribute == null ) { throw new IllegalArgumentException( String.format( - "Unable to locate %s with the the given name [%s] on this ManagedType [%s]", + "Unable to locate %s with the given name [%s] on this ManagedType [%s]", attributeType, name, getTypeName() diff --git a/hibernate-core/src/main/java/org/hibernate/persister/entity/AbstractEntityPersister.java b/hibernate-core/src/main/java/org/hibernate/persister/entity/AbstractEntityPersister.java index 58f14b3d16..62e15328d9 100644 --- a/hibernate-core/src/main/java/org/hibernate/persister/entity/AbstractEntityPersister.java +++ b/hibernate-core/src/main/java/org/hibernate/persister/entity/AbstractEntityPersister.java @@ -456,8 +456,8 @@ public abstract class AbstractEntityPersister * @JoinTable's. * * Probably this method needs to be properly implemented for the various entity persisters, - * but this at least fixes the SingleTableEntityPersister, while maintaining the the - * previous behaviour for other persisters. + * but this at least fixes the SingleTableEntityPersister, while maintaining the previous + * behaviour for other persisters. */ return isClassOrSuperclassTable( j ); } diff --git a/hibernate-core/src/main/java/org/hibernate/query/TemporalUnit.java b/hibernate-core/src/main/java/org/hibernate/query/TemporalUnit.java index bfc5e0869d..05f05a7f75 100644 --- a/hibernate-core/src/main/java/org/hibernate/query/TemporalUnit.java +++ b/hibernate-core/src/main/java/org/hibernate/query/TemporalUnit.java @@ -238,7 +238,7 @@ public enum TemporalUnit { * Obtain a fragment of SQL that can be used to perform * a unit conversion. If the normalization factor is * very large, represent it using exponential form so - * as to minimize the noise the the generated SQL. + * as to minimize the noise the generated SQL. * * @param factor the conversion factor * @return a string to inject into the SQL expression diff --git a/hibernate-core/src/main/java/org/hibernate/resource/transaction/backend/jta/internal/synchronization/AfterCompletionAction.java b/hibernate-core/src/main/java/org/hibernate/resource/transaction/backend/jta/internal/synchronization/AfterCompletionAction.java index dd6f52c342..9c77ff1b8c 100644 --- a/hibernate-core/src/main/java/org/hibernate/resource/transaction/backend/jta/internal/synchronization/AfterCompletionAction.java +++ b/hibernate-core/src/main/java/org/hibernate/resource/transaction/backend/jta/internal/synchronization/AfterCompletionAction.java @@ -12,7 +12,7 @@ import org.hibernate.engine.spi.SessionImplementor; /** * A pluggable strategy for defining any actions to be performed during - * {@link jakarta.transaction.Synchronization#afterCompletion} processing from the the + * {@link jakarta.transaction.Synchronization#afterCompletion} processing from the * {@link jakarta.transaction.Synchronization} registered by Hibernate with the underlying JTA platform. * * @author Steve Ebersole diff --git a/hibernate-core/src/main/java/org/hibernate/service/spi/SessionFactoryServiceInitiator.java b/hibernate-core/src/main/java/org/hibernate/service/spi/SessionFactoryServiceInitiator.java index 21a8f20a52..2dfde48a0f 100644 --- a/hibernate-core/src/main/java/org/hibernate/service/spi/SessionFactoryServiceInitiator.java +++ b/hibernate-core/src/main/java/org/hibernate/service/spi/SessionFactoryServiceInitiator.java @@ -39,8 +39,8 @@ public interface SessionFactoryServiceInitiator extends Servi *

* Note for implementors: signature is guaranteed to change once redesign of SessionFactory building is complete * - * @param sessionFactory The session factory. Note the the session factory is still in flux; care needs to be taken - * in regards to what you call. + * @param sessionFactory The session factory. Note the session factory is still in flux; care needs to be taken + * regarding what you call. * @param sessionFactoryOptions Options specified for building the SessionFactory * @param registry The service registry. Can be used to locate services needed to fulfill initiation. * diff --git a/hibernate-core/src/main/java/org/hibernate/sql/Template.java b/hibernate-core/src/main/java/org/hibernate/sql/Template.java index d3bf4d8013..e16d2be4b5 100644 --- a/hibernate-core/src/main/java/org/hibernate/sql/Template.java +++ b/hibernate-core/src/main/java/org/hibernate/sql/Template.java @@ -124,7 +124,7 @@ public final class Template { * named parameters. * * @param sqlWhereString The string into which to interpolate the placeholder value - * @param placeholder The value to be interpolated into the the sqlWhereString + * @param placeholder The value to be interpolated into the sqlWhereString * @param dialect The dialect to apply * @param functionRegistry The registry of all sql functions * @return The rendered sql fragment @@ -372,7 +372,7 @@ public final class Template { // * named parameters. // * // * @param sqlWhereString The string into which to interpolate the placeholder value -// * @param placeholder The value to be interpolated into the the sqlWhereString +// * @param placeholder The value to be interpolated into the sqlWhereString // * @param dialect The dialect to apply // * @param functionRegistry The registry of all sql functions // * diff --git a/hibernate-core/src/main/java/org/hibernate/tool/schema/spi/SchemaManagementToolCoordinator.java b/hibernate-core/src/main/java/org/hibernate/tool/schema/spi/SchemaManagementToolCoordinator.java index d80591344b..ae894857f2 100644 --- a/hibernate-core/src/main/java/org/hibernate/tool/schema/spi/SchemaManagementToolCoordinator.java +++ b/hibernate-core/src/main/java/org/hibernate/tool/schema/spi/SchemaManagementToolCoordinator.java @@ -604,7 +604,7 @@ public class SchemaManagementToolCoordinator { /** * For JPA-style schema-gen, database and script target handing are configured - * individually - this tuple allows interpreting the the action for both targets + * individually - this tuple allows interpreting the action for both targets * simultaneously */ public static class ActionGrouping { diff --git a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeRegistry.java b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeRegistry.java index 59d3be1d1a..7f1352985a 100644 --- a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeRegistry.java +++ b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeRegistry.java @@ -59,7 +59,7 @@ public class JavaTypeRegistry implements JavaTypeBaseline.BaselineTarget, Serial private void performInjections(JavaType descriptor) { if ( descriptor instanceof TypeConfigurationAware ) { - // would be nice to make the JavaType for an entity, e.g., aware of the the TypeConfiguration + // would be nice to make the JavaType for an entity, e.g., aware of the TypeConfiguration ( (TypeConfigurationAware) descriptor ).setTypeConfiguration( typeConfiguration ); } } diff --git a/hibernate-core/src/test/java/org/hibernate/orm/test/readonly/ReadOnlyVersionedNodesTest.java b/hibernate-core/src/test/java/org/hibernate/orm/test/readonly/ReadOnlyVersionedNodesTest.java index 06d705c11c..5951eb164b 100644 --- a/hibernate-core/src/test/java/org/hibernate/orm/test/readonly/ReadOnlyVersionedNodesTest.java +++ b/hibernate-core/src/test/java/org/hibernate/orm/test/readonly/ReadOnlyVersionedNodesTest.java @@ -585,7 +585,7 @@ public class ReadOnlyVersionedNodesTest extends AbstractReadOnlyTest { assertEquals( 0, child.getVersion() ); assertNotNull( parent ); assertEquals( 0, parent.getChildren().size() ); - assertEquals( 1, parent.getVersion() ); // hmmm, why is was version updated? + assertEquals( 1, parent.getVersion() ); // hmmm, why was version updated? session.setReadOnly( parent, true ); session.setReadOnly( child, true ); session.delete( parent ); @@ -629,7 +629,7 @@ public class ReadOnlyVersionedNodesTest extends AbstractReadOnlyTest { assertEquals( 0, child.getVersion() ); assertNotNull( parent ); assertEquals( 0, parent.getChildren().size() ); - assertEquals( 1, parent.getVersion() ); // / hmmm, why is was version updated? + assertEquals( 1, parent.getVersion() ); // / hmmm, why was version updated? session.setReadOnly( parent, true ); session.setReadOnly( child, true ); session.delete( parent ); diff --git a/hibernate-core/src/test/java/org/hibernate/orm/test/sql/exec/onetoone/bidirectional/EntityWithBidirectionalOneToOneTest.java b/hibernate-core/src/test/java/org/hibernate/orm/test/sql/exec/onetoone/bidirectional/EntityWithBidirectionalOneToOneTest.java index 5348351050..27f99b2e7f 100644 --- a/hibernate-core/src/test/java/org/hibernate/orm/test/sql/exec/onetoone/bidirectional/EntityWithBidirectionalOneToOneTest.java +++ b/hibernate-core/src/test/java/org/hibernate/orm/test/sql/exec/onetoone/bidirectional/EntityWithBidirectionalOneToOneTest.java @@ -370,7 +370,7 @@ public class EntityWithBidirectionalOneToOneTest { fetchablePath: AdoptedChild.biologicalMother.biologicalChild.mother --- Circular --- fetchablePath: AdoptedChild.biologicalMother.adopted --- NO circular --- fetchablePath: AdoptedChild.biologicalMother.adopted.biologicalMother --- NO circular --- - fetchablePath: AdoptedChild.biologicalMother.adopted.biologicalMother.biologicalChild --- NO circular --- [N.b is is not circular because adoped is an instance of AdoptedChild while biologicalChild is an instance of Child] + fetchablePath: AdoptedChild.biologicalMother.adopted.biologicalMother.biologicalChild --- NO circular --- [N.b is not circular because adopted is an instance of AdoptedChild while biologicalChild is an instance of Child] fetchablePath: AdoptedChild.biologicalMother.adopted.biologicalMother.adopted --- NO circular --- fetchablePath: AdoptedChild.biologicalMother.adopted.biologicalMother.adopted.biologicalMother --- NO circular --- fetchablePath: AdoptedChild.biologicalMother.adopted.biologicalMother.adopted.biologicalMother.biologicalChild --- NO circular --- diff --git a/hibernate-testing/src/main/java/org/hibernate/testing/orm/domain/DomainModelDescriptor.java b/hibernate-testing/src/main/java/org/hibernate/testing/orm/domain/DomainModelDescriptor.java index cf207a1259..47ce3c7dd0 100644 --- a/hibernate-testing/src/main/java/org/hibernate/testing/orm/domain/DomainModelDescriptor.java +++ b/hibernate-testing/src/main/java/org/hibernate/testing/orm/domain/DomainModelDescriptor.java @@ -55,8 +55,8 @@ public interface DomainModelDescriptor { * Identifies the specific mapping features this domain model uses. */ default EnumSet getMappingFeaturesUsed() { - // for now just return none. this is is simply informative, not used to - // drive any functionality - so maybe its not important to add + // for now just return none. this is simply informative, not used to + // drive any functionality - so maybe it's not important to add return EnumSet.noneOf( MappingFeature.class ); } }