|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.pentaho.di.trans.steps.ldapinput.LDAPConnection
public class LDAPConnection
Field Summary | |
---|---|
static String |
DEFAUL_FILTER_STRING
|
static int |
DEFAULT_PORT
|
static int |
PROTOCOL_LDAP
|
static int |
PROTOCOL_LDAP_SSL
|
static int |
PROTOCOL_LDAP_TLS
|
static String[] |
PROTOCOLS
|
static int |
SEARCH_SCOPE_OBJECT_SCOPE
|
static int |
SEARCH_SCOPE_ONELEVEL_SCOPE
|
static int |
SEARCH_SCOPE_SUBTREE_SCOPE
|
static int |
STATUS_ADDED
|
static int |
STATUS_DELETED
|
static int |
STATUS_INSERTED
|
static int |
STATUS_SKIPPED
|
static int |
STATUS_UPDATED
|
Constructor Summary | |
---|---|
LDAPConnection(LogChannelInterface logInterface,
String hostName,
int port)
Construct a new LDAP Connection |
Method Summary | |
---|---|
int |
add(String dn,
String[] attributes,
String[] values,
String multValuedSeparator,
boolean checkEntry)
|
void |
addBinaryAttribute(String name)
|
void |
addSortingAttributes(String value)
|
void |
close()
Close the LDAP connection |
void |
connect()
Connect to LDAP server |
void |
connect(String username,
String password)
Connect to LDAP server |
int |
delete(String dn,
boolean checkEntry)
|
static String |
extractBytesAndConvertToString(Attribute attr,
boolean isSID)
|
Attributes |
getAttributes()
|
String |
getDerefAliases()
|
RowMeta |
getFields(String searchBase)
|
int |
getProtocol()
|
static String |
getProtocolCode(int protocol)
|
static int |
getProtocolFromCode(String protocol)
|
String |
getReferral()
|
List<String> |
getSortingAttributes()
|
int |
getTimeLimit()
|
String |
getTrustStorePassword()
|
String |
getTrustStorePath()
|
void |
insert(String dn,
String[] attributes,
String[] values,
String multValuedSeparator)
Insert record in LDAP based on DN |
boolean |
isTrustAllCertificates()
|
void |
rename(String oldDn,
String newDn,
boolean deleteRDN)
Rename an entry |
void |
search(String searchBase,
String filter,
int limitRows,
String[] attributeReturned,
int searchScope)
|
void |
setDerefAliases(String value)
|
void |
SetPagingSize(int value)
|
void |
setProtocol(int protocol)
|
void |
setReferral(String value)
|
void |
setSortingAttributesKeys(String[] value)
|
void |
setTimeLimit(int timeLimit)
|
void |
setTrustStorePassword(String password)
|
void |
setTrustStorePath(String trustStorePath)
|
void |
trustAllCertificates(boolean value)
|
int |
update(String dn,
String[] attributes,
String[] values,
boolean checkEntry)
|
int |
upsert(String dn,
String[] attributes,
String[] values,
String[] attributesToUpdate,
String[] valuesToUpdate,
String multValuedSeparator)
Upsert record in LDAP First we will check if the entry exist based on DN If we can not find it, we will create it otherwise, we will perform an update |
void |
useTLS()
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String[] PROTOCOLS
public static final int PROTOCOL_LDAP
public static final int PROTOCOL_LDAP_SSL
public static final int PROTOCOL_LDAP_TLS
public static final int SEARCH_SCOPE_OBJECT_SCOPE
public static final int SEARCH_SCOPE_ONELEVEL_SCOPE
public static final int SEARCH_SCOPE_SUBTREE_SCOPE
public static final int DEFAULT_PORT
public static final String DEFAUL_FILTER_STRING
public static final int STATUS_SKIPPED
public static final int STATUS_INSERTED
public static final int STATUS_UPDATED
public static final int STATUS_DELETED
public static final int STATUS_ADDED
Constructor Detail |
---|
public LDAPConnection(LogChannelInterface logInterface, String hostName, int port) throws KettleException
KettleException
Method Detail |
---|
public void setTrustStorePath(String trustStorePath)
public String getTrustStorePath()
public void setTrustStorePassword(String password)
public String getTrustStorePassword()
public void trustAllCertificates(boolean value)
public boolean isTrustAllCertificates()
public int getProtocol()
public void setProtocol(int protocol)
public void useTLS()
public void connect() throws KettleException
KettleException
public void connect(String username, String password) throws KettleException
username
- : usernamepassword
- : password
KettleException
public void setSortingAttributesKeys(String[] value)
public void addSortingAttributes(String value)
public List<String> getSortingAttributes()
public void setTimeLimit(int timeLimit)
public int getTimeLimit()
public void SetPagingSize(int value)
public void setReferral(String value)
public String getReferral()
public void setDerefAliases(String value)
public String getDerefAliases()
public void search(String searchBase, String filter, int limitRows, String[] attributeReturned, int searchScope) throws KettleException
KettleException
public void addBinaryAttribute(String name)
public int delete(String dn, boolean checkEntry) throws KettleException
KettleException
public int update(String dn, String[] attributes, String[] values, boolean checkEntry) throws KettleException
KettleException
public int add(String dn, String[] attributes, String[] values, String multValuedSeparator, boolean checkEntry) throws KettleException
KettleException
public void insert(String dn, String[] attributes, String[] values, String multValuedSeparator) throws KettleException
dn
- : Distinguished Name (Key for lookup)attributes
- : contains all the attributes to set for insertvalues
- : contains all the values for attributesmultValuedSeparator
- : multi-valued attributes separator
KettleException
public int upsert(String dn, String[] attributes, String[] values, String[] attributesToUpdate, String[] valuesToUpdate, String multValuedSeparator) throws KettleException
dn
- : Distinguished Name (Key for lookup)attributes
- : contains all the attributes to set for insertvalues
- : contains all the values for attributesattributesToUpdate
- : contains attributes to updatevaluesToUpdate
- : contains values for attributes to updatemultValuedSeparator
- : multi-valued attributes separator
KettleException
public void rename(String oldDn, String newDn, boolean deleteRDN) throws KettleException
oldDn
- Distinguished name of the entry to renamenewDn
- target Distinguished name (new)deleteRDN
- To specify whether you want to keep the old name attribute when you use rename entry
true : do not keep the old value (defaut)
false : keep the old value as an attribute
KettleException
public void close() throws KettleException
KettleException
public Attributes getAttributes() throws KettleException
KettleException
public static String extractBytesAndConvertToString(Attribute attr, boolean isSID) throws Exception
Exception
public RowMeta getFields(String searchBase) throws KettleException
KettleException
public static int getProtocolFromCode(String protocol)
public static String getProtocolCode(int protocol)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |