From f6fff99bcc0358e7d0f4d42b642fcd883a38b2b1 Mon Sep 17 00:00:00 2001 From: Oliver Gierke Date: Fri, 19 May 2017 10:59:16 +0200 Subject: [PATCH] DATALDAP-37 - Polishing. Fixed capitalization of Querydsl related classes. --- .../repository/support/LdapRepositoryFactory.java | 2 +- ...eryDslLdapQuery.java => QuerydslLdapQuery.java} | 14 +++++++------- ...Repository.java => QuerydslLdapRepository.java} | 10 +++++----- ...ests.java => QuerydslFilterGeneratorTests.java} | 2 +- 4 files changed, 14 insertions(+), 14 deletions(-) rename src/main/java/org/springframework/data/ldap/repository/support/{QueryDslLdapQuery.java => QuerydslLdapQuery.java} (86%) rename src/main/java/org/springframework/data/ldap/repository/support/{QueryDslLdapRepository.java => QuerydslLdapRepository.java} (92%) rename src/test/java/org/springframework/data/ldap/repository/support/{QueryDslFilterGeneratorTests.java => QuerydslFilterGeneratorTests.java} (98%) diff --git a/src/main/java/org/springframework/data/ldap/repository/support/LdapRepositoryFactory.java b/src/main/java/org/springframework/data/ldap/repository/support/LdapRepositoryFactory.java index ccc0e76..ae5c0a9 100644 --- a/src/main/java/org/springframework/data/ldap/repository/support/LdapRepositoryFactory.java +++ b/src/main/java/org/springframework/data/ldap/repository/support/LdapRepositoryFactory.java @@ -82,7 +82,7 @@ public class LdapRepositoryFactory extends RepositoryFactorySupport { boolean isQueryDslRepository = QUERY_DSL_PRESENT && QuerydslPredicateExecutor.class.isAssignableFrom(metadata.getRepositoryInterface()); - return isQueryDslRepository ? QueryDslLdapRepository.class : SimpleLdapRepository.class; + return isQueryDslRepository ? QuerydslLdapRepository.class : SimpleLdapRepository.class; } /* diff --git a/src/main/java/org/springframework/data/ldap/repository/support/QueryDslLdapQuery.java b/src/main/java/org/springframework/data/ldap/repository/support/QuerydslLdapQuery.java similarity index 86% rename from src/main/java/org/springframework/data/ldap/repository/support/QueryDslLdapQuery.java rename to src/main/java/org/springframework/data/ldap/repository/support/QuerydslLdapQuery.java index 47b6994..416e6ec 100644 --- a/src/main/java/org/springframework/data/ldap/repository/support/QueryDslLdapQuery.java +++ b/src/main/java/org/springframework/data/ldap/repository/support/QuerydslLdapQuery.java @@ -36,32 +36,32 @@ import com.querydsl.core.types.Predicate; * @author Eddu Melendez * @author Mark Paluch */ -public class QueryDslLdapQuery implements FilteredClause> { +public class QuerydslLdapQuery implements FilteredClause> { private final LdapOperations ldapOperations; private final Class entityType; private final LdapSerializer filterGenerator; - private QueryMixin> queryMixin = new QueryMixin<>(this, + private QueryMixin> queryMixin = new QueryMixin<>(this, new DefaultQueryMetadata().noValidate()); /** - * Creates a new {@link QueryDslLdapQuery}. + * Creates a new {@link QuerydslLdapQuery}. * * @param ldapOperations must not be {@literal null}. * @param entityPath must not be {@literal null}. */ - public QueryDslLdapQuery(LdapOperations ldapOperations, EntityPath entityPath) { + public QuerydslLdapQuery(LdapOperations ldapOperations, EntityPath entityPath) { this(ldapOperations, entityPath.getType()); } /** - * Creates a new {@link QueryDslLdapQuery}. + * Creates a new {@link QuerydslLdapQuery}. * * @param ldapOperations must not be {@literal null}. * @param entityType must not be {@literal null}. */ - public QueryDslLdapQuery(LdapOperations ldapOperations, Class entityType) { + public QuerydslLdapQuery(LdapOperations ldapOperations, Class entityType) { Assert.notNull(ldapOperations, "LdapOperations must not be null!"); Assert.notNull(entityType, "Type must not be null!"); @@ -75,7 +75,7 @@ public class QueryDslLdapQuery implements FilteredClause * @see com.querydsl.core.FilteredClause#where(com.querydsl.core.types.Predicate[]) */ @Override - public QueryDslLdapQuery where(Predicate... o) { + public QuerydslLdapQuery where(Predicate... o) { return queryMixin.where(o); } diff --git a/src/main/java/org/springframework/data/ldap/repository/support/QueryDslLdapRepository.java b/src/main/java/org/springframework/data/ldap/repository/support/QuerydslLdapRepository.java similarity index 92% rename from src/main/java/org/springframework/data/ldap/repository/support/QueryDslLdapRepository.java rename to src/main/java/org/springframework/data/ldap/repository/support/QuerydslLdapRepository.java index 33cca58..08126aa 100644 --- a/src/main/java/org/springframework/data/ldap/repository/support/QueryDslLdapRepository.java +++ b/src/main/java/org/springframework/data/ldap/repository/support/QuerydslLdapRepository.java @@ -36,19 +36,19 @@ import com.querydsl.core.types.Predicate; * @author Eddu Melendez * @author Mark Paluch */ -public class QueryDslLdapRepository extends SimpleLdapRepository implements QuerydslPredicateExecutor { +public class QuerydslLdapRepository extends SimpleLdapRepository implements QuerydslPredicateExecutor { private final LdapOperations ldapOperations; private final Class entityType; /** - * Creates a new {@link QueryDslLdapRepository}. + * Creates a new {@link QuerydslLdapRepository}. * * @param ldapOperations must not be {@literal null}. * @param odm must not be {@literal null}. * @param entityType must not be {@literal null}. */ - public QueryDslLdapRepository(LdapOperations ldapOperations, ObjectDirectoryMapper odm, Class entityType) { + public QuerydslLdapRepository(LdapOperations ldapOperations, ObjectDirectoryMapper odm, Class entityType) { super(ldapOperations, odm, entityType); this.ldapOperations = ldapOperations; @@ -99,8 +99,8 @@ public class QueryDslLdapRepository extends SimpleLdapRepository implement throw new UnsupportedOperationException(); } - private QueryDslLdapQuery queryFor(Predicate predicate) { - return new QueryDslLdapQuery<>(ldapOperations, entityType).where(predicate); + private QuerydslLdapQuery queryFor(Predicate predicate) { + return new QuerydslLdapQuery<>(ldapOperations, entityType).where(predicate); } /* (non-Javadoc) diff --git a/src/test/java/org/springframework/data/ldap/repository/support/QueryDslFilterGeneratorTests.java b/src/test/java/org/springframework/data/ldap/repository/support/QuerydslFilterGeneratorTests.java similarity index 98% rename from src/test/java/org/springframework/data/ldap/repository/support/QueryDslFilterGeneratorTests.java rename to src/test/java/org/springframework/data/ldap/repository/support/QuerydslFilterGeneratorTests.java index 797a645..7c14dad 100644 --- a/src/test/java/org/springframework/data/ldap/repository/support/QueryDslFilterGeneratorTests.java +++ b/src/test/java/org/springframework/data/ldap/repository/support/QuerydslFilterGeneratorTests.java @@ -29,7 +29,7 @@ import com.querydsl.core.types.Expression; * @author Mattias Hellborg Arthursson * @author Eddu Melendez */ -public class QueryDslFilterGeneratorTests { +public class QuerydslFilterGeneratorTests { private LdapSerializer tested; private QPerson person;