KLDAPCore::LdapControl

Search for usage in LXR

#include <ldapcontrol.h>

Public Member Functions

 LdapControl ()
 
 LdapControl (const LdapControl &that)
 
 LdapControl (const QString &oid, const QByteArray &value, bool critical=false)
 
 ~LdapControl ()
 
bool critical () const
 
QString oid () const
 
LdapControloperator= (const LdapControl &that)
 
int parsePageControl (QByteArray &cookie) const
 
void setControl (const QString &oid, const QByteArray &value, bool critical=false)
 
void setCritical (bool critical)
 
void setOid (const QString &oid)
 
void setValue (const QByteArray &value)
 
QByteArray value () const
 

Static Public Member Functions

static LdapControl createPageControl (int pagesize, const QByteArray &cookie=QByteArray())
 
static void insert (LdapControls &list, const LdapControl &ctrl)
 

Detailed Description

This class represents an LDAP Control.

Definition at line 28 of file ldapcontrol.h.

Constructor & Destructor Documentation

◆ LdapControl() [1/3]

LdapControl::LdapControl ( )

Creates an empty control.

Definition at line 29 of file ldapcontrol.cpp.

◆ LdapControl() [2/3]

LdapControl::LdapControl ( const QString & oid,
const QByteArray & value,
bool critical = false )

Creates a control with the given OID, value and criticality.

Definition at line 35 of file ldapcontrol.cpp.

◆ LdapControl() [3/3]

LdapControl::LdapControl ( const LdapControl & that)

Definition at line 41 of file ldapcontrol.cpp.

◆ ~LdapControl()

LdapControl::~LdapControl ( )
default

Destroys the control object.

Member Function Documentation

◆ createPageControl()

LdapControl LdapControl::createPageControl ( int pagesize,
const QByteArray & cookie = QByteArray() )
staticnodiscard

Creates a paging search control.

Definition at line 112 of file ldapcontrol.cpp.

◆ critical()

bool LdapControl::critical ( ) const
nodiscard

Returns the control's criticality.

Definition at line 77 of file ldapcontrol.cpp.

◆ insert()

void LdapControl::insert ( LdapControls & list,
const LdapControl & ctrl )
static

Inserts a unique control against a list of controls.

If the control already exists in the list is is updated, otherwise it is appended to the list.

Parameters
listthe current list of controls
ctrlthe control to insert
Since
4.4

Definition at line 123 of file ldapcontrol.cpp.

◆ oid()

QString LdapControl::oid ( ) const
nodiscard

Returns the control's OID.

Definition at line 67 of file ldapcontrol.cpp.

◆ operator=()

LdapControl & LdapControl::operator= ( const LdapControl & that)

Definition at line 47 of file ldapcontrol.cpp.

◆ parsePageControl()

int LdapControl::parsePageControl ( QByteArray & cookie) const
nodiscard

Parses a paging results control, which the server returned.

Puts the server's cookie into cookie, and returns the estimated result set size. If the OID is not the page control's OID, or the value cannot be decoded, returns -1.

Parameters
cookiethe cookie to hold server's cookie

Definition at line 97 of file ldapcontrol.cpp.

◆ setControl()

void LdapControl::setControl ( const QString & oid,
const QByteArray & value,
bool critical = false )

Sets the control's OID, value and criticality.

Definition at line 60 of file ldapcontrol.cpp.

◆ setCritical()

void LdapControl::setCritical ( bool critical)

Sets the control's criticality.

Definition at line 92 of file ldapcontrol.cpp.

◆ setOid()

void LdapControl::setOid ( const QString & oid)

Sets the control's OID.

Definition at line 82 of file ldapcontrol.cpp.

◆ setValue()

void LdapControl::setValue ( const QByteArray & value)

Sets the control's value.

Definition at line 87 of file ldapcontrol.cpp.

◆ value()

QByteArray LdapControl::value ( ) const
nodiscard

Returns the control's value.

Definition at line 72 of file ldapcontrol.cpp.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 22 2024 12:05:57 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.