blob: 5dcaf843203746bc4c8ead40b9468e34bcf8636c [file] [log] [blame]
Title: 6.4 - AttributeType
NavPrev: 6.3-attribute.html
NavPrevText: 6.3 - Attribute
NavUp: 6-ldap-data-structures.html
NavUpText: 6 - LDAP data structures
NavNext: 6.5-ava.html
NavNextText: 6.5 - Ava
Notice: 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.
# 6.4 - AttributeType
The _AttributeType_ is one of the most important schema elements. It describes what can be stored into an _Entry_, its syntax, and the various rules that are to be followed whenever searching for an associated value.
_AttributeType_ are immutable objects, created from the schema, and never changed. One can add a new _AttributeType_, or delete itfrom the schema, but once it's added to the schema, it can't be modified.
Usually, we just use them.
## Description
An _AttributeType_ contains the following informations:
| Value | Description | optional |
|---|---|---|
| OID | An unique _Oid_ for the _AttributeType_ | no |
| NAME | some names, the fist one being considered as the _short name_. | yes |
| DESCR | A textual description describing the _AttributeType_ role. | yes |
| OBSOLETE | A flag indicating if the _AttributeType_ is deprecated | yes|
| SUP | The _AttributeType_ it inherit from | yes (If SYNTAX is null, can't be null) |
| EQUALITY | The EQUALITY _MatchingRule_ | yes (if null, and if SUP is not null, takes its SUP's value) |
| ORDERING | The ORDERING _MatchingRule_ | yes (if null, and if SUP is not null, takes its SUP's value) |
| SUBSTR | The SUBSTR _MatchingRule_ | yes (if null, and if SUP is not null, takes its SUP's value) |
| SYNTAX | The Syntax to follow | yes (If SUP is null, can't be null) |
| SINGLE-VALUE| Tells that the _AttributeType_ does not allow more than one value | yes |
| COLLECTIVE | Define a collective attribute. The _AttributeType_ USAGE must be _userApplications_ | yes |
| NO-USER-MODIFICATION | Tells that the values can't be modified by the user. The _AttributeType_ USAGE must be operational | yes |
| USAGE | The kind of _AttributeType_ : one of {_userApplications_, _directoryOperation_, _directoryOperation_, _directoryOperation_}| yes |
| extensions | Server specific parameters | yes |
An _AttributeType_ has some default elements : it's not OBSOLETE, has no SUP, is not SINGLE-VALUE, is not COLLECTIVE, can be modified by the user, and has an _userApplications_ USAGE.
You can check some of those elements using the following methods:
* isAncestorOf( AttrbuteType ) : tells if the current _AttributeType_ is the ancestor of another one
* isCollective() : tells if the current _AttributeType_ is a collective attribute
* isDescendantOf( AttributeType ) : tells if the current _AttributeType_ inherits from another one
* isOperational() : tells if the current _AttributeType_ is an Operational Attribute
* isSingleValued() : tells if the current _AttributeType_ does not allow more than one value
* isUser() : tells if the current _AttributeType_ is a User Application _AttributeType_
* isUserModifiable() : tells if the _Attributes_ usng this _AttributeType_ can be modified on the server