Package org.bremersee.ldaptive
Interface LdaptiveAttribute<T>
- Type Parameters:
T- the type parameter
- All Known Implementing Classes:
LdaptiveAttribute.Specification
public interface LdaptiveAttribute<T>
The ldaptive attribute.
- Author:
- Christian Bremer
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classThe ldaptive attribute specification. -
Method Summary
Modifier and TypeMethodDescriptiondefault org.ldaptive.LdapAttributeCreate attribute ldap attribute.default org.ldaptive.LdapAttributecreateAttribute(Collection<T> values) Create attribute ldap attribute.default org.ldaptive.LdapAttributecreateAttribute(T value) Create attribute ldap attribute.static LdaptiveAttribute<String> Define ldaptive attribute.static <T> LdaptiveAttribute<T> Define ldaptive attribute.default booleanexists(org.ldaptive.LdapEntry entry) Determines whether the attribute exists in the given ldap entry or not.getName()Gets name.getValue(org.ldaptive.LdapEntry entry) Gets value.Gets value.getValues(org.ldaptive.LdapEntry entry) Gets values.org.ldaptive.transcode.ValueTranscoder<T> Gets value transcoder.booleanisBinary()Is binary.default Optional<org.ldaptive.AttributeModification> Sets value.default Optional<org.ldaptive.AttributeModification> setValue(org.ldaptive.LdapEntry entry, T value, BiPredicate<T, T> condition) Sets value.default Optional<org.ldaptive.AttributeModification> setValues(org.ldaptive.LdapEntry entry, Collection<T> values) Sets values.
-
Method Details
-
getName
String getName()Gets name.- Returns:
- the name
-
isBinary
boolean isBinary()Is binary.- Returns:
- the boolean
-
getValueTranscoder
org.ldaptive.transcode.ValueTranscoder<T> getValueTranscoder()Gets value transcoder.- Returns:
- the value transcoder
-
exists
default boolean exists(org.ldaptive.LdapEntry entry) Determines whether the attribute exists in the given ldap entry or not.- Parameters:
entry- the entry- Returns:
trueif the attribute exists, otherwisefalse
-
getValue
Gets value.- Parameters:
entry- the entry- Returns:
- the value
-
getValue
Gets value.- Parameters:
entry- the entrydefaultValue- the default value- Returns:
- the value
-
getValues
Gets values.- Parameters:
entry- the entry- Returns:
- the values
-
setValue
default Optional<org.ldaptive.AttributeModification> setValue(org.ldaptive.LdapEntry entry, T value) Sets value.- Parameters:
entry- the entryvalue- the value- Returns:
- the value
-
setValue
default Optional<org.ldaptive.AttributeModification> setValue(org.ldaptive.LdapEntry entry, T value, BiPredicate<T, T> condition) Sets value.- Parameters:
entry- the entryvalue- the valuecondition- the condition- Returns:
- the value
-
setValues
default Optional<org.ldaptive.AttributeModification> setValues(org.ldaptive.LdapEntry entry, Collection<T> values) Sets values.- Parameters:
entry- the entryvalues- the values- Returns:
- the values
-
createAttribute
default org.ldaptive.LdapAttribute createAttribute()Create attribute ldap attribute.- Returns:
- the ldap attribute
-
createAttribute
Create attribute ldap attribute.- Parameters:
value- the value- Returns:
- the ldap attribute
-
createAttribute
Create attribute ldap attribute.- Parameters:
values- the values- Returns:
- the ldap attribute
-
define
Define ldaptive attribute.- Parameters:
name- the name- Returns:
- the ldaptive attribute
-
define
static <T> LdaptiveAttribute<T> define(String name, boolean binary, org.ldaptive.transcode.ValueTranscoder<T> valueTranscoder) Define ldaptive attribute.- Type Parameters:
T- the type parameter- Parameters:
name- the namebinary- the binaryvalueTranscoder- the value transcoder- Returns:
- the ldaptive attribute
-