Class MonitorAttribute
- java.lang.Object
-
- com.unboundid.ldap.sdk.unboundidds.monitors.MonitorAttribute
-
- All Implemented Interfaces:
java.io.Serializable
@NotMutable @ThreadSafety(level=COMPLETELY_THREADSAFE) public final class MonitorAttribute extends java.lang.Object implements java.io.Serializable
This class provides a data structure for providing information about the data presented in an attribute in a Directory Server monitor entry. It includes a human-readable display name, a human-readable description, a class that represents the data type for the values, and the set of values.
NOTE: This class, and other classes within the
com.unboundid.ldap.sdk.unboundiddspackage structure, are only supported for use against Ping Identity, UnboundID, and Nokia/Alcatel-Lucent 8661 server products. These classes provide support for proprietary functionality or for external specifications that are not considered stable or mature enough to be guaranteed to work in an interoperable way with other types of LDAP servers.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MonitorAttribute(java.lang.String name, java.lang.String displayName, java.lang.String description, java.lang.Boolean value)Creates a new monitor attribute with the provided information.MonitorAttribute(java.lang.String name, java.lang.String displayName, java.lang.String description, java.lang.Double value)Creates a new monitor attribute with the provided information.MonitorAttribute(java.lang.String name, java.lang.String displayName, java.lang.String description, java.lang.Double[] values)Creates a new monitor attribute with the provided information.MonitorAttribute(java.lang.String name, java.lang.String displayName, java.lang.String description, java.lang.Integer value)Creates a new monitor attribute with the provided information.MonitorAttribute(java.lang.String name, java.lang.String displayName, java.lang.String description, java.lang.Integer[] values)Creates a new monitor attribute with the provided information.MonitorAttribute(java.lang.String name, java.lang.String displayName, java.lang.String description, java.lang.Long value)Creates a new monitor attribute with the provided information.MonitorAttribute(java.lang.String name, java.lang.String displayName, java.lang.String description, java.lang.Long[] values)Creates a new monitor attribute with the provided information.MonitorAttribute(java.lang.String name, java.lang.String displayName, java.lang.String description, java.lang.String value)Creates a new monitor attribute with the provided information.MonitorAttribute(java.lang.String name, java.lang.String displayName, java.lang.String description, java.lang.String[] values)Creates a new monitor attribute with the provided information.MonitorAttribute(java.lang.String name, java.lang.String displayName, java.lang.String description, java.util.Date value)Creates a new monitor attribute with the provided information.MonitorAttribute(java.lang.String name, java.lang.String displayName, java.lang.String description, java.util.Date[] values)Creates a new monitor attribute with the provided information.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.BooleangetBooleanValue()Retrieves the value for this monitor attribute as aBooleanobject.java.lang.Class<?>getDataType()Retrieves the class representing the data type for this monitor attribute.java.util.DategetDateValue()Retrieves the value for this monitor attribute as aDateobject.java.util.List<java.util.Date>getDateValues()Retrieves the values for this monitor attribute as a list ofDateobjects.java.lang.StringgetDescription()Retrieves the human-readable description for this monitor attribute, if available.java.lang.StringgetDisplayName()Retrieves the human-readable display name for this monitor attribute.java.lang.DoublegetDoubleValue()Retrieves the value for this monitor attribute as aDoubleobject.java.util.List<java.lang.Double>getDoubleValues()Retrieves the values for this monitor attribute as a list ofDoubleobjects.java.lang.IntegergetIntegerValue()Retrieves the value for this monitor attribute as anIntegerobject.java.util.List<java.lang.Integer>getIntegerValues()Retrieves the values for this monitor attribute as a list ofIntegerobjects.java.lang.LonggetLongValue()Retrieves the value for this monitor attribute as aLongobject.java.util.List<java.lang.Long>getLongValues()Retrieves the values for this monitor attribute as a list ofLongobjects.java.lang.StringgetName()Retrieves the name used to identify this monitor attribute.java.lang.StringgetStringValue()Retrieves the value for this monitor attribute as aStringobject.java.util.List<java.lang.String>getStringValues()Retrieves the values for this monitor attribute as a list ofStringobjects.java.lang.ObjectgetValue()Retrieves the value for this monitor attribute as anObject.java.util.List<java.lang.Object>getValues()Retrieves the set of values for this monitor attribute as a list ofObjects.booleanhasMultipleValues()Indicates whether this monitor attribute has multiple values.java.lang.StringtoString()Retrieves a string representation of this monitor attribute.voidtoString(java.lang.StringBuilder buffer)Appends a string representation of this monitor attribute to the provided buffer.
-
-
-
Constructor Detail
-
MonitorAttribute
public MonitorAttribute(@NotNull java.lang.String name, @NotNull java.lang.String displayName, @Nullable java.lang.String description, @NotNull java.lang.Boolean value)
Creates a new monitor attribute with the provided information. It will have a single Boolean value.- Parameters:
name- The name used to identify this monitor attribute. It must not benull.displayName- The human-readable display name for this monitor attribute. It must not benull.description- A human-readable description for this monitor attribute. It may benullif no description is available.value- TheBooleanvalue for this monitor attribute. It must not benull.
-
MonitorAttribute
public MonitorAttribute(@NotNull java.lang.String name, @NotNull java.lang.String displayName, @Nullable java.lang.String description, @NotNull java.util.Date value)
Creates a new monitor attribute with the provided information. It will have a single Date value.- Parameters:
name- The name used to identify this monitor attribute. It must not benull.displayName- The human-readable display name for this monitor attribute. It must not benull.description- A human-readable description for this monitor attribute. It may benullif no description is available.value- TheDatevalue for this monitor attribute. It must not benull.
-
MonitorAttribute
public MonitorAttribute(@NotNull java.lang.String name, @NotNull java.lang.String displayName, @Nullable java.lang.String description, @NotNull java.util.Date[] values)
Creates a new monitor attribute with the provided information. It will have one or more Date values.- Parameters:
name- The name used to identify this monitor attribute. It must not benull.displayName- The human-readable display name for this monitor attribute. It must not benull.description- A human-readable description for this monitor attribute. It may benullif no description is available.values- The set ofDatevalues for this monitor attribute. It must not benullor empty.
-
MonitorAttribute
public MonitorAttribute(@NotNull java.lang.String name, @NotNull java.lang.String displayName, @Nullable java.lang.String description, @NotNull java.lang.Double value)
Creates a new monitor attribute with the provided information. It will have a single Double value.- Parameters:
name- The name used to identify this monitor attribute. It must not benull.displayName- The human-readable display name for this monitor attribute. It must not benull.description- A human-readable description for this monitor attribute. It may benullif no description is available.value- TheDoublevalue for this monitor attribute. It must not benull.
-
MonitorAttribute
public MonitorAttribute(@NotNull java.lang.String name, @NotNull java.lang.String displayName, @Nullable java.lang.String description, @NotNull java.lang.Double[] values)
Creates a new monitor attribute with the provided information. It will have one or more Double values.- Parameters:
name- The name used to identify this monitor attribute. It must not benull.displayName- The human-readable display name for this monitor attribute. It must not benull.description- A human-readable description for this monitor attribute. It may benullif no description is available.values- The set ofDoublevalues for this monitor attribute. It must not benullor empty.
-
MonitorAttribute
public MonitorAttribute(@NotNull java.lang.String name, @NotNull java.lang.String displayName, @Nullable java.lang.String description, @NotNull java.lang.Integer value)
Creates a new monitor attribute with the provided information. It will have a single Long value.- Parameters:
name- The name used to identify this monitor attribute. It must not benull.displayName- The human-readable display name for this monitor attribute. It must not benull.description- A human-readable description for this monitor attribute. It may benullif no description is available.value- TheIntegervalue for this monitor attribute. It must not benull.
-
MonitorAttribute
public MonitorAttribute(@NotNull java.lang.String name, @NotNull java.lang.String displayName, @Nullable java.lang.String description, @NotNull java.lang.Integer[] values)
Creates a new monitor attribute with the provided information. It will have a single Long value.- Parameters:
name- The name used to identify this monitor attribute. It must not benull.displayName- The human-readable display name for this monitor attribute. It must not benull.description- A human-readable description for this monitor attribute. It may benullif no description is available.values- The set ofIntegervalues for this monitor attribute. It must not benullor empty.
-
MonitorAttribute
public MonitorAttribute(@NotNull java.lang.String name, @NotNull java.lang.String displayName, @Nullable java.lang.String description, @NotNull java.lang.Long value)
Creates a new monitor attribute with the provided information. It will have a single Long value.- Parameters:
name- The name used to identify this monitor attribute. It must not benull.displayName- The human-readable display name for this monitor attribute. It must not benull.description- A human-readable description for this monitor attribute. It may benullif no description is available.value- TheLongvalue for this monitor attribute. It must not benull.
-
MonitorAttribute
public MonitorAttribute(@NotNull java.lang.String name, @NotNull java.lang.String displayName, @Nullable java.lang.String description, @NotNull java.lang.Long[] values)
Creates a new monitor attribute with the provided information. It will have one or more Long values.- Parameters:
name- The name used to identify this monitor attribute. It must not benull.displayName- The human-readable display name for this monitor attribute. It must not benull.description- A human-readable description for this monitor attribute. It may benullif no description is available.values- The set ofLongvalues for this monitor attribute. It must not benullor empty.
-
MonitorAttribute
public MonitorAttribute(@NotNull java.lang.String name, @NotNull java.lang.String displayName, @Nullable java.lang.String description, @NotNull java.lang.String value)
Creates a new monitor attribute with the provided information. It will have a single String value.- Parameters:
name- The name used to identify this monitor attribute. It must not benull.displayName- The human-readable display name for this monitor attribute. It must not benull.description- A human-readable description for this monitor attribute. It may benullif no description is available.value- TheStringvalue for this monitor attribute. It must not benull.
-
MonitorAttribute
public MonitorAttribute(@NotNull java.lang.String name, @NotNull java.lang.String displayName, @Nullable java.lang.String description, @NotNull java.lang.String[] values)
Creates a new monitor attribute with the provided information. It will have one or more String values.- Parameters:
name- The name used to identify this monitor attribute. It must not benull.displayName- The human-readable display name for this monitor attribute. It must not benull.description- A human-readable description for this monitor attribute. It may benullif no description is available.values- The set ofStringvalues for this monitor attribute. It must not benullor empty.
-
-
Method Detail
-
getName
@NotNull public java.lang.String getName()
Retrieves the name used to identify this monitor attribute. It is not necessarily human-readable, but it should be used as the key for this monitor attribute in the map returned by theMonitorEntry.getMonitorAttributesmethod.- Returns:
- The name used to identify this monitor attribute.
-
getDisplayName
@NotNull public java.lang.String getDisplayName()
Retrieves the human-readable display name for this monitor attribute.- Returns:
- The human-readable display name for this monitor attribute.
-
getDescription
@Nullable public java.lang.String getDescription()
Retrieves the human-readable description for this monitor attribute, if available.- Returns:
- The human-readable description for this monitor attribute, or
nullif none is available.
-
getDataType
@NotNull public java.lang.Class<?> getDataType()
Retrieves the class representing the data type for this monitor attribute. It will be one of the following class types: Boolean, Date, Double, Long, or String.- Returns:
- The class representing the data type for this monitor attribute.
-
hasMultipleValues
public boolean hasMultipleValues()
Indicates whether this monitor attribute has multiple values.- Returns:
trueif this monitor attribute has more than one value, orfalseif not.
-
getValue
@NotNull public java.lang.Object getValue()
Retrieves the value for this monitor attribute as anObject. If it has multiple values, then the first will be returned.- Returns:
- The value for this monitor attribute as an
Object.
-
getValues
@NotNull public java.util.List<java.lang.Object> getValues()
Retrieves the set of values for this monitor attribute as a list ofObjects.- Returns:
- The set of values for this monitor attribute as a list of
Objects.
-
getBooleanValue
@NotNull public java.lang.Boolean getBooleanValue() throws java.lang.ClassCastException
Retrieves the value for this monitor attribute as aBooleanobject.- Returns:
- The value for this monitor attribute as a
Booleanobject. - Throws:
java.lang.ClassCastException- If the data type for this monitor attribute is notBoolean.
-
getDateValue
@NotNull public java.util.Date getDateValue() throws java.lang.ClassCastException
Retrieves the value for this monitor attribute as aDateobject.- Returns:
- The value for this monitor attribute as a
Dateobject. - Throws:
java.lang.ClassCastException- If the data type for this monitor attribute is notDate.
-
getDateValues
@NotNull public java.util.List<java.util.Date> getDateValues() throws java.lang.ClassCastException
Retrieves the values for this monitor attribute as a list ofDateobjects.- Returns:
- The values for this monitor attribute as a list of
Dateobjects. - Throws:
java.lang.ClassCastException- If the data type for this monitor attribute is notDate.
-
getDoubleValue
@NotNull public java.lang.Double getDoubleValue() throws java.lang.ClassCastException
Retrieves the value for this monitor attribute as aDoubleobject.- Returns:
- The value for this monitor attribute as a
Doubleobject. - Throws:
java.lang.ClassCastException- If the data type for this monitor attribute is notDouble.
-
getDoubleValues
@NotNull public java.util.List<java.lang.Double> getDoubleValues() throws java.lang.ClassCastException
Retrieves the values for this monitor attribute as a list ofDoubleobjects.- Returns:
- The values for this monitor attribute as a list of
Doubleobjects. - Throws:
java.lang.ClassCastException- If the data type for this monitor attribute is notDouble.
-
getIntegerValue
@NotNull public java.lang.Integer getIntegerValue() throws java.lang.ClassCastException
Retrieves the value for this monitor attribute as anIntegerobject.- Returns:
- The value for this monitor attribute as an
Integerobject. - Throws:
java.lang.ClassCastException- If the data type for this monitor attribute is notInteger.
-
getIntegerValues
@NotNull public java.util.List<java.lang.Integer> getIntegerValues() throws java.lang.ClassCastException
Retrieves the values for this monitor attribute as a list ofIntegerobjects.- Returns:
- The values for this monitor attribute as a list of
Integerobjects. - Throws:
java.lang.ClassCastException- If the data type for this monitor attribute is notInteger.
-
getLongValue
@NotNull public java.lang.Long getLongValue() throws java.lang.ClassCastException
Retrieves the value for this monitor attribute as aLongobject.- Returns:
- The value for this monitor attribute as a
Longobject. - Throws:
java.lang.ClassCastException- If the data type for this monitor attribute is notLong.
-
getLongValues
@NotNull public java.util.List<java.lang.Long> getLongValues() throws java.lang.ClassCastException
Retrieves the values for this monitor attribute as a list ofLongobjects.- Returns:
- The values for this monitor attribute as a list of
Longobjects. - Throws:
java.lang.ClassCastException- If the data type for this monitor attribute is notLong.
-
getStringValue
@NotNull public java.lang.String getStringValue() throws java.lang.ClassCastException
Retrieves the value for this monitor attribute as aStringobject.- Returns:
- The value for this monitor attribute as a
Stringobject. - Throws:
java.lang.ClassCastException- If the data type for this monitor attribute is notString.
-
getStringValues
@NotNull public java.util.List<java.lang.String> getStringValues() throws java.lang.ClassCastException
Retrieves the values for this monitor attribute as a list ofStringobjects.- Returns:
- The values for this monitor attribute as a list of
Stringobjects. - Throws:
java.lang.ClassCastException- If the data type for this monitor attribute is notString.
-
toString
@NotNull public java.lang.String toString()
Retrieves a string representation of this monitor attribute.- Overrides:
toStringin classjava.lang.Object- Returns:
- A string representation of this monitor attribute.
-
-