ExtendedLogMetaRequest.ComparisonExpression (Apache Hadoop YARN Common 3.5.0 API)
Description: declaration: package: org.apache.hadoop.yarn.logaggregation, class: ExtendedLogMetaRequest, class: ComparisonExpression

Package org.apache.hadoop.yarn.logaggregation

# Class ExtendedLogMetaRequest.ComparisonExpression

java.lang.Object
org.apache.hadoop.yarn.logaggregation.ExtendedLogMetaRequest.ComparisonExpression

Enclosing class:
  ExtendedLogMetaRequest

public static class ExtendedLogMetaRequest.ComparisonExpression extends Object
Wraps a comparison logic based on a stringified expression. The format of the expression is: >value = is greater than value <value = is lower than value value = is equal to value

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final String`
  `GREATER_OPERATOR`
  `static final String`
  `LESSER_OPERATOR`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ComparisonExpression(String expression)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `boolean`
  `match(Long value)`
  `boolean`
  `match(Long value, boolean defaultValue)`
  Test the given value with the defined comparison functions based on stringified expression.
  `boolean`
  `match(String value)`
  `String`
  `toString()`

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

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

- ## Field Details

  - ### GREATER_OPERATOR

    public static final String GREATER_OPERATOR
    See Also:
      - Constant Field Values

  - ### LESSER_OPERATOR

    public static final String LESSER_OPERATOR
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### ComparisonExpression

    public ComparisonExpression(String expression)

- ## Method Details

  - ### match

    public boolean match(String value)

  - ### match

    public boolean match(Long value)

  - ### match

    public boolean match(Long value, boolean defaultValue)
    Test the given value with the defined comparison functions based on stringified expression.
    Parameters:
      `value` - value to test with
      `defaultValue` - value to return when no expression was defined
    Returns:
      comparison test result or the given default value

  - ### toString

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