You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by ak...@apache.org on 2006/08/14 00:42:25 UTC

svn commit: r431262 - in /directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions: DITContentRule.java DITStructureRule.java NameForm.java

Author: akarasulu
Date: Sun Aug 13 15:42:25 2006
New Revision: 431262

URL: http://svn.apache.org/viewvc?rev=431262&view=rev
Log:
adding NameForms, dITContentRules, and dITStructureRules classes

Added:
    directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/DITContentRule.java
    directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/DITStructureRule.java
    directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/NameForm.java

Added: directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/DITContentRule.java
URL: http://svn.apache.org/viewvc/directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/DITContentRule.java?rev=431262&view=auto
==============================================================================
--- directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/DITContentRule.java (added)
+++ directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/DITContentRule.java Sun Aug 13 15:42:25 2006
@@ -0,0 +1,93 @@
+/*
+ *   Copyright 2006 The Apache Software Foundation
+ *
+ *   Licensed 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.server2.schema.descriptions;
+
+
+import java.util.List;
+
+import javax.naming.NamingException;
+
+
+/**
+ * A ditContentRule specification. ditContentRules identify the content of
+ * entries of a particular structural objectClass. They specify the AUXILIARY
+ * objectClasses and additional attribute types permitted to appear, or excluded
+ * from appearing in entries of the indicated STRUCTURAL objectClass.
+ * <p>
+ * According to section 4.1.6 of RFC 4512:
+ * </p>
+ * 
+ * <pre>
+ *  4.1.6. DIT Content Rules
+ *  
+ * </pre>
+ * 
+ * @see <a href="http://www.faqs.org/rfcs/rfc4512.html">RFC 4512</a>
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$
+ */
+public interface DITContentRule extends OidObject
+{
+    /**
+     * Gets the STRUCTURAL ObjectClass this DITContentRule specifies attributes
+     * for.
+     * 
+     * @return the ObjectClass this DITContentRule specifies attributes for
+     * @throws NamingException if there is a failure resolving the object
+     */
+    ObjectClass getObjectClass() throws NamingException;
+
+
+    /**
+     * Gets all the AUXILIARY ObjectClasses this DITContentRule specifies for
+     * the given STRUCTURAL objectClass.
+     * 
+     * @return the extra AUXILIARY ObjectClasses
+     * @throws NamingException if there is a failure resolving the object
+     */
+    List<ObjectClass> getAuxObjectClasses() throws NamingException;
+
+
+    /**
+     * Gets all the AttributeTypes of the "must" attribute names this
+     * DITContentRule specifies for the given STRUCTURAL objectClass.
+     * 
+     * @return the AttributeTypes of attributes that must be included in entries
+     * @throws NamingException if there is a failure resolving the object
+     */
+    List<AttributeType> getMustNames() throws NamingException;
+
+
+    /**
+     * Gets all the AttributeTypes of the "may" attribute names this
+     * DITContentRule specifies for the given STRUCTURAL objectClass.
+     * 
+     * @return the AttributeTypes of attributes that may be included in entries
+     * @throws NamingException if there is a failure resolving the object
+     */
+    List<AttributeType> getMayNames() throws NamingException;
+
+
+    /**
+     * Gets all the AttributeTypes of the "not" attribute names this
+     * DITContentRule specifies for the given STRUCTURAL objectClass.
+     * 
+     * @return the AttributeTypes of attributes that are excluded in entries
+     * @throws NamingException if there is a failure resolving the object
+     */
+    List <AttributeType> getNotNames() throws NamingException;
+}

Added: directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/DITStructureRule.java
URL: http://svn.apache.org/viewvc/directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/DITStructureRule.java?rev=431262&view=auto
==============================================================================
--- directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/DITStructureRule.java (added)
+++ directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/DITStructureRule.java Sun Aug 13 15:42:25 2006
@@ -0,0 +1,67 @@
+/*
+ *   Copyright 2004 The Apache Software Foundation
+ *
+ *   Licensed 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.server2.schema.descriptions;
+
+
+import java.util.List;
+
+import javax.naming.NamingException;
+
+
+/**
+ * A dITStructureRule definition. A dITStructureRules is a rule governing the
+ * structure of the DIT by specifying a permitted superior to subordinate entry
+ * relationship. A structure rule relates a nameForm, and therefore a STRUCTURAL
+ * objectClass, to superior dITStructureRules. This permits entries of the
+ * STRUCTURAL objectClass identified by the nameForm to exist in the DIT as
+ * subordinates to entries governed by the indicated superior dITStructureRules.
+ * Hence dITStructureRules only apply to structural object classes.
+ * <p>
+ * According to section 4.1.7.1 of RFC 4512:
+ * </p>
+ * 
+ * <pre>
+ * </pre>
+ * 
+ * @see <a href="http://www.faqs.org/rfcs/rfc4512.html">RFC4512</a>
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$
+ */
+public interface DITStructureRule extends OidObject
+{
+    /**
+     * The nameForm associating this ditStructureRule with a structural
+     * objectClass.
+     * 
+     * @return the nameForm for the structural objectClass
+     * @throws NamingException
+     *             if there is a failure resolving the object
+     */
+    NameForm getNameForm() throws NamingException;
+
+
+    /**
+     * Gets a collection of all the superior StructureRules. The difference with
+     * getSuperClass is this method will resolve the entire superior class
+     * chain.
+     * 
+     * @return the chain of StructureRules
+     * @throws NamingException
+     *             if there is a failure resolving the object
+     */
+    List<DITStructureRule> getSuperClasses() throws NamingException;
+}

Added: directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/NameForm.java
URL: http://svn.apache.org/viewvc/directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/NameForm.java?rev=431262&view=auto
==============================================================================
--- directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/NameForm.java (added)
+++ directory/sandbox/akarasulu/apacheds-2.0/schema/descriptions/src/main/java/org/apache/directory/server2/schema/descriptions/NameForm.java Sun Aug 13 15:42:25 2006
@@ -0,0 +1,78 @@
+/*
+ *   Copyright 2004 The Apache Software Foundation
+ *
+ *   Licensed 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.server2.schema.descriptions;
+
+
+import java.util.List;
+
+import javax.naming.NamingException;
+
+
+/**
+ * A nameForm description. NameForms define the relationship between a
+ * STRUCTURAL objectClass definition and the attributeTypes allowed to be used
+ * for the naming of an Entry of that objectClass: it defines which attributes
+ * can be used for the RDN.
+ * <p>
+ * According to section 4.1.7.2 of RFC 4512:
+ * </p>
+ * 
+ * <pre>
+ *  4.1.7.2. Name Forms
+ *  
+ * </pre>
+ * 
+ * @see <a href="http://www.faqs.org/rfcs/rfc4512.html">RFC4512</a>
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$
+ */
+public interface NameForm extends OidObject
+{
+    /**
+     * Gets the STRUCTURAL ObjectClass this name form specifies naming
+     * attributes for.
+     * 
+     * @return the ObjectClass this NameForm is for
+     * @throws NamingException
+     *             if there is a failure resolving the object
+     */
+    ObjectClass getObjectClass() throws NamingException;
+
+
+    /**
+     * Gets all the AttributeTypes of the attributes this NameForm specifies as
+     * having to be used in the given objectClass for naming: as part of the
+     * Rdn.
+     * 
+     * @return the AttributeTypes of the must use attributes
+     * @throws NamingException
+     *             if there is a failure resolving the object
+     */
+    List<AttributeType> getMustUse() throws NamingException;
+
+
+    /**
+     * Gets all the AttributeTypes of the attribute this NameForm specifies as
+     * being useable without requirement in the given objectClass for naming: as
+     * part of the Rdn.
+     * 
+     * @return the AttributeTypes of the may use attributes
+     * @throws NamingException
+     *             if there is a failure resolving the object
+     */
+    List<AttributeType> getMaytUse() throws NamingException;
+}