]> git.sur5r.net Git - openldap/blob - contrib/ldapc++/src/LDAPControl.h
35c074749a9db068a0ca3a46274f72c7489a2ae0
[openldap] / contrib / ldapc++ / src / LDAPControl.h
1 /*
2  * Copyright 2000, OpenLDAP Foundation, All Rights Reserved.
3  * COPYING RESTRICTIONS APPLY, see COPYRIGHT file
4  */
5
6
7 #ifndef LDAP_CONTROL_H
8 #define LDAP_CONTROL_H
9 #include <string>
10 #include <ldap.h>
11
12
13 class LDAPCtrl{
14         public :
15         LDAPCtrl(const LDAPCtrl& c);
16                 LDAPCtrl(const char *oid, bool critical, const char *data=0, 
17                 int length=0);
18         LDAPCtrl(const string& oid, bool critical=false,
19                 const string& data=string());
20         LDAPCtrl(const LDAPControl* ctrl);
21         ~LDAPCtrl();
22         
23         string getOID() const;
24         string getData() const;
25         bool isCritical() const;
26         LDAPControl* getControlStruct() const;
27         
28     private :
29         string m_oid;
30         string m_data;
31         bool m_isCritical;
32 };
33
34 #endif //LDAP_CONTROL_H