|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.opends.server.tasks.TaskUtils
public class TaskUtils
This class defines a number of static utility methods for server tasks.
| Constructor Summary | |
|---|---|
TaskUtils()
|
|
| Method Summary | |
|---|---|
static void |
disableBackend(java.lang.String backendID)
Disables a backend using an internal modify operation on the backend configuration entry. |
static void |
enableBackend(java.lang.String backendID)
Enables a backend using an internal modify operation on the backend configuration entry. |
static java.util.Map<java.lang.String,ConfigEntry> |
getBackendConfigEntries()
Get all the backend configuration entries defined in the server mapped by their backend ID. |
static java.lang.String |
getBackendID(ConfigEntry configEntry)
Get the backend ID of a backend configuration entry. |
static boolean |
getBoolean(java.util.List<Attribute> attrList,
boolean defaultValue)
Get the single boolean value of an entry attribute that is defined in the schema as a single valued boolean attribute, and that is not expected to have attribute options. |
static BackendCfg |
getConfigEntry(Backend backend)
Get the configuration entry for a given backend. |
static java.util.ArrayList<java.lang.String> |
getMultiValueString(java.util.List<Attribute> attrList)
Get the multiple string values of an entry attribute that is defined in the schema as a multi-valued string attribute, and that is not expected to have attribute options. |
static int |
getSingleValueInteger(java.util.List<Attribute> attrList,
int defaultValue)
Get the single integer value of an entry attribute that is defined in the schema as a single valued integer attribute, and that is not expected to have attribute options. |
static java.lang.String |
getSingleValueString(java.util.List<Attribute> attrList)
Get the single string value of an entry attribute that is defined in the schema as a single valued string attribute, and that is not expected to have attribute options. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public TaskUtils()
| Method Detail |
|---|
public static java.lang.String getBackendID(ConfigEntry configEntry)
configEntry - A backend configuration entry.
public static java.util.Map<java.lang.String,ConfigEntry> getBackendConfigEntries()
public static BackendCfg getConfigEntry(Backend backend)
backend - The backend whose configuration entry is wanted.
public static void enableBackend(java.lang.String backendID)
throws DirectoryException
backendID - Identifies the backend to be enabled.
DirectoryException - If the internal modify operation failed.
public static void disableBackend(java.lang.String backendID)
throws DirectoryException
backendID - Identifies the backend to be disabled.
DirectoryException - If the internal modify operation failed.
public static boolean getBoolean(java.util.List<Attribute> attrList,
boolean defaultValue)
attrList - The attribute value of the entry attribute.defaultValue - The default value to be returned if there is no
recognizable boolean attribute value.
public static java.util.ArrayList<java.lang.String> getMultiValueString(java.util.List<Attribute> attrList)
attrList - The attribute values of the entry attribute.
public static java.lang.String getSingleValueString(java.util.List<Attribute> attrList)
attrList - The attribute value of the entry attribute.
public static int getSingleValueInteger(java.util.List<Attribute> attrList,
int defaultValue)
attrList - The attribute value of the entry attribute.defaultValue - The default value to be returned if there is no
recognizable integer attribute value.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||