StringValueExp (Java SE 20 & JDK 20) (original) (raw)
All Implemented Interfaces:
[Serializable](../../../java.base/java/io/Serializable.html "interface in java.io")
, [ValueExp](ValueExp.html "interface in javax.management")
public class StringValueExp extends Objectimplements ValueExp
Represents strings that are arguments to relational constraints. A StringValueExp
may be used anywhere a ValueExp
is required.
Since:
1.5
See Also:
Constructor Summary
Constructors
Creates a new StringValueExp
representing the given string.
Method Summary
Applies the ValueExp on a MBean.[getValue](#getValue%28%29)()
Returns the string represented by theStringValueExp
instance.void
[toString](#toString%28%29)()
Returns the string representing the object.
Constructor Details
StringValueExp
public StringValueExp()
Basic constructor.StringValueExp
public StringValueExp(String val)
Creates a newStringValueExp
representing the given string.
Parameters:
val
- the string that will be the value of this expressionMethod Details
getValue
Returns the string represented by the
StringValueExp
instance.
Returns:
the string.toString
Returns the string representing the object.
Overrides:
[toString](../../../java.base/java/lang/Object.html#toString%28%29)
in class[Object](../../../java.base/java/lang/Object.html "class in java.lang")
Returns:
a string representation of the object.setMBeanServer
Deprecated.
Sets the MBean server on which the query is to be performed.
Specified by:
[setMBeanServer](ValueExp.html#setMBeanServer%28javax.management.MBeanServer%29)
in interface[ValueExp](ValueExp.html "interface in javax.management")
Parameters:
s
- The MBean server on which the query is to be performed.apply
Applies the ValueExp on a MBean.
Specified by:
[apply](ValueExp.html#apply%28javax.management.ObjectName%29)
in interface[ValueExp](ValueExp.html "interface in javax.management")
Parameters:
name
- The name of the MBean on which the ValueExp will be applied.
Returns:
TheValueExp
.
Throws:
[BadStringOperationException](BadStringOperationException.html "class in javax.management")
- when an invalid string operation is passed to a method for constructing a query
[BadBinaryOpValueExpException](BadBinaryOpValueExpException.html "class in javax.management")
- when an invalid expression is passed to a method for constructing a query
[BadAttributeValueExpException](BadAttributeValueExpException.html "class in javax.management")
- when an invalid MBean attribute is passed to a query constructing method
[InvalidApplicationException](InvalidApplicationException.html "class in javax.management")
- when an invalid apply is attempted