You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by el...@apache.org on 2008/05/12 13:49:46 UTC
svn commit: r655480 [3/11] - in /directory:
apacheds/trunk/apacheds-jdbm/src/examples/
apacheds/trunk/apacheds-jdbm/src/main/java/jdbm/btree/
apacheds/trunk/bootstrap-extract/src/main/java/org/apache/directory/server/schema/bootstrap/partition/
apached...
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java Mon May 12 04:49:35 2008
@@ -20,6 +20,10 @@
package org.apache.directory.server.core.authz;
+import javax.naming.directory.SearchControls;
+import javax.naming.NamingEnumeration;
+import javax.naming.NamingException;
+
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
@@ -52,9 +56,6 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
-import javax.naming.NamingEnumeration;
-import javax.naming.NamingException;
-import javax.naming.directory.SearchControls;
/**
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java Mon May 12 04:49:35 2008
@@ -20,6 +20,19 @@
package org.apache.directory.server.core.authz;
+import javax.naming.directory.SearchControls;
+import javax.naming.NamingEnumeration;
+import javax.naming.NamingException;
+
+import java.text.ParseException;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+
import org.apache.directory.server.core.DirectoryService;
import org.apache.directory.server.core.entry.ServerAttribute;
import org.apache.directory.server.core.entry.ServerEntry;
@@ -50,17 +63,6 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
-import javax.naming.NamingEnumeration;
-import javax.naming.NamingException;
-import javax.naming.directory.SearchControls;
-import java.text.ParseException;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
/**
* A cache for tuple sets which responds to specific events to perform
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilter.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilter.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilter.java Mon May 12 04:49:35 2008
@@ -46,9 +46,9 @@
{
public Collection<ACITuple> filter(
Registries registries,
- Collection<ACITuple> tuples,
- OperationScope scope,
- PartitionNexusProxy proxy,
+ Collection<ACITuple> tuples,
+ OperationScope scope,
+ PartitionNexusProxy proxy,
Collection<LdapDN> userGroupNames,
LdapDN userName,
ServerEntry userEntry,
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/MaxImmSubFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/MaxImmSubFilter.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/MaxImmSubFilter.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/MaxImmSubFilter.java Mon May 12 04:49:35 2008
@@ -20,6 +20,15 @@
package org.apache.directory.server.core.authz.support;
+import javax.naming.directory.SearchControls;
+import javax.naming.NamingEnumeration;
+import javax.naming.NamingException;
+
+import java.util.Collection;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.Iterator;
+
import org.apache.directory.server.core.authn.AuthenticationInterceptor;
import org.apache.directory.server.core.authz.AciAuthorizationInterceptor;
import org.apache.directory.server.core.authz.DefaultAuthorizationInterceptor;
@@ -44,13 +53,6 @@
import org.apache.directory.shared.ldap.message.AliasDerefMode;
import org.apache.directory.shared.ldap.name.LdapDN;
-import javax.naming.NamingEnumeration;
-import javax.naming.NamingException;
-import javax.naming.directory.SearchControls;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.Iterator;
/**
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/collective/CollectiveAttributeInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/collective/CollectiveAttributeInterceptor.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/collective/CollectiveAttributeInterceptor.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/collective/CollectiveAttributeInterceptor.java Mon May 12 04:49:35 2008
@@ -88,7 +88,7 @@
if ( name.isNormalized() == false )
{
- name = LdapDN.normalize( name, atRegistry.getNormalizerMapping() );
+ name = LdapDN.normalize( name, atRegistry.getNormalizerMapping() );
}
ServerEntry entry = result.getServerEntry();
@@ -128,7 +128,7 @@
if ( ( retAttrs == null ) || ( retAttrs.length != 1 ) || ( retAttrs[0] != SchemaConstants.ALL_USER_ATTRIBUTES ) )
{
ServerEntry entryWithCAS = nexus.lookup( new LookupOperationContext( registries, normName, new String[] {
- SchemaConstants.COLLECTIVE_ATTRIBUTE_SUBENTRIES_AT_OID } ) );
+ SchemaConstants.COLLECTIVE_ATTRIBUTE_SUBENTRIES_AT_OID } ) );
caSubentries = entryWithCAS.get( SchemaConstants.COLLECTIVE_ATTRIBUTE_SUBENTRIES_AT );
}
else
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/enumeration/ReferralHandlingEnumeration.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/enumeration/ReferralHandlingEnumeration.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/enumeration/ReferralHandlingEnumeration.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/enumeration/ReferralHandlingEnumeration.java Mon May 12 04:49:35 2008
@@ -81,7 +81,7 @@
int scope,
boolean doThrow ) throws NamingException
{
- normalizerMap = registries.getAttributeTypeRegistry().getNormalizerMapping();
+ normalizerMap = registries.getAttributeTypeRegistry().getNormalizerMapping();
this.underlying = underlying;
this.doThrow = doThrow;
this.lut = lut;
@@ -96,7 +96,7 @@
{
while ( underlying.hasMore() )
{
- ServerSearchResult result = underlying.next();
+ ServerSearchResult result = underlying.next();
LdapDN dn = new LdapDN( result.getDn() );
dn.normalize( normalizerMap );
@@ -121,7 +121,7 @@
public ServerSearchResult next() throws NamingException
{
- ServerSearchResult retval = prefetched;
+ ServerSearchResult retval = prefetched;
prefetch();
return retval;
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/enumeration/SearchResultFilteringEnumeration.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/enumeration/SearchResultFilteringEnumeration.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/enumeration/SearchResultFilteringEnumeration.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/enumeration/SearchResultFilteringEnumeration.java Mon May 12 04:49:35 2008
@@ -212,7 +212,7 @@
public ServerSearchResult next() throws NamingException
{
- ServerSearchResult retVal = this.prefetched;
+ ServerSearchResult retVal = this.prefetched;
prefetch();
return retVal;
}
@@ -230,7 +230,7 @@
public ServerSearchResult nextElement()
{
- ServerSearchResult retVal = this.prefetched;
+ ServerSearchResult retVal = this.prefetched;
try
{
@@ -291,8 +291,8 @@
*/
private void prefetch() throws NamingException
{
- ServerSearchResult tmp;
-
+ ServerSearchResult tmp;
+
if ( abandoned )
{
this.close();
@@ -361,6 +361,6 @@
public String toString()
{
- return name;
+ return name;
}
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/exception/ExceptionInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/exception/ExceptionInterceptor.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/exception/ExceptionInterceptor.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/exception/ExceptionInterceptor.java Mon May 12 04:49:35 2008
@@ -144,8 +144,8 @@
public void add( NextInterceptor nextInterceptor, AddOperationContext opContext )
throws NamingException
{
- LdapDN name = opContext.getDn();
-
+ LdapDN name = opContext.getDn();
+
if ( subschemSubentryDn.getNormName().equals( name.getNormName() ) )
{
throw new LdapNameAlreadyBoundException(
@@ -168,13 +168,13 @@
synchronized( notAliasCache )
{
- notAnAlias = notAliasCache.containsKey( parentDn.getNormName() );
+ notAnAlias = notAliasCache.containsKey( parentDn.getNormName() );
}
if ( ! notAnAlias )
{
- // We don't know if the parent is an alias or not, so we will launch a
- // lookup, and update the cache if it's not an alias
+ // We don't know if the parent is an alias or not, so we will launch a
+ // lookup, and update the cache if it's not an alias
ServerEntry attrs;
try
@@ -201,10 +201,10 @@
}
else
{
- synchronized ( notAliasCache )
- {
- notAliasCache.put( parentDn.getNormName(), parentDn );
- }
+ synchronized ( notAliasCache )
+ {
+ notAliasCache.put( parentDn.getNormName(), parentDn );
+ }
}
}
@@ -218,8 +218,8 @@
*/
public void delete( NextInterceptor nextInterceptor, DeleteOperationContext opContext ) throws NamingException
{
- LdapDN name = opContext.getDn();
-
+ LdapDN name = opContext.getDn();
+
if ( name.getNormName().equalsIgnoreCase( subschemSubentryDn.getNormName() ) )
{
throw new LdapOperationNotSupportedException(
@@ -252,10 +252,10 @@
synchronized( notAliasCache )
{
- if ( notAliasCache.containsKey( name.getNormName() ) )
- {
- notAliasCache.remove( name.getNormName() );
- }
+ if ( notAliasCache.containsKey( name.getNormName() ) )
+ {
+ notAliasCache.remove( name.getNormName() );
+ }
}
nextInterceptor.delete( opContext );
@@ -349,10 +349,10 @@
// it would also be more complex.
synchronized( notAliasCache )
{
- if ( notAliasCache.containsKey( opContext.getDn().getNormName() ) )
- {
- notAliasCache.remove( opContext.getDn().getNormName() );
- }
+ if ( notAliasCache.containsKey( opContext.getDn().getNormName() ) )
+ {
+ notAliasCache.remove( opContext.getDn().getNormName() );
+ }
}
nextInterceptor.modify( opContext );
@@ -395,10 +395,10 @@
// Remove the previous entry from the notAnAlias cache
synchronized( notAliasCache )
{
- if ( notAliasCache.containsKey( dn.getNormName() ) )
- {
- notAliasCache.remove( dn.getNormName() );
- }
+ if ( notAliasCache.containsKey( dn.getNormName() ) )
+ {
+ notAliasCache.remove( dn.getNormName() );
+ }
}
nextInterceptor.rename( opContext );
@@ -451,10 +451,10 @@
// Remove the original entry from the NotAlias cache, if needed
synchronized( notAliasCache )
{
- if ( notAliasCache.containsKey( oriChildName.getNormName() ) )
- {
- notAliasCache.remove( oriChildName.getNormName() );
- }
+ if ( notAliasCache.containsKey( oriChildName.getNormName() ) )
+ {
+ notAliasCache.remove( oriChildName.getNormName() );
+ }
}
nextInterceptor.move( opContext );
@@ -505,10 +505,10 @@
// Remove the original entry from the NotAlias cache, if needed
synchronized( notAliasCache )
{
- if ( notAliasCache.containsKey( oriChildName.getNormName() ) )
- {
- notAliasCache.remove( oriChildName.getNormName() );
- }
+ if ( notAliasCache.containsKey( oriChildName.getNormName() ) )
+ {
+ notAliasCache.remove( oriChildName.getNormName() );
+ }
}
nextInterceptor.moveAndRename( opContext );
@@ -524,18 +524,18 @@
try
{
- NamingEnumeration<ServerSearchResult> result = nextInterceptor.search( opContext );
-
- if ( ! result.hasMoreElements() )
- {
- if ( !base.isEmpty() && !( subschemSubentryDn.toNormName() ).equalsIgnoreCase( base.toNormName() ) )
- {
- // We just check that the entry exists only if we didn't found any entry
- assertHasEntry( nextInterceptor, "Attempt to search under non-existant entry:" , base );
- }
- }
+ NamingEnumeration<ServerSearchResult> result = nextInterceptor.search( opContext );
+
+ if ( ! result.hasMoreElements() )
+ {
+ if ( !base.isEmpty() && !( subschemSubentryDn.toNormName() ).equalsIgnoreCase( base.toNormName() ) )
+ {
+ // We just check that the entry exists only if we didn't found any entry
+ assertHasEntry( nextInterceptor, "Attempt to search under non-existant entry:" , base );
+ }
+ }
- return result;
+ return result;
}
catch ( NamingException ne )
{
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/CompareOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/CompareOperationContext.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/CompareOperationContext.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/CompareOperationContext.java Mon May 12 04:49:35 2008
@@ -46,7 +46,7 @@
*/
public CompareOperationContext( Registries registries )
{
- super( registries );
+ super( registries );
}
/**
@@ -66,7 +66,7 @@
*/
public CompareOperationContext( Registries registries, String oid )
{
- super( registries );
+ super( registries );
this.oid = oid;
}
@@ -77,7 +77,7 @@
*/
public CompareOperationContext( Registries registries, LdapDN dn, String oid )
{
- super( registries, dn );
+ super( registries, dn );
this.oid = oid;
}
@@ -88,7 +88,7 @@
*/
public CompareOperationContext( Registries registries, LdapDN dn, String oid, Object value )
{
- super( registries, dn );
+ super( registries, dn );
this.oid = oid;
this.value = value;
}
@@ -96,51 +96,51 @@
/**
* @return The compared OID
*/
- public String getOid()
- {
- return oid;
- }
-
- /**
- * Set the compared OID
- * @param oid The compared OID
- */
- public void setOid( String oid )
- {
- this.oid = oid;
- }
-
- /**
- * @return The value to compare
- */
- public Object getValue()
- {
- return value;
- }
-
- /**
- * Set the value to compare
- * @param value The value to compare
- */
- public void setValue( Object value )
- {
- this.value = value;
- }
+ public String getOid()
+ {
+ return oid;
+ }
+
+ /**
+ * Set the compared OID
+ * @param oid The compared OID
+ */
+ public void setOid( String oid )
+ {
+ this.oid = oid;
+ }
+
+ /**
+ * @return The value to compare
+ */
+ public Object getValue()
+ {
+ return value;
+ }
- /**
+ /**
+ * Set the value to compare
+ * @param value The value to compare
+ */
+ public void setValue( Object value )
+ {
+ this.value = value;
+ }
+
+ /**
* @see Object#toString()
*/
public String toString()
{
return "CompareContext for DN '" + getDn().getUpName() + "'" +
- ( ( oid != null ) ? ", oid : <" + oid + ">" : "" ) +
- ( ( value != null ) ? ", value :'" +
- ( ( value instanceof String ) ?
- value :
- ( ( value instanceof byte[] ) ?
- StringTools.dumpBytes( (byte[])value ) :
- "unknown value type" ) )
- + "'"
- : "" );
+ ( ( oid != null ) ? ", oid : <" + oid + ">" : "" ) +
+ ( ( value != null ) ? ", value :'" +
+ ( ( value instanceof String ) ?
+ value :
+ ( ( value instanceof byte[] ) ?
+ StringTools.dumpBytes( (byte[])value ) :
+ "unknown value type" ) )
+ + "'"
+ : "" );
}
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/LookupOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/LookupOperationContext.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/LookupOperationContext.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/LookupOperationContext.java Mon May 12 04:49:35 2008
@@ -49,7 +49,7 @@
*/
public LookupOperationContext( Registries registries )
{
- super( registries );
+ super( registries );
}
/**
@@ -69,7 +69,7 @@
*/
public LookupOperationContext( Registries registries, String attrsId[] )
{
- super( registries );
+ super( registries );
this.attrsId = new ArrayList<String>();
attrsOid = new ArrayList<String>();
setAttrsId( attrsId );
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveAndRenameOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveAndRenameOperationContext.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveAndRenameOperationContext.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveAndRenameOperationContext.java Mon May 12 04:49:35 2008
@@ -43,7 +43,7 @@
*/
public MoveAndRenameOperationContext( Registries registries )
{
- super( registries );
+ super( registries );
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveOperationContext.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveOperationContext.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveOperationContext.java Mon May 12 04:49:35 2008
@@ -41,7 +41,7 @@
*/
public MoveOperationContext( Registries registries )
{
- super( registries );
+ super( registries );
}
/**
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/RenameOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/RenameOperationContext.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/RenameOperationContext.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/RenameOperationContext.java Mon May 12 04:49:35 2008
@@ -48,7 +48,7 @@
*/
public RenameOperationContext( Registries registries )
{
- super( registries );
+ super( registries );
}
@@ -70,39 +70,39 @@
/**
* @return The delete old DN flag
*/
- public boolean getDelOldDn()
- {
- return delOldDn;
- }
+ public boolean getDelOldDn()
+ {
+ return delOldDn;
+ }
/**
- * Set the flag to delete the old DN
- * @param delOldDn the flag to set
- */
- public void setDelOldDn( boolean delOldDn )
- {
- this.delOldDn = delOldDn;
- }
+ * Set the flag to delete the old DN
+ * @param delOldDn the flag to set
+ */
+ public void setDelOldDn( boolean delOldDn )
+ {
+ this.delOldDn = delOldDn;
+ }
/**
- * @return The new RDN
- */
- public Rdn getNewRdn()
- {
- return newRdn;
- }
+ * @return The new RDN
+ */
+ public Rdn getNewRdn()
+ {
+ return newRdn;
+ }
/**
- * Set the new RDN
- * @param newRdn The new RDN
- */
- public void setNewRdn( Rdn newRdn )
- {
- this.newRdn = newRdn;
- }
+ * Set the new RDN
+ * @param newRdn The new RDN
+ */
+ public void setNewRdn( Rdn newRdn )
+ {
+ this.newRdn = newRdn;
+ }
/**
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/ReplaceOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/ReplaceOperationContext.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/ReplaceOperationContext.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/ReplaceOperationContext.java Mon May 12 04:49:35 2008
@@ -41,7 +41,7 @@
*/
public ReplaceOperationContext( Registries registries )
{
- super( registries );
+ super( registries );
}
/**
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/SearchOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/SearchOperationContext.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/SearchOperationContext.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/interceptor/context/SearchOperationContext.java Mon May 12 04:49:35 2008
@@ -52,7 +52,7 @@
*/
public SearchOperationContext( Registries registries )
{
- super( registries );
+ super( registries );
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/jndi/JavaLdapSupport.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/jndi/JavaLdapSupport.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/jndi/JavaLdapSupport.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/jndi/JavaLdapSupport.java Mon May 12 04:49:35 2008
@@ -173,10 +173,10 @@
* objectClass: javaSerializedObject
*/
entry.put( SchemaConstants.OBJECT_CLASS_AT,
- SchemaConstants.TOP_OC,
- JOBJECT_ATTR,
- JCONTAINER_ATTR,
- JSERIALIZEDOBJ_ATTR );
+ SchemaConstants.TOP_OC,
+ JOBJECT_ATTR,
+ JCONTAINER_ATTR,
+ JSERIALIZEDOBJ_ATTR );
// Add the javaClassName and javaSerializedData attributes
entry.put( JCLASSNAME_ATTR, obj.getClass().getName() );
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java Mon May 12 04:49:35 2008
@@ -366,21 +366,21 @@
}
else
{
- // Feed the contextEntry with the mandatory ObjectClass values, if they are missing.
- if ( !objectClassAttr.contains( SchemaConstants.TOP_OC ) )
- {
- objectClassAttr.add( SchemaConstants.TOP_OC );
- }
-
- if ( !objectClassAttr.contains( SchemaConstants.ORGANIZATIONAL_UNIT_OC ) )
- {
- objectClassAttr.add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
- }
-
- if ( !objectClassAttr.contains( SchemaConstants.EXTENSIBLE_OBJECT_OC ) )
- {
- objectClassAttr.add( SchemaConstants.EXTENSIBLE_OBJECT_OC );
- }
+ // Feed the contextEntry with the mandatory ObjectClass values, if they are missing.
+ if ( !objectClassAttr.contains( SchemaConstants.TOP_OC ) )
+ {
+ objectClassAttr.add( SchemaConstants.TOP_OC );
+ }
+
+ if ( !objectClassAttr.contains( SchemaConstants.ORGANIZATIONAL_UNIT_OC ) )
+ {
+ objectClassAttr.add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
+ }
+
+ if ( !objectClassAttr.contains( SchemaConstants.EXTENSIBLE_OBJECT_OC ) )
+ {
+ objectClassAttr.add( SchemaConstants.EXTENSIBLE_OBJECT_OC );
+ }
}
systemEntry.put( SchemaConstants.CREATORS_NAME_AT, ServerDNConstants.ADMIN_SYSTEM_DN );
@@ -649,35 +649,35 @@
synchronized ( partitionLookupTree )
{
- LdapDN partitionSuffix = partition.getSuffixDn();
-
- if ( partitionSuffix == null )
- {
- throw new ConfigurationException( "The current partition does not have any suffix: " + partition.getId() );
- }
-
+ LdapDN partitionSuffix = partition.getSuffixDn();
+
+ if ( partitionSuffix == null )
+ {
+ throw new ConfigurationException( "The current partition does not have any suffix: " + partition.getId() );
+ }
+
partitions.put( partitionSuffix.toString(), partition );
partitionLookupTree.recursivelyAddPartition( partitionLookupTree, partition.getSuffixDn(), 0, partition );
EntryAttribute namingContexts = rootDSE.get( SchemaConstants.NAMING_CONTEXTS_AT );
- LdapDN partitionUpSuffix = partition.getUpSuffixDn();
-
- if ( partitionUpSuffix == null )
- {
- throw new ConfigurationException( "The current partition does not have any user provided suffix: " + partition.getId() );
- }
-
- if ( namingContexts == null )
- {
- namingContexts = new DefaultServerAttribute(
- registries.getAttributeTypeRegistry().lookup( SchemaConstants.NAMING_CONTEXTS_AT ), partitionUpSuffix.getUpName() );
- rootDSE.put( namingContexts );
- }
- else
- {
- namingContexts.add( partitionUpSuffix.getUpName() );
- }
+ LdapDN partitionUpSuffix = partition.getUpSuffixDn();
+
+ if ( partitionUpSuffix == null )
+ {
+ throw new ConfigurationException( "The current partition does not have any user provided suffix: " + partition.getId() );
+ }
+
+ if ( namingContexts == null )
+ {
+ namingContexts = new DefaultServerAttribute(
+ registries.getAttributeTypeRegistry().lookup( SchemaConstants.NAMING_CONTEXTS_AT ), partitionUpSuffix.getUpName() );
+ rootDSE.put( namingContexts );
+ }
+ else
+ {
+ namingContexts.add( partitionUpSuffix.getUpName() );
+ }
}
}
@@ -904,7 +904,7 @@
// -----------------------------------------------------------
if ( ( ids == null ) || ( ids.length == 0 ) )
{
- ServerEntry rootDSE = (ServerEntry)getRootDSE( null ).clone();
+ ServerEntry rootDSE = (ServerEntry)getRootDSE( null ).clone();
ServerSearchResult result = new ServerSearchResult( LdapDN.EMPTY_LDAPDN, null, rootDSE, false );
return new SingletonEnumeration<ServerSearchResult>( result );
}
@@ -951,7 +951,7 @@
// return nothing
if ( containsOneDotOne )
{
- ServerEntry serverEntry = new DefaultServerEntry( registries, base );
+ ServerEntry serverEntry = new DefaultServerEntry( registries, base );
ServerSearchResult result = new ServerSearchResult( LdapDN.EMPTY_LDAPDN, null, serverEntry, false );
return new SingletonEnumeration<ServerSearchResult>( result );
}
@@ -959,7 +959,7 @@
// return everything
if ( containsAsterisk && containsPlus )
{
- ServerEntry rootDSE = (ServerEntry)getRootDSE( null ).clone();
+ ServerEntry rootDSE = (ServerEntry)getRootDSE( null ).clone();
ServerSearchResult result = new ServerSearchResult( LdapDN.EMPTY_LDAPDN, null, rootDSE, false );
return new SingletonEnumeration<ServerSearchResult>( result );
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/PartitionNexus.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/PartitionNexus.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/PartitionNexus.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/PartitionNexus.java Mon May 12 04:49:35 2008
@@ -84,15 +84,15 @@
try
{
- Map<String, OidNormalizer> oidsMap = new HashMap<String, OidNormalizer>();
-
- oidsMap.put( SchemaConstants.UID_AT, new OidNormalizer( SchemaConstants.UID_AT_OID, new NoOpNormalizer() ) );
- oidsMap.put( SchemaConstants.USER_ID_AT, new OidNormalizer( SchemaConstants.UID_AT_OID, new NoOpNormalizer() ) );
- oidsMap.put( SchemaConstants.UID_AT_OID, new OidNormalizer( SchemaConstants.UID_AT_OID, new NoOpNormalizer() ) );
-
- oidsMap.put( SchemaConstants.OU_AT, new OidNormalizer( SchemaConstants.OU_AT_OID, new NoOpNormalizer() ) );
- oidsMap.put( SchemaConstants.ORGANIZATIONAL_UNIT_NAME_AT, new OidNormalizer( SchemaConstants.OU_AT_OID, new NoOpNormalizer() ) );
- oidsMap.put( SchemaConstants.OU_AT_OID, new OidNormalizer( SchemaConstants.OU_AT_OID, new NoOpNormalizer() ) );
+ Map<String, OidNormalizer> oidsMap = new HashMap<String, OidNormalizer>();
+
+ oidsMap.put( SchemaConstants.UID_AT, new OidNormalizer( SchemaConstants.UID_AT_OID, new NoOpNormalizer() ) );
+ oidsMap.put( SchemaConstants.USER_ID_AT, new OidNormalizer( SchemaConstants.UID_AT_OID, new NoOpNormalizer() ) );
+ oidsMap.put( SchemaConstants.UID_AT_OID, new OidNormalizer( SchemaConstants.UID_AT_OID, new NoOpNormalizer() ) );
+
+ oidsMap.put( SchemaConstants.OU_AT, new OidNormalizer( SchemaConstants.OU_AT_OID, new NoOpNormalizer() ) );
+ oidsMap.put( SchemaConstants.ORGANIZATIONAL_UNIT_NAME_AT, new OidNormalizer( SchemaConstants.OU_AT_OID, new NoOpNormalizer() ) );
+ oidsMap.put( SchemaConstants.OU_AT_OID, new OidNormalizer( SchemaConstants.OU_AT_OID, new NoOpNormalizer() ) );
adminDn.normalize( oidsMap );
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreePartition.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreePartition.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreePartition.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreePartition.java Mon May 12 04:49:35 2008
@@ -234,8 +234,8 @@
public void delete( DeleteOperationContext opContext ) throws NamingException
{
- LdapDN dn = opContext.getDn();
-
+ LdapDN dn = opContext.getDn();
+
Long id = getEntryId( dn.getNormName() );
// don't continue if id is null
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreeSearchResultEnumeration.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreeSearchResultEnumeration.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreeSearchResultEnumeration.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreeSearchResultEnumeration.java Mon May 12 04:49:35 2008
@@ -113,7 +113,7 @@
if ( null == entry )
{
- entry = partition.lookup( (Long)rec.getEntryId() );
+ entry = partition.lookup( (Long)rec.getEntryId() );
rec.setEntry( entry );
entry = (ServerEntry)entry.clone();
}
@@ -140,9 +140,9 @@
continue;
}
- ServerAttribute attr = ( ServerAttribute ) rec.getEntry().get( attrId ).clone();
+ ServerAttribute attr = ( ServerAttribute ) rec.getEntry().get( attrId ).clone();
- entry.put( attr );
+ entry.put( attr );
}
// add all operational attributes
@@ -155,7 +155,7 @@
continue;
}
- ServerAttribute attr = (ServerAttribute)attribute.clone();
+ ServerAttribute attr = (ServerAttribute)attribute.clone();
entry.put( attr );
}
}
@@ -177,7 +177,7 @@
}
// clone attribute to stuff into the new resultant entry
- ServerAttribute attr = ( ServerAttribute ) rec.getEntry().get( attrId ).clone();
+ ServerAttribute attr = ( ServerAttribute ) rec.getEntry().get( attrId ).clone();
entry.put( attr );
}
@@ -188,19 +188,19 @@
if ( attrType.getUsage() == UsageEnum.USER_APPLICATIONS )
{
- ServerAttribute attr = ( ServerAttribute ) rec.getEntry().get( attrType ).clone();
+ ServerAttribute attr = ( ServerAttribute ) rec.getEntry().get( attrType ).clone();
entry.put( attr );
}
}
}
else
{
- Set<EntryAttribute> entryAttrs = new HashSet<EntryAttribute>();
-
- for ( EntryAttribute entryAttribute:entry )
- {
- entryAttrs.add( entryAttribute );
- }
+ Set<EntryAttribute> entryAttrs = new HashSet<EntryAttribute>();
+
+ for ( EntryAttribute entryAttribute:entry )
+ {
+ entryAttrs.add( entryAttribute );
+ }
//entry = new DefaultServerEntry( registries, dn );
//ServerEntry attrs = rec.getEntry();
@@ -231,7 +231,7 @@
// we may have more than one descendant, like sn and cn
// for name, so add all of them
//entry.put( (ServerAttribute)attr.clone() );
- entryAttrs.remove( attr );
+ entryAttrs.remove( attr );
}
}
}
@@ -239,13 +239,13 @@
{
// clone attribute to stuff into the new resultant entry
//entry.put( (ServerAttribute)attr.clone() );
- entryAttrs.remove( attr );
+ entryAttrs.remove( attr );
}
}
for ( EntryAttribute entryAttribute:entryAttrs )
{
- entry.remove( entryAttribute );
+ entry.remove( entryAttribute );
}
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/DefaultOptimizer.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/DefaultOptimizer.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/DefaultOptimizer.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/DefaultOptimizer.java Mon May 12 04:49:35 2008
@@ -150,19 +150,19 @@
{
if ( node instanceof AndNode )
{
- count = getConjunctionScan( (AndNode)node );
+ count = getConjunctionScan( (AndNode)node );
}
else if ( node instanceof OrNode )
{
- count = getDisjunctionScan( (OrNode)node );
+ count = getDisjunctionScan( (OrNode)node );
}
else if ( node instanceof NotNode )
{
- count = getNegationScan( (NotNode)node );
+ count = getNegationScan( (NotNode)node );
}
else
{
- throw new IllegalArgumentException( "Unrecognized branch node type" );
+ throw new IllegalArgumentException( "Unrecognized branch node type" );
}
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/ExpressionEnumerator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/ExpressionEnumerator.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/ExpressionEnumerator.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/ExpressionEnumerator.java Mon May 12 04:49:35 2008
@@ -91,7 +91,7 @@
*/
public NamingEnumeration<IndexRecord> enumerate( ExprNode node ) throws NamingException
{
- NamingEnumeration<IndexRecord> list = null;
+ NamingEnumeration<IndexRecord> list = null;
if ( node instanceof ScopeNode )
{
@@ -192,8 +192,8 @@
*/
private NamingEnumeration<IndexRecord> enumNeg( final BranchNode node ) throws NamingException
{
- NamingEnumeration<IndexRecord> baseEnumeration = null;
- NamingEnumeration<IndexRecord> enumeration = null;
+ NamingEnumeration<IndexRecord> baseEnumeration = null;
+ NamingEnumeration<IndexRecord> enumeration = null;
baseEnumeration = db.getNdnIndex().listIndices();
@@ -349,8 +349,8 @@
*/
private NamingEnumeration<IndexRecord> nonIndexedScan( final LeafNode node ) throws NamingException
{
- NamingEnumeration<IndexRecord> underlying = db.getNdnIndex().listIndices();
-
+ NamingEnumeration<IndexRecord> underlying = db.getNdnIndex().listIndices();
+
IndexAssertion assertion = new IndexAssertion()
{
public boolean assertCandidate( IndexRecord record ) throws NamingException
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/LeafEvaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/LeafEvaluator.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/LeafEvaluator.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/LeafEvaluator.java Mon May 12 04:49:35 2008
@@ -159,7 +159,7 @@
private ServerEntry getEntry( IndexRecord rec ) throws NamingException
{
// get the attributes associated with the entry
- ServerEntry entry = rec.getEntry();
+ ServerEntry entry = rec.getEntry();
// resuscitate entry if need be
// TODO Is this really needed ?
@@ -265,7 +265,7 @@
// get the attribute associated with the node
EntryAttribute attr = record.getEntry().get(
- registries.getAttributeTypeRegistry().lookup( node.getAttribute() ) );
+ registries.getAttributeTypeRegistry().lookup( node.getAttribute() ) );
// If we do not have the attribute just return false
if ( null == attr )
@@ -300,7 +300,7 @@
}
else
{
- for ( Value<?> value:attr )
+ for ( Value<?> value:attr )
{
Object normValue = normalizer.normalize( value );
@@ -358,7 +358,7 @@
// Now, get the AttributeType associated with the Attribute id
AttributeType type = registries.getAttributeTypeRegistry().lookup(
- registries.getOidRegistry().getOid( attrId ) );
+ registries.getOidRegistry().getOid( attrId ) );
// here, we may have some descendants if the attribute is not found
if ( entry.get( type ) != null )
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/SubstringEvaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/SubstringEvaluator.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/SubstringEvaluator.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/SubstringEvaluator.java Mon May 12 04:49:35 2008
@@ -138,7 +138,7 @@
// resuscitate the entry if it has not been and set entry in IndexRecord
if ( null == entry )
{
- ServerEntry attrs = db.lookup( (Long)record.getEntryId() );
+ ServerEntry attrs = db.lookup( (Long)record.getEntryId() );
record.setEntry( attrs );
entry = record.getEntry();
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/AddEntryDialog.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/AddEntryDialog.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/AddEntryDialog.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/AddEntryDialog.java Mon May 12 04:49:35 2008
@@ -208,7 +208,10 @@
public Object getCellEditorValue()
{
if ( log.isDebugEnabled() )
+ {
log.debug( "Editor returning '" + l_textField.getText() + "'" );
+ }
+
return l_textField.getText();
}
};
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/IndexDialog.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/IndexDialog.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/IndexDialog.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/IndexDialog.java Mon May 12 04:49:35 2008
@@ -309,8 +309,7 @@
{
String prefix = key.substring( 0, starIndex );
- if ( log.isDebugEnabled() )
- log.debug( "Regex prefix = " + prefix );
+ log.debug( "Regex prefix = {}", prefix );
list = index.listIndices( regex, prefix );
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/PartitionFrame.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/PartitionFrame.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/PartitionFrame.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/gui/PartitionFrame.java Mon May 12 04:49:35 2008
@@ -310,8 +310,7 @@
{
public void actionPerformed( ActionEvent an_event )
{
- if ( LOG.isDebugEnabled() )
- LOG.debug( "action command = " + an_event.getActionCommand() );
+ LOG.debug( "action command = {}", an_event.getActionCommand() );
try
{
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/ObjectClassImpl.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/ObjectClassImpl.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/ObjectClassImpl.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/ObjectClassImpl.java Mon May 12 04:49:35 2008
@@ -205,19 +205,19 @@
public boolean isStructural()
{
- return objectClassType == ObjectClassTypeEnum.STRUCTURAL;
+ return objectClassType == ObjectClassTypeEnum.STRUCTURAL;
}
public boolean isAbstract()
{
- return objectClassType == ObjectClassTypeEnum.ABSTRACT;
+ return objectClassType == ObjectClassTypeEnum.ABSTRACT;
}
public boolean isAuxiliary()
{
- return objectClassType == ObjectClassTypeEnum.AUXILIARY;
+ return objectClassType == ObjectClassTypeEnum.AUXILIARY;
}
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/PartitionSchemaLoader.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/PartitionSchemaLoader.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/PartitionSchemaLoader.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/PartitionSchemaLoader.java Mon May 12 04:49:35 2008
@@ -429,7 +429,7 @@
while ( list.hasMore() )
{
- ServerSearchResult result = list.next();
+ ServerSearchResult result = list.next();
LdapDN resultDN = result.getDn();
resultDN.normalize( atRegistry.getNormalizerMapping() );
ServerEntry attrs = lookupPartition( resultDN );
@@ -530,7 +530,7 @@
while ( list.hasMore() )
{
- ServerSearchResult result = list.next();
+ ServerSearchResult result = list.next();
LdapDN resultDN = result.getDn();
resultDN.normalize( atRegistry.getNormalizerMapping() );
ServerEntry attrs = lookupPartition( resultDN );
@@ -628,7 +628,7 @@
while ( list.hasMore() )
{
- ServerSearchResult result = list.next();
+ ServerSearchResult result = list.next();
LdapDN resultDN = result.getDn();
resultDN.normalize( atRegistry.getNormalizerMapping() );
ServerEntry attrs = lookupPartition( resultDN );
@@ -661,7 +661,7 @@
while ( list.hasMore() )
{
- ServerSearchResult result = list.next();
+ ServerSearchResult result = list.next();
LdapDN resultDN = result.getDn();
resultDN.normalize( atRegistry.getNormalizerMapping() );
ServerEntry attrs = lookupPartition( resultDN );
@@ -693,7 +693,7 @@
while ( list.hasMore() )
{
- ServerSearchResult result = list.next();
+ ServerSearchResult result = list.next();
LdapDN resultDN = result.getDn();
resultDN.normalize( atRegistry.getNormalizerMapping() );
ServerEntry attrs = lookupPartition( resultDN );
@@ -727,7 +727,7 @@
while ( list.hasMore() )
{
- ServerSearchResult result = list.next();
+ ServerSearchResult result = list.next();
LdapDN resultDN = result.getDn();
resultDN.normalize( atRegistry.getNormalizerMapping() );
ServerEntry attrs = lookupPartition( resultDN );
@@ -805,7 +805,7 @@
while ( list.hasMore() )
{
- ServerSearchResult result = list.next();
+ ServerSearchResult result = list.next();
LdapDN resultDN = result.getDn();
resultDN.normalize( atRegistry.getNormalizerMapping() );
ServerEntry attrs = lookupPartition( resultDN );
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/RefinementEvaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/RefinementEvaluator.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/RefinementEvaluator.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/RefinementEvaluator.java Mon May 12 04:49:35 2008
@@ -102,7 +102,7 @@
}
return true;
-
+
}
else if ( node instanceof NotNode )
{
@@ -112,7 +112,7 @@
}
throw new IllegalArgumentException( "Negation has no child: " + node );
-
+
}
else
{
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/ModifyDNStoredProcedureParameterInjector.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/ModifyDNStoredProcedureParameterInjector.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/ModifyDNStoredProcedureParameterInjector.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/ModifyDNStoredProcedureParameterInjector.java Mon May 12 04:49:35 2008
@@ -40,32 +40,32 @@
private LdapDN oldDN;
private LdapDN newDN;
- public ModifyDNStoredProcedureParameterInjector( Invocation invocation, boolean deleteOldRn,
+ public ModifyDNStoredProcedureParameterInjector( Invocation invocation, boolean deleteOldRn,
LdapDN oldRDN, Rdn newRDN, LdapDN oldSuperiorDN, LdapDN newSuperiorDN, LdapDN oldDN, LdapDN newDN)
{
super( invocation );
this.deleteOldRn = deleteOldRn;
- this.oldRDN = oldRDN;
- this.newRDN = newRDN;
- this.oldSuperiorDN = oldSuperiorDN;
- this.newSuperiorDN = newSuperiorDN;
- this.oldDN = oldDN;
- this.newDN = newDN;
-
- Map<Class<?>, MicroInjector> injectors = super.getInjectors();
- injectors.put( StoredProcedureParameter.ModifyDN_ENTRY.class, $entryInjector );
- injectors.put( StoredProcedureParameter.ModifyDN_NEW_RDN.class, $newrdnInjector );
- injectors.put( StoredProcedureParameter.ModifyDN_DELETE_OLD_RDN.class, $deleteoldrdnInjector );
- injectors.put( StoredProcedureParameter.ModifyDN_NEW_SUPERIOR.class, $newSuperiorInjector );
- injectors.put( StoredProcedureParameter.ModifyDN_OLD_RDN.class, $oldRDNInjector );
- injectors.put( StoredProcedureParameter.ModifyDN_OLD_SUPERIOR_DN.class, $oldSuperiorDNInjector );
- injectors.put( StoredProcedureParameter.ModifyDN_NEW_DN.class, $newDNInjector );
-
+ this.oldRDN = oldRDN;
+ this.newRDN = newRDN;
+ this.oldSuperiorDN = oldSuperiorDN;
+ this.newSuperiorDN = newSuperiorDN;
+ this.oldDN = oldDN;
+ this.newDN = newDN;
+
+ Map<Class<?>, MicroInjector> injectors = super.getInjectors();
+ injectors.put( StoredProcedureParameter.ModifyDN_ENTRY.class, $entryInjector );
+ injectors.put( StoredProcedureParameter.ModifyDN_NEW_RDN.class, $newrdnInjector );
+ injectors.put( StoredProcedureParameter.ModifyDN_DELETE_OLD_RDN.class, $deleteoldrdnInjector );
+ injectors.put( StoredProcedureParameter.ModifyDN_NEW_SUPERIOR.class, $newSuperiorInjector );
+ injectors.put( StoredProcedureParameter.ModifyDN_OLD_RDN.class, $oldRDNInjector );
+ injectors.put( StoredProcedureParameter.ModifyDN_OLD_SUPERIOR_DN.class, $oldSuperiorDNInjector );
+ injectors.put( StoredProcedureParameter.ModifyDN_NEW_DN.class, $newDNInjector );
+
}
- /**
- * Injector for 'entry' parameter of ModifyDNRequest as in RFC4511.
- */
- MicroInjector $entryInjector = new MicroInjector()
+ /**
+ * Injector for 'entry' parameter of ModifyDNRequest as in RFC4511.
+ */
+ MicroInjector $entryInjector = new MicroInjector()
{
public Object inject( Registries registries, StoredProcedureParameter param ) throws NamingException
{
Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/TriggerInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/TriggerInterceptor.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/TriggerInterceptor.java (original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/trigger/TriggerInterceptor.java Mon May 12 04:49:35 2008
@@ -261,9 +261,9 @@
public void add( NextInterceptor next, AddOperationContext addContext ) throws NamingException
{
- LdapDN name = addContext.getDn();
- ServerEntry entry = addContext.getEntry();
-
+ LdapDN name = addContext.getDn();
+ ServerEntry entry = addContext.getEntry();
+
// Bypass trigger handling if the service is disabled.
if ( !enabled )
{
@@ -297,8 +297,8 @@
public void delete( NextInterceptor next, DeleteOperationContext deleteContext ) throws NamingException
{
- LdapDN name = deleteContext.getDn();
-
+ LdapDN name = deleteContext.getDn();
+
// Bypass trigger handling if the service is disabled.
if ( !enabled )
{
@@ -592,16 +592,16 @@
private Object executeTrigger( TriggerSpecification tsec, StoredProcedureParameterInjector injector, ServerLdapContext callerRootCtx ) throws NamingException
{
- List<Object> returnValues = new ArrayList<Object>();
- List<SPSpec> spSpecs = tsec.getSPSpecs();
+ List<Object> returnValues = new ArrayList<Object>();
+ List<SPSpec> spSpecs = tsec.getSPSpecs();
for ( SPSpec spSpec : spSpecs )
{
- List<Object> arguments = new ArrayList<Object>();
- arguments.addAll( injector.getArgumentsToInject( registries, spSpec.getParameters() ) );
+ List<Object> arguments = new ArrayList<Object>();
+ arguments.addAll( injector.getArgumentsToInject( registries, spSpec.getParameters() ) );
Object[] values = arguments.toArray();
Object returnValue = executeProcedure( callerRootCtx, spSpec.getName(), values );
returnValues.add( returnValue );
- }
+ }
return returnValues;
}
Modified: directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilterTest.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilterTest.java (original)
+++ directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilterTest.java Mon May 12 04:49:35 2008
@@ -53,19 +53,19 @@
private static final Collection<String> EMPTY_STRING_COLLECTION = Collections.unmodifiableCollection( new ArrayList<String>() );
private static final Collection<Attribute> EMPTY_ATTRIBUTE_COLLECTION =
- Collections.unmodifiableCollection( new ArrayList<Attribute>() );
+ Collections.unmodifiableCollection( new ArrayList<Attribute>() );
private static final Collection<UserClass> EMPTY_USER_CLASS_COLLECTION =
- Collections.unmodifiableCollection( new ArrayList<UserClass>() );
+ Collections.unmodifiableCollection( new ArrayList<UserClass>() );
private static final Collection<ACITuple> EMPTY_ACI_TUPLE_COLLECTION =
- Collections.unmodifiableCollection( new ArrayList<ACITuple>() );
+ Collections.unmodifiableCollection( new ArrayList<ACITuple>() );
private static final Collection<ProtectedItem> EMPTY_PROTECTED_ITEM_COLLECTION =
- Collections.unmodifiableCollection( new ArrayList<ProtectedItem>() );
+ Collections.unmodifiableCollection( new ArrayList<ProtectedItem>() );
private static final Set<MicroOperation> EMPTY_MICRO_OPERATION_SET =
- Collections.unmodifiableSet( new HashSet<MicroOperation>() );
+ Collections.unmodifiableSet( new HashSet<MicroOperation>() );
private static final List<ACITuple> TUPLES_A = new ArrayList<ACITuple>();
private static final List<ACITuple> TUPLES_B = new ArrayList<ACITuple>();
@@ -98,13 +98,13 @@
allAttributeValues, EMPTY_MICRO_OPERATION_SET, true, 0 );
ACITuple selfValueTuple = new ACITuple( EMPTY_USER_CLASS_COLLECTION, AuthenticationLevel.NONE, selfValue,
- EMPTY_MICRO_OPERATION_SET, true, 0 );
+ EMPTY_MICRO_OPERATION_SET, true, 0 );
ACITuple attributeValueTuple = new ACITuple( EMPTY_USER_CLASS_COLLECTION, AuthenticationLevel.NONE, attributeValue,
- EMPTY_MICRO_OPERATION_SET, true, 0 );
+ EMPTY_MICRO_OPERATION_SET, true, 0 );
ACITuple rangeOfValuesTuple = new ACITuple( EMPTY_USER_CLASS_COLLECTION, AuthenticationLevel.NONE, rangeOfValues,
- EMPTY_MICRO_OPERATION_SET, true, 0 );
+ EMPTY_MICRO_OPERATION_SET, true, 0 );
ACITuple allUserAttributeTypesTuple = new ACITuple( EMPTY_USER_CLASS_COLLECTION, AuthenticationLevel.NONE,
allUserAttributeTypes, EMPTY_MICRO_OPERATION_SET, true, 0 );
Modified: directory/apacheds/trunk/interceptor-kerberos/src/main/java/org/apache/directory/server/core/kerberos/PasswordPolicyInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/interceptor-kerberos/src/main/java/org/apache/directory/server/core/kerberos/PasswordPolicyInterceptor.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/interceptor-kerberos/src/main/java/org/apache/directory/server/core/kerberos/PasswordPolicyInterceptor.java (original)
+++ directory/apacheds/trunk/interceptor-kerberos/src/main/java/org/apache/directory/server/core/kerberos/PasswordPolicyInterceptor.java Mon May 12 04:49:35 2008
@@ -122,20 +122,20 @@
{
if ( log.isDebugEnabled() )
{
- switch ( mod.getOperation() )
- {
- case ADD_ATTRIBUTE:
- operation = "Adding";
- break;
-
- case REMOVE_ATTRIBUTE:
- operation = "Removing";
- break;
-
- case REPLACE_ATTRIBUTE:
- operation = "Replacing";
- break;
- }
+ switch ( mod.getOperation() )
+ {
+ case ADD_ATTRIBUTE:
+ operation = "Adding";
+ break;
+
+ case REMOVE_ATTRIBUTE:
+ operation = "Removing";
+ break;
+
+ case REPLACE_ATTRIBUTE:
+ operation = "Replacing";
+ break;
+ }
}
ServerAttribute attr = (ServerAttribute)mod.getAttribute();
@@ -182,7 +182,7 @@
if ( log.isDebugEnabled() )
{
- log.debug( operation + " for entry '" + name.getUpName() + "' the attribute " + mod.getAttribute() );
+ log.debug( operation + " for entry '" + name.getUpName() + "' the attribute " + mod.getAttribute() );
}
}
Modified: directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/messages/value/flags/TicketFlags.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/messages/value/flags/TicketFlags.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/messages/value/flags/TicketFlags.java (original)
+++ directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/messages/value/flags/TicketFlags.java Mon May 12 04:49:35 2008
@@ -29,7 +29,7 @@
*/
public class TicketFlags extends AbstractKerberosFlags
{
- public static final long serialVersionUID = 1L;
+ private static final long serialVersionUID = 1L;
/**
Modified: directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/configuration/ReplicationConfiguration.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/configuration/ReplicationConfiguration.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/configuration/ReplicationConfiguration.java (original)
+++ directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/configuration/ReplicationConfiguration.java Mon May 12 04:49:35 2008
@@ -141,8 +141,8 @@
* @return <tt>0</tt> if automatic replication is disabled
*/
public int getReplicationInterval() {
- return replicationInterval;
- }
+ return replicationInterval;
+ }
/**
Modified: directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationInterceptor.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationInterceptor.java (original)
+++ directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationInterceptor.java Mon May 12 04:49:35 2008
@@ -357,7 +357,7 @@
{
while ( e.hasMore() )
{
- ServerSearchResult sr = e.next();
+ ServerSearchResult sr = e.next();
LdapDN name = sr.getDn();
if ( name.size() > contextName.size() )
@@ -498,11 +498,11 @@
@Override
public NamingEnumeration<ServerSearchResult> list( NextInterceptor nextInterceptor, ListOperationContext opContext ) throws NamingException
{
- NamingEnumeration<ServerSearchResult> result = nextInterceptor.search(
- new SearchOperationContext(
- registries, opContext.getDn(), opContext.getAliasDerefMode(),
- new PresenceNode( SchemaConstants.OBJECT_CLASS_AT_OID ),
- new SearchControls() ) );
+ NamingEnumeration<ServerSearchResult> result = nextInterceptor.search(
+ new SearchOperationContext(
+ registries, opContext.getDn(), opContext.getAliasDerefMode(),
+ new PresenceNode( SchemaConstants.OBJECT_CLASS_AT_OID ),
+ new SearchControls() ) );
return new SearchResultFilteringEnumeration( result, new SearchControls(), InvocationStack.getInstance().peek(),
Constants.DELETED_ENTRIES_FILTER, "List replication filter" );
@@ -523,7 +523,7 @@
searchControls.setReturningAttributes( newAttrIds );
}
- NamingEnumeration<ServerSearchResult> result = nextInterceptor.search(
+ NamingEnumeration<ServerSearchResult> result = nextInterceptor.search(
new SearchOperationContext( registries, opContext.getDn(), opContext.getAliasDerefMode(), opContext.getFilter(), searchControls ) );
return new SearchResultFilteringEnumeration( result, searchControls, InvocationStack.getInstance().peek(),
Constants.DELETED_ENTRIES_FILTER, "Search Replication filter" );
Modified: directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationProtocolHandler.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationProtocolHandler.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationProtocolHandler.java (original)
+++ directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationProtocolHandler.java Mon May 12 04:49:35 2008
@@ -64,7 +64,7 @@
}
public ReplicationContextHandler getContextHandler() {
- return contextHandler;
+ return contextHandler;
}
Modified: directory/apacheds/trunk/protocol-dhcp/src/main/java/org/apache/directory/server/dhcp/messages/DhcpMessage.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/protocol-dhcp/src/main/java/org/apache/directory/server/dhcp/messages/DhcpMessage.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/protocol-dhcp/src/main/java/org/apache/directory/server/dhcp/messages/DhcpMessage.java (original)
+++ directory/apacheds/trunk/protocol-dhcp/src/main/java/org/apache/directory/server/dhcp/messages/DhcpMessage.java Mon May 12 04:49:35 2008
@@ -32,265 +32,265 @@
* @version $Rev$, $Date$
*/
public class DhcpMessage {
- /**
- * Flag value: request broadcast answer.
- */
- public static final int FLAG_BROADCAST = 0x01;
-
- /**
- * [yiaddr] 'your' (client) IP address.
- */
- private InetAddress assignedClientAddress;
-
- /**
- * [file] Boot file name, null terminated string; "generic" name or null in
- * DHCPDISCOVER, fully qualified directory-path name in DHCPOFFER.
- */
- private String bootFileName;
-
- /**
- * [ciaddr] Current client IP address; only filled in if client is in BOUND,
- * RENEW or REBINDING state and can respond to ARP requests.
- */
- private InetAddress currentClientAddress;
-
- /**
- * [flags] Flags. (LSB is broadcast flag)
- */
- private short flags;
-
- /**
- * [hops] Client sets to zero, optionally used by relay agents when booting
- * via a relay agent.
- */
- private short hopCount;
-
- /**
- * [op] Message op code. 1 = BOOTREQUEST, 2 = BOOTREPLY, ...
- */
- private byte op;
-
- /**
- * Operation constant: boot request (client to server).
- *
- * @see #op
- */
- public static final byte OP_BOOTREQUEST = 1;
-
- /**
- * Operation constant: boot reply (server to client).
- *
- * @see #op
- */
- public static final byte OP_BOOTREPLY = 2;
-
- /**
- * [siaddr] IP address of next server to use in bootstrap; returned in
- * DHCPOFFER, DHCPACK by server.
- */
- private InetAddress nextServerAddress;
-
- /**
- * [options] Optional parameters field. See the options documents for a list
- * of defined options.
- */
- private OptionsField options = new OptionsField();
-
- /**
- * [giaddr] Relay agent IP address, used in booting via a relay agent.
- */
- private InetAddress relayAgentAddress;
-
- /**
- * [secs] Filled in by client, seconds elapsed since client began address
- * acquisition or renewal process.
- */
- private int seconds;
-
- /**
- * [sname] Optional server host name, null terminated string.
- */
- private String serverHostname;
-
- /**
- * [xid] Transaction ID, a random number chosen by the client, used by the
- * client and server to associate messages and responses between a client and
- * a server.
- */
- private int transactionId;
-
- /**
- * The DHCP message type option.
- */
- private MessageType messageType;
-
- private HardwareAddress hardwareAddress;
-
- /**
- * Create a default dhcp message.
- */
- public DhcpMessage() {
-
- }
-
- /**
- * Create a DHCP message based on the supplied values.
- *
- * @param messageType
- * @param op
- * @param hardwareAddress
- * @param hops
- * @param transactionId
- * @param seconds
- * @param flags
- * @param currentClientAddress
- * @param assignedClientAddress
- * @param nextServerAddress
- * @param relayAgentAddress
- * @param serverHostname
- * @param bootFileName
- * @param options
- */
- public DhcpMessage(MessageType messageType, byte op,
- HardwareAddress hardwareAddress, short hops, int transactionId,
- int seconds, short flags, InetAddress currentClientAddress,
- InetAddress assignedClientAddress, InetAddress nextServerAddress,
- InetAddress relayAgentAddress, String serverHostname,
- String bootFileName, OptionsField options) {
- this.messageType = messageType;
- this.op = op;
- this.hardwareAddress = hardwareAddress;
- this.hopCount = hops;
- this.transactionId = transactionId;
- this.seconds = seconds;
- this.flags = flags;
- this.currentClientAddress = currentClientAddress;
- this.assignedClientAddress = assignedClientAddress;
- this.nextServerAddress = nextServerAddress;
- this.relayAgentAddress = relayAgentAddress;
- this.serverHostname = serverHostname;
- this.bootFileName = bootFileName;
- this.options = options;
- }
-
- public InetAddress getAssignedClientAddress() {
- return assignedClientAddress;
- }
-
- public String getBootFileName() {
- return bootFileName;
- }
-
- public InetAddress getCurrentClientAddress() {
- return currentClientAddress;
- }
-
- public short getFlags() {
- return flags;
- }
-
- public short getHopCount() {
- return hopCount;
- }
-
- public MessageType getMessageType() {
- return messageType;
- }
-
- public InetAddress getNextServerAddress() {
- return nextServerAddress;
- }
-
- public OptionsField getOptions() {
- return options;
- }
-
- public InetAddress getRelayAgentAddress() {
- return relayAgentAddress;
- }
-
- public int getSeconds() {
- return seconds;
- }
-
- public String getServerHostname() {
- return serverHostname;
- }
-
- public int getTransactionId() {
- return transactionId;
- }
-
- public void setAssignedClientAddress(InetAddress assignedClientAddress) {
- this.assignedClientAddress = assignedClientAddress;
- }
-
- public void setBootFileName(String bootFileName) {
- this.bootFileName = bootFileName;
- }
-
- public void setCurrentClientAddress(InetAddress currentClientAddress) {
- this.currentClientAddress = currentClientAddress;
- }
-
- public void setFlags(short flags) {
- this.flags = flags;
- }
-
- public void setHopCount(short hopCount) {
- this.hopCount = hopCount;
- }
-
- public void setMessageType(MessageType messageType) {
- this.messageType = messageType;
- }
-
- public void setNextServerAddress(InetAddress nextServerAddress) {
- this.nextServerAddress = nextServerAddress;
- }
-
- public void setOptions(OptionsField options) {
- this.options = options;
- }
-
- public void setRelayAgentAddress(InetAddress relayAgentAddress) {
- this.relayAgentAddress = relayAgentAddress;
- }
-
- public void setSeconds(int seconds) {
- this.seconds = seconds;
- }
-
- public void setServerHostname(String serverHostname) {
- this.serverHostname = serverHostname;
- }
-
- public void setTransactionId(int transactionId) {
- this.transactionId = transactionId;
- }
-
- public byte getOp() {
- return op;
- }
-
- public void setOp(byte op) {
- this.op = op;
- }
-
- public HardwareAddress getHardwareAddress() {
- return hardwareAddress;
- }
-
- public void setHardwareAddress(HardwareAddress hardwareAddress) {
- this.hardwareAddress = hardwareAddress;
- }
-
- public String toString() {
- StringBuilder sb = new StringBuilder();
- sb.append(messageType).append(": hwAddress=").append(hardwareAddress)
- .append(", tx=").append(transactionId).append(", options=").append(
- options);
+ /**
+ * Flag value: request broadcast answer.
+ */
+ public static final int FLAG_BROADCAST = 0x01;
+
+ /**
+ * [yiaddr] 'your' (client) IP address.
+ */
+ private InetAddress assignedClientAddress;
+
+ /**
+ * [file] Boot file name, null terminated string; "generic" name or null in
+ * DHCPDISCOVER, fully qualified directory-path name in DHCPOFFER.
+ */
+ private String bootFileName;
+
+ /**
+ * [ciaddr] Current client IP address; only filled in if client is in BOUND,
+ * RENEW or REBINDING state and can respond to ARP requests.
+ */
+ private InetAddress currentClientAddress;
+
+ /**
+ * [flags] Flags. (LSB is broadcast flag)
+ */
+ private short flags;
+
+ /**
+ * [hops] Client sets to zero, optionally used by relay agents when booting
+ * via a relay agent.
+ */
+ private short hopCount;
+
+ /**
+ * [op] Message op code. 1 = BOOTREQUEST, 2 = BOOTREPLY, ...
+ */
+ private byte op;
+
+ /**
+ * Operation constant: boot request (client to server).
+ *
+ * @see #op
+ */
+ public static final byte OP_BOOTREQUEST = 1;
+
+ /**
+ * Operation constant: boot reply (server to client).
+ *
+ * @see #op
+ */
+ public static final byte OP_BOOTREPLY = 2;
+
+ /**
+ * [siaddr] IP address of next server to use in bootstrap; returned in
+ * DHCPOFFER, DHCPACK by server.
+ */
+ private InetAddress nextServerAddress;
+
+ /**
+ * [options] Optional parameters field. See the options documents for a list
+ * of defined options.
+ */
+ private OptionsField options = new OptionsField();
+
+ /**
+ * [giaddr] Relay agent IP address, used in booting via a relay agent.
+ */
+ private InetAddress relayAgentAddress;
+
+ /**
+ * [secs] Filled in by client, seconds elapsed since client began address
+ * acquisition or renewal process.
+ */
+ private int seconds;
+
+ /**
+ * [sname] Optional server host name, null terminated string.
+ */
+ private String serverHostname;
+
+ /**
+ * [xid] Transaction ID, a random number chosen by the client, used by the
+ * client and server to associate messages and responses between a client and
+ * a server.
+ */
+ private int transactionId;
+
+ /**
+ * The DHCP message type option.
+ */
+ private MessageType messageType;
+
+ private HardwareAddress hardwareAddress;
+
+ /**
+ * Create a default dhcp message.
+ */
+ public DhcpMessage() {
+
+ }
+
+ /**
+ * Create a DHCP message based on the supplied values.
+ *
+ * @param messageType
+ * @param op
+ * @param hardwareAddress
+ * @param hops
+ * @param transactionId
+ * @param seconds
+ * @param flags
+ * @param currentClientAddress
+ * @param assignedClientAddress
+ * @param nextServerAddress
+ * @param relayAgentAddress
+ * @param serverHostname
+ * @param bootFileName
+ * @param options
+ */
+ public DhcpMessage(MessageType messageType, byte op,
+ HardwareAddress hardwareAddress, short hops, int transactionId,
+ int seconds, short flags, InetAddress currentClientAddress,
+ InetAddress assignedClientAddress, InetAddress nextServerAddress,
+ InetAddress relayAgentAddress, String serverHostname,
+ String bootFileName, OptionsField options) {
+ this.messageType = messageType;
+ this.op = op;
+ this.hardwareAddress = hardwareAddress;
+ this.hopCount = hops;
+ this.transactionId = transactionId;
+ this.seconds = seconds;
+ this.flags = flags;
+ this.currentClientAddress = currentClientAddress;
+ this.assignedClientAddress = assignedClientAddress;
+ this.nextServerAddress = nextServerAddress;
+ this.relayAgentAddress = relayAgentAddress;
+ this.serverHostname = serverHostname;
+ this.bootFileName = bootFileName;
+ this.options = options;
+ }
+
+ public InetAddress getAssignedClientAddress() {
+ return assignedClientAddress;
+ }
+
+ public String getBootFileName() {
+ return bootFileName;
+ }
+
+ public InetAddress getCurrentClientAddress() {
+ return currentClientAddress;
+ }
+
+ public short getFlags() {
+ return flags;
+ }
+
+ public short getHopCount() {
+ return hopCount;
+ }
+
+ public MessageType getMessageType() {
+ return messageType;
+ }
+
+ public InetAddress getNextServerAddress() {
+ return nextServerAddress;
+ }
+
+ public OptionsField getOptions() {
+ return options;
+ }
+
+ public InetAddress getRelayAgentAddress() {
+ return relayAgentAddress;
+ }
+
+ public int getSeconds() {
+ return seconds;
+ }
+
+ public String getServerHostname() {
+ return serverHostname;
+ }
+
+ public int getTransactionId() {
+ return transactionId;
+ }
+
+ public void setAssignedClientAddress(InetAddress assignedClientAddress) {
+ this.assignedClientAddress = assignedClientAddress;
+ }
+
+ public void setBootFileName(String bootFileName) {
+ this.bootFileName = bootFileName;
+ }
+
+ public void setCurrentClientAddress(InetAddress currentClientAddress) {
+ this.currentClientAddress = currentClientAddress;
+ }
+
+ public void setFlags(short flags) {
+ this.flags = flags;
+ }
+
+ public void setHopCount(short hopCount) {
+ this.hopCount = hopCount;
+ }
+
+ public void setMessageType(MessageType messageType) {
+ this.messageType = messageType;
+ }
+
+ public void setNextServerAddress(InetAddress nextServerAddress) {
+ this.nextServerAddress = nextServerAddress;
+ }
+
+ public void setOptions(OptionsField options) {
+ this.options = options;
+ }
+
+ public void setRelayAgentAddress(InetAddress relayAgentAddress) {
+ this.relayAgentAddress = relayAgentAddress;
+ }
+
+ public void setSeconds(int seconds) {
+ this.seconds = seconds;
+ }
+
+ public void setServerHostname(String serverHostname) {
+ this.serverHostname = serverHostname;
+ }
+
+ public void setTransactionId(int transactionId) {
+ this.transactionId = transactionId;
+ }
+
+ public byte getOp() {
+ return op;
+ }
+
+ public void setOp(byte op) {
+ this.op = op;
+ }
+
+ public HardwareAddress getHardwareAddress() {
+ return hardwareAddress;
+ }
+
+ public void setHardwareAddress(HardwareAddress hardwareAddress) {
+ this.hardwareAddress = hardwareAddress;
+ }
+
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(messageType).append(": hwAddress=").append(hardwareAddress)
+ .append(", tx=").append(transactionId).append(", options=").append(
+ options);
- return sb.toString();
- }
+ return sb.toString();
+ }
}
Modified: directory/apacheds/trunk/protocol-dhcp/src/main/java/org/apache/directory/server/dhcp/options/ByteOption.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/protocol-dhcp/src/main/java/org/apache/directory/server/dhcp/options/ByteOption.java?rev=655480&r1=655479&r2=655480&view=diff
==============================================================================
--- directory/apacheds/trunk/protocol-dhcp/src/main/java/org/apache/directory/server/dhcp/options/ByteOption.java (original)
+++ directory/apacheds/trunk/protocol-dhcp/src/main/java/org/apache/directory/server/dhcp/options/ByteOption.java Mon May 12 04:49:35 2008
@@ -35,30 +35,30 @@
*
*/
public abstract class ByteOption extends DhcpOption {
- /**
- * The byte value (represented as a short because of the unsignedness).
- */
- private short byteValue;
+ /**
+ * The byte value (represented as a short because of the unsignedness).
+ */
+ private short byteValue;
- /*
- * @see org.apache.directory.server.dhcp.options.DhcpOption#setData(byte[])
- */
- public void setData(byte[] data) {
- byteValue = (short) (data[0] & 0xff);
- }
+ /*
+ * @see org.apache.directory.server.dhcp.options.DhcpOption#setData(byte[])
+ */
+ public void setData(byte[] data) {
+ byteValue = (short) (data[0] & 0xff);
+ }
- /*
- * @see org.apache.directory.server.dhcp.options.DhcpOption#getData()
- */
- public byte[] getData() {
- return new byte[]{(byte) (byteValue & 0xff)};
- }
+ /*
+ * @see org.apache.directory.server.dhcp.options.DhcpOption#getData()
+ */
+ public byte[] getData() {
+ return new byte[]{(byte) (byteValue & 0xff)};
+ }
- public short getByteValue() {
- return byteValue;
- }
+ public short getByteValue() {
+ return byteValue;
+ }
- public void setShortValue(short shortValue) {
- this.byteValue = shortValue;
- }
+ public void setShortValue(short shortValue) {
+ this.byteValue = shortValue;
+ }
}