public class EmbeddedLdapRuleBuilder extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
DEFAULT_BIND_CREDENTIALS |
static String |
DEFAULT_BIND_DSN |
static String |
DEFAULT_DOMAIN |
static String |
LDAP_SERVER_LISTENER_NAME |
static int |
MAX_PORT_EXCLUSIVE |
static int |
MIN_PORT_EXCLUSIVE |
| Constructor and Description |
|---|
EmbeddedLdapRuleBuilder() |
| Modifier and Type | Method and Description |
|---|---|
EmbeddedLdapRuleBuilder |
bindingToAddress(String address)
Allows the listening address for the embedded LDAP server to be set.
|
EmbeddedLdapRuleBuilder |
bindingToPort(int port)
Sets the port that the in-memory LDAP server will bind to.
|
EmbeddedLdapRule |
build()
Creates a new rule based on the information that was previously provided
|
EmbeddedLdapRuleBuilder |
importingLdifs(String... ldifFiles)
Specify one or more LDIF resources to be imported on startup.
|
static EmbeddedLdapRuleBuilder |
newInstance()
Creates a new builder
|
EmbeddedLdapRuleBuilder |
usingBindCredentials(String bindCredentials)
Sets the credentials to be used to authenticate.
|
EmbeddedLdapRuleBuilder |
usingBindDSN(String bindDSN)
Sets the DSN to bind to when authenticating.
|
EmbeddedLdapRuleBuilder |
usingDomainDsn(String domainDsn)
Sets a domainDsn to be used.
|
EmbeddedLdapRuleBuilder |
withoutDefaultSchema()
Avoid adding UnboundID's default schema that contains the most common LDAP elements defined through various RFC's.
|
EmbeddedLdapRuleBuilder |
withSchema(String... ldifSchemaFiles)
Define schemas to be used for the server.
|
public static final String DEFAULT_DOMAIN
public static final String DEFAULT_BIND_DSN
public static final String DEFAULT_BIND_CREDENTIALS
public static final String LDAP_SERVER_LISTENER_NAME
public static final int MIN_PORT_EXCLUSIVE
public static final int MAX_PORT_EXCLUSIVE
public static EmbeddedLdapRuleBuilder newInstance()
public EmbeddedLdapRuleBuilder usingDomainDsn(String domainDsn)
DEFAULT_DOMAIN fielddomainDsn - a valid DSN stringpublic EmbeddedLdapRuleBuilder usingBindDSN(String bindDSN)
DEFAULT_BIND_DSN fieldbindDSN - a valid DSN stringpublic EmbeddedLdapRuleBuilder usingBindCredentials(String bindCredentials)
DEFAULT_BIND_CREDENTIALS fieldbindCredentials - a password stringpublic EmbeddedLdapRuleBuilder bindingToPort(int port)
port - a port numberIllegalArgumentException - if the provided value for port is not between @{link MIN_PORT_EXCLUSIVE}
and @{MAX_PORT_EXCLUSIVE} (exclusive)public EmbeddedLdapRuleBuilder bindingToAddress(String address)
address - a valid hostname or textual representation of an IP addressIllegalArgumentException - if the value provided for \"address\" is invalidpublic EmbeddedLdapRuleBuilder withoutDefaultSchema()
public EmbeddedLdapRuleBuilder withSchema(String... ldifSchemaFiles)
ldifSchemaFiles - LDIF-files containing schema element definitionspublic EmbeddedLdapRuleBuilder importingLdifs(String... ldifFiles)
ldifFiles - LDIF-files to importpublic EmbeddedLdapRule build()
Copyright © 2015 Sondre Eikanger Kvalø. All rights reserved..