directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r1420129 - /directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AttributeType.java
Date Tue, 11 Dec 2012 12:45:47 GMT
Author: elecharny
Date: Tue Dec 11 12:45:46 2012
New Revision: 1420129

URL: http://svn.apache.org/viewvc?rev=1420129&view=rev
Log:
Added the isUser() and isOperational() methods

Modified:
    directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AttributeType.java

Modified: directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AttributeType.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AttributeType.java?rev=1420129&r1=1420128&r2=1420129&view=diff
==============================================================================
--- directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AttributeType.java
(original)
+++ directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AttributeType.java
Tue Dec 11 12:45:46 2012
@@ -445,6 +445,26 @@ public class AttributeType extends Abstr
     {
         return substringOid;
     }
+    
+    
+    /**
+     * Tells if the attributeType is a USER attribute or not
+     * @return true if this is a USER attributeType
+     */
+    public boolean isUser()
+    {
+        return usage == UsageEnum.USER_APPLICATIONS;
+    }
+    
+    
+    /**
+     * Tells if the attributeType is an OPERATIONAL attribute or not
+     * @return true if this is an OPERATIONAL attributeType
+     */
+    public boolean isOperational()
+    {
+        return usage != UsageEnum.USER_APPLICATIONS;
+    }
 
 
     /**



Mime
View raw message