LDAPModule Class Reference

Class for LDAP support. More...

#include <ldapmodule.h>

Inheritance diagram for LDAPModule:
Inheritance graph
[legend]
Collaboration diagram for LDAPModule:
Collaboration graph
[legend]

Public Member Functions

 LDAPModule ()
 Constructor.
virtual ~LDAPModule ()
 Destructor.
void connect (const KockpitAuthObj &authobj)
 Establish LDAP conection.
void bind (KockpitAuthObj &authobj)
 Make a bind.
void reset (KockpitAuthObj &authobj)
 Reset connection.
void disconnect ()
 Destroy existing connection.
void build (QList< KockpitUnitMap * > *kuml, const KockpitBaseObj &baseobj)
 Build kockpit units.
void createEntry (KockpitUnitMap *kunit)
 Create backend entry.
void deleteEntry (KockpitUnitMap *kunit)
 Delete backend entry.
void modifyEntry (KockpitUnitMap *kunit)
 Modify backend entry.
Q_INVOKABLE QStringList getAttrs (const QString &base, const QString &attr)
 Script access.

Private Attributes

LDAPConnection * conn
 LDAP connection.

Detailed Description

Class for LDAP support.

This class is needed for LDAP support for kockpit.


Constructor & Destructor Documentation

LDAPModule::LDAPModule (  ) 

Constructor.

Connection is initialized with NULL.

virtual LDAPModule::~LDAPModule (  )  [inline, virtual]

Destructor.


Member Function Documentation

void LDAPModule::bind ( KockpitAuthObj authobj  ) 

Make a bind.

This function is used to authenticate users against the LDAP backend.

Parameters:
authobj This structure specfifies the connection parameters.
void LDAPModule::build ( QList< KockpitUnitMap * > *  kuml,
const KockpitBaseObj baseobj 
) [virtual]

Build kockpit units.

In dependency of the type which is specified in the basobj structure objects will be created and filled with the datasource attribute values.

Parameters:
kuml pointer to List of pointers to KockpitUnitMap objects (could be KockpitUser or KockpitGroup objects.
baseobj This structure specifies the type of the object which should be filled with attribute values.

Implements KockpitModule.

void LDAPModule::connect ( const KockpitAuthObj authobj  )  [virtual]

Establish LDAP conection.

With this function a connection to the LDAP directory specified with authobj is esablished.

Parameters:
authobj This structure specfifies the connection parameters.

Implements KockpitModule.

void LDAPModule::createEntry ( KockpitUnitMap kunit  )  [virtual]

Create backend entry.

This function creates an entry in the backend. The backend attributes are determined by the AttributeMaps.

Parameters:
kunit Pointer to KockpitUnitMap.

Implements KockpitModule.

void LDAPModule::deleteEntry ( KockpitUnitMap kunit  )  [virtual]

Delete backend entry.

This function deletes an entry from the backend. The backend attributes are determined by the AttributeMaps.

Parameters:
kunit Pointer to KockpitUnitMap.

Implements KockpitModule.

void LDAPModule::disconnect (  )  [virtual]

Destroy existing connection.

Implements KockpitModule.

QStringList LDAPModule::getAttrs ( const QString &  base,
const QString &  attr 
)

Script access.

This function is invoked by a js script - its the only interface for this task.

Parameters:
base LDAP Base.
attr Attributes to scan after in LDAP directory.
Returns:
QStringList list of attribute values.
void LDAPModule::modifyEntry ( KockpitUnitMap kunit  )  [virtual]

Modify backend entry.

This function modifies an entry in the backend. The backend attributes are determined by the AttributeMaps.

Parameters:
kunit Pointer to KockpitUnitMap.

Implements KockpitModule.

void LDAPModule::reset ( KockpitAuthObj authobj  ) 

Reset connection.

This function is used to reset the connection, to make it possible to login again.

Parameters:
authobj This structure specfifies the connection parameters.

Field Documentation

LDAPConnection* LDAPModule::conn [private]

LDAP connection.


The documentation for this class was generated from the following files:
Generated on Wed Mar 24 09:58:14 2010 for kockpit by  doxygen 1.6.3