directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r679255 - in /directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core: CoreSession.java DefaultCoreSession.java
Date Thu, 24 Jul 2008 00:53:19 GMT
Author: akarasulu
Date: Wed Jul 23 17:53:19 2008
New Revision: 679255

URL: http://svn.apache.org/viewvc?rev=679255&view=rev
Log:
removing ability to set referral handling mode in core session

Modified:
    directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/CoreSession.java
    directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultCoreSession.java

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/CoreSession.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/CoreSession.java?rev=679255&r1=679254&r2=679255&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/CoreSession.java
(original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/CoreSession.java
Wed Jul 23 17:53:19 2008
@@ -102,22 +102,6 @@
 
     
     /**
-     * Gets the referral handling mode for this CoreSession.
-     *
-     * @return the referral handling mode for this session
-     */
-    ReferralHandlingMode getReferralHandlingMode();
-
-    
-    /**
-     * Sets the referral handling mode for this CoreSession.
-     *
-     * @param referralHandlingMode the referral handling mode for this session
-     */
-    void setReferralHandlingMode( ReferralHandlingMode referralHandlingMode );
-    
-    
-    /**
      * Gets whether or not confidentiality is enabled for this session.
      * 
      * @return true if confidentiality is enabled, false otherwise
@@ -255,6 +239,11 @@
     
     
     void delete( DeleteRequest deleteRequest ) throws Exception;
+
+    /**
+     * Checks to see if an entry exists. 
+     */
+    boolean exists( LdapDN dn ) throws Exception;
     
     
     /**
@@ -266,7 +255,6 @@
      */
     ClonedServerEntry lookup( LdapDN dn ) throws Exception;
 
-    
     ClonedServerEntry lookup( LdapDN dn, Control[] requestControls, ReferralHandlingMode
refMode, 
         LdapDN authorized ) throws Exception;
 

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultCoreSession.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultCoreSession.java?rev=679255&r1=679254&r2=679255&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultCoreSession.java
(original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultCoreSession.java
Wed Jul 23 17:53:19 2008
@@ -34,6 +34,7 @@
 import org.apache.directory.server.core.interceptor.context.AddOperationContext;
 import org.apache.directory.server.core.interceptor.context.CompareOperationContext;
 import org.apache.directory.server.core.interceptor.context.DeleteOperationContext;
+import org.apache.directory.server.core.interceptor.context.EntryOperationContext;
 import org.apache.directory.server.core.interceptor.context.ListOperationContext;
 import org.apache.directory.server.core.interceptor.context.LookupOperationContext;
 import org.apache.directory.server.core.interceptor.context.ModifyOperationContext;
@@ -74,7 +75,6 @@
     private final DirectoryService directoryService;
     private final LdapPrincipal authenticatedPrincipal;
     private LdapPrincipal authorizedPrincipal;
-    private ReferralHandlingMode referralHandlingMode = ReferralHandlingMode.IGNORE;
     
     
     public DefaultCoreSession( LdapPrincipal principal, DirectoryService directoryService
)
@@ -342,24 +342,6 @@
     }
 
 
-    /**
-     * @param referralHandlingMode the referralHandlingMode to set
-     */
-    public void setReferralHandlingMode( ReferralHandlingMode referralHandlingMode )
-    {
-        this.referralHandlingMode = referralHandlingMode;
-    }
-
-
-    /**
-     * @return the referralHandlingMode
-     */
-    public ReferralHandlingMode getReferralHandlingMode()
-    {
-        return referralHandlingMode;
-    }
-
-
     public boolean isAnonymous()
     {
         return getEffectivePrincipal().getJndiName().isEmpty();
@@ -401,6 +383,13 @@
     }
 
 
+    public boolean exists( LdapDN dn ) throws Exception
+    {
+        EntryOperationContext opContext = new EntryOperationContext( this, dn );
+        return directoryService.getOperationManager().hasEntry( opContext );
+    }
+
+
     public void modify( ModifyRequest modifyRequest ) throws Exception
     {
         ModifyOperationContext opContext = new ModifyOperationContext( this, modifyRequest
);



Mime
View raw message