From 14db0238c20da1874c07a70319e2b41fa298a17f Mon Sep 17 00:00:00 2001 From: Mattias Arthursson Date: Wed, 22 Oct 2008 13:19:05 +0000 Subject: [PATCH] Removed redundant 'public' modifiers from interfaces. --- .../core/AttributeModificationsAware.java | 2 +- .../ldap/core/AttributesMapper.java | 2 +- .../ldap/core/AuthenticationSource.java | 4 +- .../ldap/core/ContextAssembler.java | 2 +- .../ldap/core/ContextExecutor.java | 2 +- .../ldap/core/ContextMapper.java | 2 +- .../ldap/core/ContextSource.java | 7 +- .../ldap/core/DirContextOperations.java | 2 + .../ldap/core/DirContextProcessor.java | 4 +- .../ldap/core/LdapOperations.java | 142 +++++++++--------- .../core/NameClassPairCallbackHandler.java | 2 +- .../ldap/core/NameClassPairMapper.java | 2 +- .../ldap/core/SearchExecutor.java | 2 +- .../ldap/core/support/BaseLdapPathAware.java | 2 +- .../springframework/ldap/filter/Filter.java | 59 ++++---- .../pool/validation/DirContextValidator.java | 2 +- .../TempEntryRenamingStrategy.java | 2 +- ...pensatingTransactionOperationExecutor.java | 6 +- ...mpensatingTransactionOperationFactory.java | 2 +- ...mpensatingTransactionOperationManager.java | 6 +- ...pensatingTransactionOperationRecorder.java | 2 +- 21 files changed, 129 insertions(+), 127 deletions(-) diff --git a/core/src/main/java/org/springframework/ldap/core/AttributeModificationsAware.java b/core/src/main/java/org/springframework/ldap/core/AttributeModificationsAware.java index 089ca336..405947b1 100644 --- a/core/src/main/java/org/springframework/ldap/core/AttributeModificationsAware.java +++ b/core/src/main/java/org/springframework/ldap/core/AttributeModificationsAware.java @@ -33,5 +33,5 @@ public interface AttributeModificationsAware { * * @return an array of modification items. */ - public ModificationItem[] getModificationItems(); + ModificationItem[] getModificationItems(); } diff --git a/core/src/main/java/org/springframework/ldap/core/AttributesMapper.java b/core/src/main/java/org/springframework/ldap/core/AttributesMapper.java index b090bf1f..91637840 100644 --- a/core/src/main/java/org/springframework/ldap/core/AttributesMapper.java +++ b/core/src/main/java/org/springframework/ldap/core/AttributesMapper.java @@ -50,6 +50,6 @@ public interface AttributesMapper { * @throws NamingException * if any error occurs mapping the attributes */ - public Object mapFromAttributes(Attributes attributes) + Object mapFromAttributes(Attributes attributes) throws NamingException; } diff --git a/core/src/main/java/org/springframework/ldap/core/AuthenticationSource.java b/core/src/main/java/org/springframework/ldap/core/AuthenticationSource.java index 4f368e09..8939100f 100644 --- a/core/src/main/java/org/springframework/ldap/core/AuthenticationSource.java +++ b/core/src/main/java/org/springframework/ldap/core/AuthenticationSource.java @@ -29,12 +29,12 @@ public interface AuthenticationSource { * * @return the principal (userDn). */ - public String getPrincipal(); + String getPrincipal(); /** * Get the credentials to use when creating an authenticated context. * * @return the credentials (password). */ - public String getCredentials(); + String getCredentials(); } diff --git a/core/src/main/java/org/springframework/ldap/core/ContextAssembler.java b/core/src/main/java/org/springframework/ldap/core/ContextAssembler.java index 33403622..0c5a6cbb 100644 --- a/core/src/main/java/org/springframework/ldap/core/ContextAssembler.java +++ b/core/src/main/java/org/springframework/ldap/core/ContextAssembler.java @@ -32,5 +32,5 @@ public interface ContextAssembler extends ContextMapper { * @param ctx * the context to map to. */ - public void mapToContext(Object obj, Object ctx); + void mapToContext(Object obj, Object ctx); } diff --git a/core/src/main/java/org/springframework/ldap/core/ContextExecutor.java b/core/src/main/java/org/springframework/ldap/core/ContextExecutor.java index 3feb41bf..efd25835 100644 --- a/core/src/main/java/org/springframework/ldap/core/ContextExecutor.java +++ b/core/src/main/java/org/springframework/ldap/core/ContextExecutor.java @@ -46,5 +46,5 @@ public interface ContextExecutor { * @throws NamingException * if the operation resulted in one. */ - public Object executeWithContext(DirContext ctx) throws NamingException; + Object executeWithContext(DirContext ctx) throws NamingException; } diff --git a/core/src/main/java/org/springframework/ldap/core/ContextMapper.java b/core/src/main/java/org/springframework/ldap/core/ContextMapper.java index 2d82c243..c3a4c7e2 100644 --- a/core/src/main/java/org/springframework/ldap/core/ContextMapper.java +++ b/core/src/main/java/org/springframework/ldap/core/ContextMapper.java @@ -61,5 +61,5 @@ public interface ContextMapper { * ContextSource. * @return an object built from the data in the context. */ - public Object mapFromContext(Object ctx); + Object mapFromContext(Object ctx); } diff --git a/core/src/main/java/org/springframework/ldap/core/ContextSource.java b/core/src/main/java/org/springframework/ldap/core/ContextSource.java index 5c142d13..a8221435 100644 --- a/core/src/main/java/org/springframework/ldap/core/ContextSource.java +++ b/core/src/main/java/org/springframework/ldap/core/ContextSource.java @@ -41,7 +41,7 @@ public interface ContextSource { * @return A DirContext instance, never null. * @throws NamingException if some error occurs creating an DirContext. */ - public DirContext getReadOnlyContext() throws NamingException; + DirContext getReadOnlyContext() throws NamingException; /** * Gets a read-write DirContext instance. @@ -50,7 +50,7 @@ public interface ContextSource { * @throws NamingException if some error occurs creating an * DirContext. */ - public DirContext getReadWriteContext() throws NamingException; + DirContext getReadWriteContext() throws NamingException; /** * Gets a DirContext instance authenticated using the supplied @@ -61,6 +61,7 @@ public interface ContextSource { * @param credentials The credentials to use for authentication. * @return an authenticated DirContext instance, never * null. + * @since 1.3 */ - public DirContext getContext(String principal, String credentials) throws NamingException; + DirContext getContext(String principal, String credentials) throws NamingException; } \ No newline at end of file diff --git a/core/src/main/java/org/springframework/ldap/core/DirContextOperations.java b/core/src/main/java/org/springframework/ldap/core/DirContextOperations.java index 03dbfe60..8d16db99 100644 --- a/core/src/main/java/org/springframework/ldap/core/DirContextOperations.java +++ b/core/src/main/java/org/springframework/ldap/core/DirContextOperations.java @@ -187,6 +187,7 @@ public interface DirContextOperations extends DirContext, AttributeModifications * @return The url of the referred server, e.g. * ldap://localhost:389, or the empty string if this is not a * referral. + * @since 1.3 */ String getReferralUrl(); @@ -195,6 +196,7 @@ public interface DirContextOperations extends DirContext, AttributeModifications * * @return true if this instance results from a referral, * false otherwise. + * @since 1.3 */ boolean isReferral(); } \ No newline at end of file diff --git a/core/src/main/java/org/springframework/ldap/core/DirContextProcessor.java b/core/src/main/java/org/springframework/ldap/core/DirContextProcessor.java index 907a682e..ec902f82 100644 --- a/core/src/main/java/org/springframework/ldap/core/DirContextProcessor.java +++ b/core/src/main/java/org/springframework/ldap/core/DirContextProcessor.java @@ -37,7 +37,7 @@ public interface DirContextProcessor { * @throws NamingException * if thrown by the underlying operation. */ - public void preProcess(DirContext ctx) throws NamingException; + void preProcess(DirContext ctx) throws NamingException; /** * Perform post-processing on the supplied DirContext. @@ -47,5 +47,5 @@ public interface DirContextProcessor { * @throws NamingException * if thrown by the underlying operation. */ - public void postProcess(DirContext ctx) throws NamingException; + void postProcess(DirContext ctx) throws NamingException; } diff --git a/core/src/main/java/org/springframework/ldap/core/LdapOperations.java b/core/src/main/java/org/springframework/ldap/core/LdapOperations.java index 04dce7d2..a3637c0f 100644 --- a/core/src/main/java/org/springframework/ldap/core/LdapOperations.java +++ b/core/src/main/java/org/springframework/ldap/core/LdapOperations.java @@ -65,7 +65,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted as no entries being found. */ - public void search(SearchExecutor se, NameClassPairCallbackHandler handler, + void search(SearchExecutor se, NameClassPairCallbackHandler handler, DirContextProcessor processor) throws NamingException; /** @@ -93,7 +93,7 @@ public interface LdapOperations { * @see #search(Name, String, AttributesMapper) * @see #search(Name, String, ContextMapper) */ - public void search(SearchExecutor se, NameClassPairCallbackHandler handler) + void search(SearchExecutor se, NameClassPairCallbackHandler handler) throws NamingException; /** @@ -115,7 +115,7 @@ public interface LdapOperations { * @see #search(Name, String, AttributesMapper) * @see #search(Name, String, ContextMapper) */ - public Object executeReadOnly(ContextExecutor ce) throws NamingException; + Object executeReadOnly(ContextExecutor ce) throws NamingException; /** * Perform an operation (or series of operations) on a read-write context. @@ -136,7 +136,7 @@ public interface LdapOperations { * @see #rename(Name, Name) * @see #modifyAttributes(Name, ModificationItem[]) */ - public Object executeReadWrite(ContextExecutor ce) throws NamingException; + Object executeReadWrite(ContextExecutor ce) throws NamingException; /** * Search for all objects matching the supplied filter. Each @@ -161,7 +161,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void search(Name base, String filter, SearchControls controls, + void search(Name base, String filter, SearchControls controls, NameClassPairCallbackHandler handler) throws NamingException; /** @@ -183,7 +183,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void search(String base, String filter, SearchControls controls, + void search(String base, String filter, SearchControls controls, NameClassPairCallbackHandler handler) throws NamingException; /** @@ -214,7 +214,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void search(Name base, String filter, SearchControls controls, + void search(Name base, String filter, SearchControls controls, NameClassPairCallbackHandler handler, DirContextProcessor processor) throws NamingException; @@ -245,7 +245,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(String base, String filter, SearchControls controls, + List search(String base, String filter, SearchControls controls, AttributesMapper mapper, DirContextProcessor processor) throws NamingException; @@ -276,7 +276,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(Name base, String filter, SearchControls controls, + List search(Name base, String filter, SearchControls controls, AttributesMapper mapper, DirContextProcessor processor) throws NamingException; @@ -310,7 +310,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(String base, String filter, SearchControls controls, + List search(String base, String filter, SearchControls controls, ContextMapper mapper, DirContextProcessor processor) throws NamingException; @@ -344,7 +344,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(Name base, String filter, SearchControls controls, + List search(Name base, String filter, SearchControls controls, ContextMapper mapper, DirContextProcessor processor) throws NamingException; @@ -370,7 +370,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void search(String base, String filter, SearchControls controls, + void search(String base, String filter, SearchControls controls, NameClassPairCallbackHandler handler, DirContextProcessor processor) throws NamingException; @@ -398,7 +398,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void search(Name base, String filter, int searchScope, + void search(Name base, String filter, int searchScope, boolean returningObjFlag, NameClassPairCallbackHandler handler) throws NamingException; @@ -426,7 +426,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void search(String base, String filter, int searchScope, + void search(String base, String filter, int searchScope, boolean returningObjFlag, NameClassPairCallbackHandler handler) throws NamingException; @@ -448,7 +448,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void search(Name base, String filter, + void search(Name base, String filter, NameClassPairCallbackHandler handler) throws NamingException; /** @@ -469,7 +469,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void search(String base, String filter, + void search(String base, String filter, NameClassPairCallbackHandler handler) throws NamingException; /** @@ -497,7 +497,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(Name base, String filter, int searchScope, + List search(Name base, String filter, int searchScope, String[] attrs, AttributesMapper mapper) throws NamingException; /** @@ -525,7 +525,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(String base, String filter, int searchScope, + List search(String base, String filter, int searchScope, String[] attrs, AttributesMapper mapper) throws NamingException; /** @@ -549,7 +549,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(Name base, String filter, int searchScope, + List search(Name base, String filter, int searchScope, AttributesMapper mapper) throws NamingException; /** @@ -573,7 +573,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(String base, String filter, int searchScope, + List search(String base, String filter, int searchScope, AttributesMapper mapper) throws NamingException; /** @@ -595,7 +595,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(Name base, String filter, AttributesMapper mapper) + List search(Name base, String filter, AttributesMapper mapper) throws NamingException; /** @@ -617,7 +617,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(String base, String filter, AttributesMapper mapper) + List search(String base, String filter, AttributesMapper mapper) throws NamingException; /** @@ -645,7 +645,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(Name base, String filter, int searchScope, + List search(Name base, String filter, int searchScope, String[] attrs, ContextMapper mapper) throws NamingException; /** @@ -673,7 +673,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(String base, String filter, int searchScope, + List search(String base, String filter, int searchScope, String[] attrs, ContextMapper mapper) throws NamingException; /** @@ -697,7 +697,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(Name base, String filter, int searchScope, + List search(Name base, String filter, int searchScope, ContextMapper mapper) throws NamingException; /** @@ -721,7 +721,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(String base, String filter, int searchScope, + List search(String base, String filter, int searchScope, ContextMapper mapper) throws NamingException; /** @@ -745,7 +745,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(Name base, String filter, ContextMapper mapper) + List search(Name base, String filter, ContextMapper mapper) throws NamingException; /** @@ -769,7 +769,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(String base, String filter, ContextMapper mapper) + List search(String base, String filter, ContextMapper mapper) throws NamingException; /** @@ -793,7 +793,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(String base, String filter, SearchControls controls, + List search(String base, String filter, SearchControls controls, ContextMapper mapper) throws NamingException; /** @@ -820,7 +820,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(Name base, String filter, SearchControls controls, + List search(Name base, String filter, SearchControls controls, ContextMapper mapper) throws NamingException; /** @@ -844,7 +844,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(String base, String filter, SearchControls controls, + List search(String base, String filter, SearchControls controls, AttributesMapper mapper) throws NamingException; /** @@ -868,7 +868,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List search(Name base, String filter, SearchControls controls, + List search(Name base, String filter, SearchControls controls, AttributesMapper mapper) throws NamingException; /** @@ -886,7 +886,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void list(String base, NameClassPairCallbackHandler handler) + void list(String base, NameClassPairCallbackHandler handler) throws NamingException; /** @@ -904,7 +904,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void list(Name base, NameClassPairCallbackHandler handler) + void list(Name base, NameClassPairCallbackHandler handler) throws NamingException; /** @@ -925,7 +925,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List list(String base, NameClassPairMapper mapper) + List list(String base, NameClassPairMapper mapper) throws NamingException; /** @@ -946,7 +946,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List list(Name base, NameClassPairMapper mapper) + List list(Name base, NameClassPairMapper mapper) throws NamingException; /** @@ -962,7 +962,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List list(String base) throws NamingException; + List list(String base) throws NamingException; /** * Perform a non-recursive listing of the children of the given @@ -977,7 +977,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List list(Name base) throws NamingException; + List list(Name base) throws NamingException; /** * Perform a non-recursive listing of the children of the given @@ -994,7 +994,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void listBindings(final String base, + void listBindings(final String base, NameClassPairCallbackHandler handler) throws NamingException; /** @@ -1012,7 +1012,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public void listBindings(final Name base, + void listBindings(final Name base, NameClassPairCallbackHandler handler) throws NamingException; /** @@ -1033,7 +1033,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List listBindings(String base, NameClassPairMapper mapper) + List listBindings(String base, NameClassPairMapper mapper) throws NamingException; /** @@ -1054,7 +1054,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List listBindings(Name base, NameClassPairMapper mapper) + List listBindings(Name base, NameClassPairMapper mapper) throws NamingException; /** @@ -1070,7 +1070,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List listBindings(final String base) throws NamingException; + List listBindings(final String base) throws NamingException; /** * Perform a non-recursive listing of children of the given @@ -1085,7 +1085,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List listBindings(final Name base) throws NamingException; + List listBindings(final Name base) throws NamingException; /** * Perform a non-recursive listing of the children of the given @@ -1104,7 +1104,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List listBindings(String base, ContextMapper mapper) + List listBindings(String base, ContextMapper mapper) throws NamingException; /** @@ -1124,7 +1124,7 @@ public interface LdapOperations { * NameNotFoundException will be ignored. Instead * this is interpreted that no entries were found. */ - public List listBindings(Name base, ContextMapper mapper) + List listBindings(Name base, ContextMapper mapper) throws NamingException; /** @@ -1140,7 +1140,7 @@ public interface LdapOperations { * @see #lookupContext(Name) * @see AbstractContextSource#setDirObjectFactory(Class) */ - public Object lookup(Name dn) throws NamingException; + Object lookup(Name dn) throws NamingException; /** * Lookup the supplied DN and return the found object. This will typically @@ -1155,7 +1155,7 @@ public interface LdapOperations { * @see #lookupContext(String) * @see AbstractContextSource#setDirObjectFactory(Class) */ - public Object lookup(String dn) throws NamingException; + Object lookup(String dn) throws NamingException; /** * Convenience method to get the attributes of a specified DN and @@ -1170,7 +1170,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public Object lookup(Name dn, AttributesMapper mapper) + Object lookup(Name dn, AttributesMapper mapper) throws NamingException; /** @@ -1186,7 +1186,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public Object lookup(String dn, AttributesMapper mapper) + Object lookup(String dn, AttributesMapper mapper) throws NamingException; /** @@ -1202,7 +1202,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public Object lookup(Name dn, ContextMapper mapper) throws NamingException; + Object lookup(Name dn, ContextMapper mapper) throws NamingException; /** * Convenience method to lookup a specified DN and automatically pass the @@ -1217,7 +1217,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public Object lookup(String dn, ContextMapper mapper) + Object lookup(String dn, ContextMapper mapper) throws NamingException; /** @@ -1235,7 +1235,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public Object lookup(Name dn, String[] attributes, AttributesMapper mapper) + Object lookup(Name dn, String[] attributes, AttributesMapper mapper) throws NamingException; /** @@ -1253,7 +1253,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public Object lookup(String dn, String[] attributes, AttributesMapper mapper) + Object lookup(String dn, String[] attributes, AttributesMapper mapper) throws NamingException; /** @@ -1271,7 +1271,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public Object lookup(Name dn, String[] attributes, ContextMapper mapper) + Object lookup(Name dn, String[] attributes, ContextMapper mapper) throws NamingException; /** @@ -1289,7 +1289,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public Object lookup(String dn, String[] attributes, ContextMapper mapper) + Object lookup(String dn, String[] attributes, ContextMapper mapper) throws NamingException; /** @@ -1304,7 +1304,7 @@ public interface LdapOperations { * if any error occurs. * @see #modifyAttributes(DirContextOperations) */ - public void modifyAttributes(Name dn, ModificationItem[] mods) + void modifyAttributes(Name dn, ModificationItem[] mods) throws NamingException; /** @@ -1319,7 +1319,7 @@ public interface LdapOperations { * if any error occurs. * @see #modifyAttributes(DirContextOperations) */ - public void modifyAttributes(String dn, ModificationItem[] mods) + void modifyAttributes(String dn, ModificationItem[] mods) throws NamingException; /** @@ -1339,7 +1339,7 @@ public interface LdapOperations { * if any error occurs. * @see DirContextAdapter */ - public void bind(Name dn, Object obj, Attributes attributes) + void bind(Name dn, Object obj, Attributes attributes) throws NamingException; /** @@ -1359,7 +1359,7 @@ public interface LdapOperations { * if any error occurs. * @see DirContextAdapter */ - public void bind(String dn, Object obj, Attributes attributes) + void bind(String dn, Object obj, Attributes attributes) throws NamingException; /** @@ -1372,7 +1372,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public void unbind(Name dn) throws NamingException; + void unbind(Name dn) throws NamingException; /** * Remove an entry from the LDAP tree. The entry must not have any children - @@ -1384,7 +1384,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public void unbind(String dn) throws NamingException; + void unbind(String dn) throws NamingException; /** * Remove an entry from the LDAP tree, optionally removing all descendants @@ -1399,7 +1399,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public void unbind(Name dn, boolean recursive) throws NamingException; + void unbind(Name dn, boolean recursive) throws NamingException; /** * Remove an entry from the LDAP tree, optionally removing all descendants @@ -1414,7 +1414,7 @@ public interface LdapOperations { * @throws NamingException * if any error occurs. */ - public void unbind(String dn, boolean recursive) throws NamingException; + void unbind(String dn, boolean recursive) throws NamingException; /** * Remove an entry and replace it with a new one. The attributes used to @@ -1434,7 +1434,7 @@ public interface LdapOperations { * if any error occurs. * @see DirContextAdapter */ - public void rebind(Name dn, Object obj, Attributes attributes) + void rebind(Name dn, Object obj, Attributes attributes) throws NamingException; /** @@ -1455,7 +1455,7 @@ public interface LdapOperations { * if any error occurs. * @see DirContextAdapter */ - public void rebind(String dn, Object obj, Attributes attributes) + void rebind(String dn, Object obj, Attributes attributes) throws NamingException; /** @@ -1472,7 +1472,7 @@ public interface LdapOperations { * @throws NamingException * if any other error occurs. */ - public void rename(final Name oldDn, final Name newDn) + void rename(final Name oldDn, final Name newDn) throws NamingException; /** @@ -1489,7 +1489,7 @@ public interface LdapOperations { * @throws NamingException * if any other error occurs. */ - public void rename(final String oldDn, final String newDn) + void rename(final String oldDn, final String newDn) throws NamingException; /** @@ -1510,7 +1510,7 @@ public interface LdapOperations { * @see #modifyAttributes(DirContextOperations) * @since 1.2 */ - public DirContextOperations lookupContext(Name dn) throws NamingException, + DirContextOperations lookupContext(Name dn) throws NamingException, ClassCastException; /** @@ -1531,7 +1531,7 @@ public interface LdapOperations { * @see #modifyAttributes(DirContextOperations) * @since 1.2 */ - public DirContextOperations lookupContext(String dn) + DirContextOperations lookupContext(String dn) throws NamingException, ClassCastException; /** @@ -1570,6 +1570,6 @@ public interface LdapOperations { * @see #lookupContext(Name) * @see DirContextAdapter */ - public void modifyAttributes(DirContextOperations ctx) + void modifyAttributes(DirContextOperations ctx) throws IllegalStateException, NamingException; } diff --git a/core/src/main/java/org/springframework/ldap/core/NameClassPairCallbackHandler.java b/core/src/main/java/org/springframework/ldap/core/NameClassPairCallbackHandler.java index 5913c4de..95ae2881 100644 --- a/core/src/main/java/org/springframework/ldap/core/NameClassPairCallbackHandler.java +++ b/core/src/main/java/org/springframework/ldap/core/NameClassPairCallbackHandler.java @@ -37,5 +37,5 @@ public interface NameClassPairCallbackHandler { * the NameClassPair returned from the * NamingEnumeration. */ - public void handleNameClassPair(NameClassPair nameClassPair); + void handleNameClassPair(NameClassPair nameClassPair); } diff --git a/core/src/main/java/org/springframework/ldap/core/NameClassPairMapper.java b/core/src/main/java/org/springframework/ldap/core/NameClassPairMapper.java index 8282368a..7c8319f5 100644 --- a/core/src/main/java/org/springframework/ldap/core/NameClassPairMapper.java +++ b/core/src/main/java/org/springframework/ldap/core/NameClassPairMapper.java @@ -39,6 +39,6 @@ public interface NameClassPairMapper { * @throws NamingException * if one is encountered in the operation. */ - public Object mapFromNameClassPair(NameClassPair nameClassPair) + Object mapFromNameClassPair(NameClassPair nameClassPair) throws NamingException; } diff --git a/core/src/main/java/org/springframework/ldap/core/SearchExecutor.java b/core/src/main/java/org/springframework/ldap/core/SearchExecutor.java index 36f3d2d2..9561e99c 100644 --- a/core/src/main/java/org/springframework/ldap/core/SearchExecutor.java +++ b/core/src/main/java/org/springframework/ldap/core/SearchExecutor.java @@ -47,6 +47,6 @@ public interface SearchExecutor { * @throws NamingException * if the search results in one. */ - public NamingEnumeration executeSearch(DirContext ctx) + NamingEnumeration executeSearch(DirContext ctx) throws NamingException; } diff --git a/core/src/main/java/org/springframework/ldap/core/support/BaseLdapPathAware.java b/core/src/main/java/org/springframework/ldap/core/support/BaseLdapPathAware.java index 45ebf5de..79642763 100644 --- a/core/src/main/java/org/springframework/ldap/core/support/BaseLdapPathAware.java +++ b/core/src/main/java/org/springframework/ldap/core/support/BaseLdapPathAware.java @@ -45,5 +45,5 @@ public interface BaseLdapPathAware { * ApplicationContext. * @param baseLdapPath the base path used in the ContextSource */ - public void setBaseLdapPath(DistinguishedName baseLdapPath); + void setBaseLdapPath(DistinguishedName baseLdapPath); } diff --git a/core/src/main/java/org/springframework/ldap/filter/Filter.java b/core/src/main/java/org/springframework/ldap/filter/Filter.java index 06cb9c8e..f90e3557 100644 --- a/core/src/main/java/org/springframework/ldap/filter/Filter.java +++ b/core/src/main/java/org/springframework/ldap/filter/Filter.java @@ -20,40 +20,39 @@ package org.springframework.ldap.filter; * Common interface for LDAP filters. * * @author Adam Skogman - * @see RFC 1960: A String Representation of LDAP Search Filters + * @see RFC 1960: A String + * Representation of LDAP Search Filters< /a> */ public interface Filter { - /** - * Encodes the filter to a String. - * - * @return The encoded filter in the standard String format - */ - public String encode(); + /** + * Encodes the filter to a String. + * + * @return The encoded filter in the standard String format + */ + String encode(); - /** - * Encodes the filter to a StringBuffer. - * - * @param buf - * The StringBuffer to encode the filter to - * @return The same StringBuffer as was given - */ - public StringBuffer encode(StringBuffer buf); + /** + * Encodes the filter to a StringBuffer. + * + * @param buf The StringBuffer to encode the filter to + * @return The same StringBuffer as was given + */ + StringBuffer encode(StringBuffer buf); - /** - * All filters must implement equals. - * - * @param o - * @return true if the objects are equal. - */ - public boolean equals(Object o); - - /** - * All filters must implement hashCode. - * - * @return the hash code according to the contract in - * {@link Object#hashCode()} - */ - public int hashCode(); + /** + * All filters must implement equals. + * + * @param o + * @return true if the objects are equal. + */ + boolean equals(Object o); + /** + * All filters must implement hashCode. + * + * @return the hash code according to the contract in + * {@link Object#hashCode()} + */ + int hashCode(); } \ No newline at end of file diff --git a/core/src/main/java/org/springframework/ldap/pool/validation/DirContextValidator.java b/core/src/main/java/org/springframework/ldap/pool/validation/DirContextValidator.java index 5eab0faf..813a05ee 100644 --- a/core/src/main/java/org/springframework/ldap/pool/validation/DirContextValidator.java +++ b/core/src/main/java/org/springframework/ldap/pool/validation/DirContextValidator.java @@ -35,5 +35,5 @@ public interface DirContextValidator { * @param dirContext The {@link DirContext} to validate. * @return true if the {@link DirContext} operated correctly during validation. */ - public boolean validateDirContext(DirContextType contextType, DirContext dirContext); + boolean validateDirContext(DirContextType contextType, DirContext dirContext); } diff --git a/core/src/main/java/org/springframework/ldap/transaction/compensating/TempEntryRenamingStrategy.java b/core/src/main/java/org/springframework/ldap/transaction/compensating/TempEntryRenamingStrategy.java index 1a47f7ab..88150e81 100644 --- a/core/src/main/java/org/springframework/ldap/transaction/compensating/TempEntryRenamingStrategy.java +++ b/core/src/main/java/org/springframework/ldap/transaction/compensating/TempEntryRenamingStrategy.java @@ -34,5 +34,5 @@ public interface TempEntryRenamingStrategy { * @return The name to which the entry should be temporarily renamed * according to this strategy. */ - public Name getTemporaryName(Name originalName); + Name getTemporaryName(Name originalName); } diff --git a/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationExecutor.java b/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationExecutor.java index afa196ad..73a208a0 100644 --- a/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationExecutor.java +++ b/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationExecutor.java @@ -43,14 +43,14 @@ public interface CompensatingTransactionOperationExecutor { * the operation was performed using the information supplied on creation of * this instance. */ - public void rollback(); + void rollback(); /** * Commit the operation. In many cases, this will not require any work at * all to be performed. However, in some cases there will be interesting * stuff to do. See class description for elaboration on this. */ - public void commit(); + void commit(); /** * Perform the operation. This will most often require performing the @@ -58,5 +58,5 @@ public interface CompensatingTransactionOperationExecutor { * this method might be something else. See class description for * elaboration on this. */ - public void performOperation(); + void performOperation(); } diff --git a/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationFactory.java b/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationFactory.java index d494e14f..86a8cdb2 100644 --- a/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationFactory.java +++ b/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationFactory.java @@ -39,6 +39,6 @@ public interface CompensatingTransactionOperationFactory { * * @return a new {@link CompensatingTransactionOperationRecorder} instance. */ - public CompensatingTransactionOperationRecorder createRecordingOperation( + CompensatingTransactionOperationRecorder createRecordingOperation( Object resource, String method); } diff --git a/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationManager.java b/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationManager.java index 5c117d8f..3117e2d1 100644 --- a/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationManager.java +++ b/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationManager.java @@ -38,18 +38,18 @@ public interface CompensatingTransactionOperationManager { * @param args * Arguments supplied to the method. */ - public void performOperation(Object resource, String operation, + void performOperation(Object resource, String operation, Object[] args); /** * Rollback all recorded operations by performing each of the recorded * rollback operations. */ - public void rollback(); + void rollback(); /** * Commit all recorded operations. In many cases this means doing nothing, * but in some cases some temporary data will need to be removed. */ - public void commit(); + void commit(); } diff --git a/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationRecorder.java b/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationRecorder.java index 9a9804bb..d842c873 100644 --- a/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationRecorder.java +++ b/core/src/main/java/org/springframework/transaction/compensating/CompensatingTransactionOperationRecorder.java @@ -36,6 +36,6 @@ public interface CompensatingTransactionOperationRecorder { * @return A {@link CompensatingTransactionOperationExecutor} to be used if * the recorded operation should need to be rolled back. */ - public CompensatingTransactionOperationExecutor recordOperation( + CompensatingTransactionOperationExecutor recordOperation( Object[] args); }