2000-10-03 14:50:44 -04:00
|
|
|
/*
|
|
|
|
|
* Copyright 2000, OpenLDAP Foundation, All Rights Reserved.
|
|
|
|
|
* COPYING RESTRICTIONS APPLY, see COPYRIGHT file
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#ifndef LDAP_REFERENCE_LIST_H
|
|
|
|
|
#define LDAP_REFERENCE_LIST_H
|
|
|
|
|
|
|
|
|
|
#include <list>
|
|
|
|
|
|
|
|
|
|
class LDAPSearchReference;
|
|
|
|
|
|
|
|
|
|
typedef list<LDAPSearchReference> RefList;
|
|
|
|
|
|
2001-02-19 06:34:28 -05:00
|
|
|
/**
|
|
|
|
|
* Container class for storing a list of Search References
|
|
|
|
|
*
|
|
|
|
|
* Used internally only by LDAPSearchResults
|
|
|
|
|
*/
|
2000-10-03 14:50:44 -04:00
|
|
|
class LDAPReferenceList{
|
|
|
|
|
public:
|
2001-03-15 06:07:58 -05:00
|
|
|
typedef RefList::const_iterator const_iterator;
|
|
|
|
|
|
2001-02-19 06:34:28 -05:00
|
|
|
/**
|
|
|
|
|
* Constructs an empty list.
|
|
|
|
|
*/
|
2000-10-03 14:50:44 -04:00
|
|
|
LDAPReferenceList();
|
2001-02-19 06:34:28 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Copy-constructor
|
|
|
|
|
*/
|
2000-10-03 14:50:44 -04:00
|
|
|
LDAPReferenceList(const LDAPReferenceList& rl);
|
2001-02-19 06:34:28 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Destructor
|
|
|
|
|
*/
|
2000-10-03 14:50:44 -04:00
|
|
|
~LDAPReferenceList();
|
|
|
|
|
|
2001-02-19 06:34:28 -05:00
|
|
|
/**
|
|
|
|
|
* @return The number of LDAPSearchReference-objects that are
|
|
|
|
|
* currently stored in this list.
|
|
|
|
|
*/
|
2000-10-03 14:50:44 -04:00
|
|
|
size_t size() const;
|
2001-02-19 06:34:28 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @return A iterator that points to the first element of the list.
|
|
|
|
|
*/
|
2000-10-03 14:50:44 -04:00
|
|
|
const_iterator begin() const;
|
2001-02-19 06:34:28 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @return A iterator that points to the element after the last
|
|
|
|
|
* element of the list.
|
|
|
|
|
*/
|
2000-10-03 14:50:44 -04:00
|
|
|
const_iterator end() const;
|
2001-02-19 06:34:28 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Adds one element to the end of the list.
|
|
|
|
|
* @param e The LDAPSearchReference to add to the list.
|
|
|
|
|
*/
|
2000-10-03 14:50:44 -04:00
|
|
|
void addReference(const LDAPSearchReference& e);
|
|
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
RefList m_refs;
|
|
|
|
|
};
|
|
|
|
|
#endif // LDAP_REFERENCE_LIST_H
|
|
|
|
|
|