2 * Copyright 2003, OpenLDAP Foundation, All Rights Reserved.
3 * COPYING RESTRICTIONS APPLY, see COPYRIGHT file
6 #ifndef LDAP_ATTRTYPE_H
7 #define LDAP_ATTRTYPE_H
9 #include <ldap_schema.h>
12 #include "StringList.h"
14 #define SCHEMA_PARSE_FLAG 0x03
20 * Represents the Attribute Type (from LDAP schema)
38 LDAPAttrType (const LDAPAttrType& oc);
41 * Constructs new object and fills the data structure by parsing the
43 * @param at_item description of attribute type is string returned
44 * by the search command. It is in the form:
45 * "( SuSE.YaST.Attr:19 NAME ( 'skelDir' ) DESC ''
46 * EQUALITY caseExactIA5Match SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )"
48 LDAPAttrType (string at_item);
53 virtual ~LDAPAttrType();
57 * Returns attribute description
62 * Returns attribute oid
67 * Returns attribute name (first one if there are more of them)
72 * Returns all attribute names
74 StringList getNames();
77 * Returns true if attribute type hllows only single value
81 void setNames (char **at_names);
82 void setDesc (char *at_desc);
83 void setOid (char *at_oid);
84 void setSingle (int at_single_value);
88 #endif // LDAP_ATTRTYPE_H