mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-24 16:49:39 -05:00
honor superior Objectclasses
This commit is contained in:
parent
5a5da65d36
commit
39bc8e7ecc
2 changed files with 18 additions and 1 deletions
|
|
@ -16,6 +16,7 @@ LDAPObjClass::LDAPObjClass(){
|
|||
names = StringList ();
|
||||
must = StringList();
|
||||
may = StringList();
|
||||
sup = StringList();
|
||||
}
|
||||
|
||||
LDAPObjClass::LDAPObjClass (const LDAPObjClass &oc){
|
||||
|
|
@ -28,6 +29,7 @@ LDAPObjClass::LDAPObjClass (const LDAPObjClass &oc){
|
|||
must = oc.must;
|
||||
may = oc.may;
|
||||
kind = oc.kind;
|
||||
sup = oc.sup;
|
||||
}
|
||||
|
||||
LDAPObjClass::LDAPObjClass (string oc_item) {
|
||||
|
|
@ -47,6 +49,7 @@ LDAPObjClass::LDAPObjClass (string oc_item) {
|
|||
this->setKind (o->oc_kind);
|
||||
this->setMust (o->oc_at_oids_must);
|
||||
this->setMay (o->oc_at_oids_may);
|
||||
this->setSup (o->oc_sup_oids);
|
||||
}
|
||||
// else? -> error
|
||||
}
|
||||
|
|
@ -71,6 +74,10 @@ void LDAPObjClass::setMay (char **oc_may) {
|
|||
may = StringList (oc_may);
|
||||
}
|
||||
|
||||
void LDAPObjClass::setSup (char **oc_sup) {
|
||||
sup = StringList (oc_sup);
|
||||
}
|
||||
|
||||
void LDAPObjClass::setDesc (char *oc_desc) {
|
||||
desc = string ();
|
||||
if (oc_desc)
|
||||
|
|
@ -103,6 +110,10 @@ StringList LDAPObjClass::getMay () {
|
|||
return may;
|
||||
}
|
||||
|
||||
StringList LDAPObjClass::getSup () {
|
||||
return sup;
|
||||
}
|
||||
|
||||
string LDAPObjClass::getName () {
|
||||
|
||||
if (names.empty())
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ using namespace std;
|
|||
*/
|
||||
class LDAPObjClass{
|
||||
private :
|
||||
StringList names, must, may;
|
||||
StringList names, must, may, sup;
|
||||
string desc, oid;
|
||||
int kind;
|
||||
|
||||
|
|
@ -81,6 +81,11 @@ class LDAPObjClass{
|
|||
* Returns list of allowed (and not required) attributes
|
||||
*/
|
||||
StringList getMay();
|
||||
|
||||
/**
|
||||
* Returns list of the OIDs of the superior ObjectClasses
|
||||
*/
|
||||
StringList getSup();
|
||||
|
||||
void setNames (char **oc_names);
|
||||
void setMay (char **oc_may);
|
||||
|
|
@ -88,6 +93,7 @@ class LDAPObjClass{
|
|||
void setDesc (char *oc_desc);
|
||||
void setOid (char *oc_oid);
|
||||
void setKind (int oc_kind);
|
||||
void setSup (char **oc_sup);
|
||||
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue