Medical Imaging Interaction Toolkit  2021.02.99-00f000b3
Medical Imaging Interaction Toolkit
us::LDAPProp Class Reference

#include <usLDAPProp.h>

Public Member Functions

 LDAPProp (const std::string &property)
 
 operator LDAPPropExpr () const
 
LDAPPropExpr operator! () const
 
LDAPPropExpr operator== (const std::string &s) const
 
LDAPPropExpr operator== (const us::Any &s) const
 
template<class T >
LDAPPropExpr operator== (const T &s) const
 
LDAPPropExpr operator!= (const std::string &s) const
 
LDAPPropExpr operator!= (const us::Any &s) const
 
template<class T >
LDAPPropExpr operator!= (const T &s) const
 
LDAPPropExpr operator>= (const std::string &s) const
 
LDAPPropExpr operator>= (const us::Any &s) const
 
template<class T >
LDAPPropExpr operator>= (const T &s) const
 
LDAPPropExpr operator<= (const std::string &s) const
 
LDAPPropExpr operator<= (const us::Any &s) const
 
template<class T >
LDAPPropExpr operator<= (const T &s) const
 
LDAPPropExpr Approx (const std::string &s) const
 
LDAPPropExpr Approx (const us::Any &s) const
 
template<class T >
LDAPPropExpr Approx (const T &s) const
 

Detailed Description

A fluent API for creating LDAP filter strings.

Examples for creating LDAPFilter objects:

// This creates the filter "(&(name=Ben)(!(count=1)))"
LDAPFilter filter(LDAPProp("name") == "Ben" && !(LDAPProp("count") == 1));
// This creates the filter "(|(presence=*)(!(absence=*)))"
LDAPFilter filter(LDAPProp("presence") || !LDAPProp("absence"));
// This creates the filter "(&(ge>=-3)(approx~=hi))"
LDAPFilter filter(LDAPProp("ge") >= -3 && LDAPProp("approx").Approx("hi"));
See also
LDAPFilter

Definition at line 70 of file usLDAPProp.h.

Constructor & Destructor Documentation

◆ LDAPProp()

us::LDAPProp::LDAPProp ( const std::string &  property)

Create a LDAPProp instance for the named LDAP property.

Parameters
propertyThe name of the LDAP property.

Member Function Documentation

◆ Approx() [1/3]

LDAPPropExpr us::LDAPProp::Approx ( const std::string &  s) const

LDAP approximation '~='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

◆ Approx() [2/3]

LDAPPropExpr us::LDAPProp::Approx ( const us::Any s) const

LDAP approximation '~='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

◆ Approx() [3/3]

template<class T >
LDAPPropExpr us::LDAPProp::Approx ( const T &  s) const
inline

LDAP approximation '~='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

Definition at line 187 of file usLDAPProp.h.

References operator &&(), operator||(), US_Core_EXPORT, and US_END_NAMESPACE.

◆ operator LDAPPropExpr()

us::LDAPProp::operator LDAPPropExpr ( ) const

◆ operator!()

LDAPPropExpr us::LDAPProp::operator! ( ) const

States the absence of the LDAP property.

Returns
A LDAP expression object.

◆ operator!=() [1/3]

LDAPPropExpr us::LDAPProp::operator!= ( const std::string &  s) const

Convenience operator for LDAP inequality.

Writing either

LDAPProp("attr") != "val"

or

!(LDAPProp("attr") == "val")

leads to the same string "(!(attr=val))".

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

◆ operator!=() [2/3]

LDAPPropExpr us::LDAPProp::operator!= ( const us::Any s) const

Convenience operator for LDAP inequality.

Writing either

LDAPProp("attr") != "val"

or

!(LDAPProp("attr") == "val")

leads to the same string "(!(attr=val))".

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

◆ operator!=() [3/3]

template<class T >
LDAPPropExpr us::LDAPProp::operator!= ( const T &  s) const
inline

Convenience operator for LDAP inequality.

Writing either

LDAPProp("attr") != "val"

or

!(LDAPProp("attr") == "val")

leads to the same string "(!(attr=val))".

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

Definition at line 130 of file usLDAPProp.h.

References mitk::operator!=(), and operator>=().

◆ operator<=() [1/3]

LDAPPropExpr us::LDAPProp::operator<= ( const std::string &  s) const

LDAP less or equal '<='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

◆ operator<=() [2/3]

LDAPPropExpr us::LDAPProp::operator<= ( const us::Any s) const

LDAP less or equal '<='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

◆ operator<=() [3/3]

template<class T >
LDAPPropExpr us::LDAPProp::operator<= ( const T &  s) const
inline

LDAP less or equal '<='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

Definition at line 168 of file usLDAPProp.h.

References operator<=().

◆ operator==() [1/3]

LDAPPropExpr us::LDAPProp::operator== ( const std::string &  s) const

LDAP equality '='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

◆ operator==() [2/3]

LDAPPropExpr us::LDAPProp::operator== ( const us::Any s) const

LDAP equality '='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

◆ operator==() [3/3]

template<class T >
LDAPPropExpr us::LDAPProp::operator== ( const T &  s) const
inline

LDAP equality '='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

Definition at line 92 of file usLDAPProp.h.

References mitk::operator!=().

◆ operator>=() [1/3]

LDAPPropExpr us::LDAPProp::operator>= ( const std::string &  s) const

LDAP greater or equal '>='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

◆ operator>=() [2/3]

LDAPPropExpr us::LDAPProp::operator>= ( const us::Any s) const

LDAP greater or equal '>='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

◆ operator>=() [3/3]

template<class T >
LDAPPropExpr us::LDAPProp::operator>= ( const T &  s) const
inline

LDAP greater or equal '>='

Parameters
sA type convertible to std::string.
Returns
A LDAP expression object.

Definition at line 149 of file usLDAPProp.h.

References operator<=(), and operator>=().


The documentation for this class was generated from the following file: