Package org.apache.any23.extractor.xpath

## Class Term<T extends org.eclipse.rdf4j.model.Value>

- java.lang.Object
- - org.apache.any23.extractor.xpath.Term<T>

- Direct Known Subclasses:
    `TemplateGraph`, `TemplateObject`, `TemplatePredicate`, `TemplateSubject`

      public abstract class Term<T extends org.eclipse.rdf4j.model.Value>
      extends Object

  Represents a generic template term.
  Author:
    Michele Mostarda (mostarda@fbk.eu)

- - ### Constructor Summary

    Constructors
    Modifier | Constructor | Description
    --- | --- | ---
    `protected` | `Term​(String internalValue, boolean isVar)` | Constructor.

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `String` | `getInternalValue()` |
    `T` | `getValue​(Map<String,​String> varMapping)` | Returns the value represented by this `Term` given the `varMapping`, the #isVar and #internalValue parameters.
    `protected abstract T` | `getValueInternal​(String value)` |
    `boolean` | `isVar()` |
    `String` | `toString()` |

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

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

- - ### Constructor Detail

    - #### Term

          protected Term​(String internalValue,
                         boolean isVar)

      Constructor.
      Parameters:
        `internalValue` - internal term value.
        `isVar` - if true the `internalValue` is a variable name, otherwise is a constant.

  - ### Method Detail

    - #### getInternalValue

          public String getInternalValue()

      Returns:
        the internal value.

    - #### isVar

          public boolean isVar()

      Returns:
        the isVar flag value.

    - #### getValue

          public T getValue​(Map<String,​String> varMapping)

      Returns the value represented by this `Term` given the `varMapping`, the #isVar and #internalValue parameters.
      Parameters:
        `varMapping` - a map representing values of variables.
      Returns:
        the value for this term.

    - #### getValueInternal

          protected abstract T getValueInternal​(String value)

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`