directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r1068920 - in /directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/actions/delResponse: ./ InitDelResponse.java
Date Wed, 09 Feb 2011 14:54:26 GMT
Author: elecharny
Date: Wed Feb  9 14:54:26 2011
New Revision: 1068920

URL: http://svn.apache.org/viewvc?rev=1068920&view=rev
Log:
Moved the DelResponse action (forgot to commit it)

Added:
    directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/actions/delResponse/
    directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/actions/delResponse/InitDelResponse.java

Added: directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/actions/delResponse/InitDelResponse.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/actions/delResponse/InitDelResponse.java?rev=1068920&view=auto
==============================================================================
--- directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/actions/delResponse/InitDelResponse.java
(added)
+++ directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/actions/delResponse/InitDelResponse.java
Wed Feb  9 14:54:26 2011
@@ -0,0 +1,65 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ *
+ */
+package org.apache.directory.shared.ldap.codec.actions.delResponse;
+
+
+import org.apache.directory.shared.asn1.ber.grammar.GrammarAction;
+import org.apache.directory.shared.ldap.codec.LdapMessageContainer;
+import org.apache.directory.shared.ldap.codec.decorators.DeleteResponseDecorator;
+import org.apache.directory.shared.ldap.model.message.DeleteResponseImpl;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ * The action used to initialize the SearchResultDone response
+ * <pre>
+ * LdapMessage ::= ... DelResponse ...
+ * DelResponse ::= [APPLICATION 11] SEQUENCE { ...
+ * </pre>
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ */
+public class InitDelResponse extends GrammarAction<LdapMessageContainer<DeleteResponseDecorator>>
+{
+    /** The logger */
+    private static final Logger LOG = LoggerFactory.getLogger( InitDelResponse.class );
+
+    /**
+     * Instantiates a new action.
+     */
+    public InitDelResponse()
+    {
+        super( "Init DelResponse" );
+    }
+
+
+    /**
+     * {@inheritDoc}
+     */
+    public void action( LdapMessageContainer<DeleteResponseDecorator> container )
+    {
+        // Now, we can allocate the DelResponse Object
+        DeleteResponseDecorator delResponse = new DeleteResponseDecorator(
+            container.getLdapCodecService(), new DeleteResponseImpl( container.getMessageId()
) );
+        container.setMessage( delResponse );
+
+        LOG.debug( "Del response " );
+    }
+}



Mime
View raw message