openldap/contrib/ldapc++/src/LDAPModList.h
Ralf Haferkamp bef9945dff - some code cleanups
- fix for the client caching code (cache is flushed after modifications
  rather than removing only the changed entry)

The code was submitted by Jeff Costlow <j.costlow@f5.com> under the
following terms:

Copyright 2002, F5 Networks, Inc, All rights reserved.
This software is not subject to any license of F5 Networks.

This is free software; you can redistribute and use it
under the same terms as OpenLDAP itself.
2002-04-23 15:28:11 +00:00

49 lines
1,006 B
C++

/*
* Copyright 2000, OpenLDAP Foundation, All Rights Reserved.
* COPYING RESTRICTIONS APPLY, see COPYRIGHT file
*/
#ifndef LDAP_MOD_LIST_H
#define LDAP_MOD_LIST_H
#include <ldap.h>
#include <list>
#include <LDAPModification.h>
typedef std::list<LDAPModification> ModList;
/**
* This container class is used to store multiple LDAPModification-objects.
*/
class LDAPModList{
public :
/**
* Constructs an empty list.
*/
LDAPModList();
/**
* Copy-constructor
*/
LDAPModList(const LDAPModList&);
/**
* Adds one element to the end of the list.
* @param mod The LDAPModification to add to the std::list.
*/
void addModification(const LDAPModification &mod);
/**
* Translates the list to a 0-terminated array of
* LDAPMod-structures as needed by the C-API
*/
LDAPMod** toLDAPModArray();
private :
ModList m_modList;
};
#endif //LDAP_MOD_LIST_H