StringAttributeValue (Apache Hadoop YARN Common 3.5.0 API)
Description: declaration: package: org.apache.hadoop.yarn.nodelabels, class: StringAttributeValue

Package org.apache.hadoop.yarn.nodelabels

# Class StringAttributeValue

java.lang.Object
org.apache.hadoop.yarn.nodelabels.StringAttributeValue

All Implemented Interfaces:
  `AttributeValue`

public class StringAttributeValue extends Object implements AttributeValue
Attribute value for String NodeAttributeType.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `StringAttributeValue()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `boolean`
  `compareForOperation(AttributeValue other, AttributeExpressionOperation op)`
  compare the value against the other based on the AttributeExpressionOperation.
  `String`
  `getValue()`
  `String`
  `toString()`
  `void`
  `validateAndInitializeValue(String valueStr)`
  validate the value based on the type and initialize for further compare operations.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### StringAttributeValue

    public StringAttributeValue()

- ## Method Details

  - ### compareForOperation

    public boolean compareForOperation(AttributeValue other, AttributeExpressionOperation op)
    Description copied from interface: `AttributeValue`
    compare the value against the other based on the AttributeExpressionOperation.
    Specified by:
      `compareForOperation` in interface `AttributeValue`
    Parameters:
      `other` - attribute value.
      `op` - attribute expression operation.
    Returns:
      true if value `other` matches the current value for the operation `op`.

  - ### validateAndInitializeValue

    public void validateAndInitializeValue(String valueStr) throws IOException
    Description copied from interface: `AttributeValue`
    validate the value based on the type and initialize for further compare operations.
    Specified by:
      `validateAndInitializeValue` in interface `AttributeValue`
    Parameters:
      `valueStr` - value.
    Throws:
      `IOException` - io error occur.

  - ### getValue

    public String getValue()
    Specified by:
      `getValue` in interface `AttributeValue`
    Returns:
      original value which was set.

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`