Interface AttributeQuery

All Known Implementing Classes:
Attributes

public interface AttributeQuery

Type-safe query for format attributes which control the formatting process.

Author:
Meno Hochschild
See Also:
ChronoMerger.createFrom(ChronoEntity, AttributeQuery, boolean, boolean)
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Queries if a format attribute exists for given key.
    <A> A
    get​(AttributeKey<A> key)
    Yields a format attribute for given key.
    <A> A
    get​(AttributeKey<A> key, A defaultValue)
    Yields a format attribute for given key.
  • Method Details

    • contains

      boolean contains(AttributeKey<?> key)

      Queries if a format attribute exists for given key.

      Parameters:
      key - attribute key
      Returns:
      true if attribute exists else false
    • get

      <A> A get(AttributeKey<A> key)

      Yields a format attribute for given key.

      Type Parameters:
      A - generic type of attribute value
      Parameters:
      key - attribute key
      Returns:
      attribute value
      Throws:
      NoSuchElementException - if attribute does not exist
    • get

      <A> A get(AttributeKey<A> key, A defaultValue)

      Yields a format attribute for given key.

      Type Parameters:
      A - generic type of attribute value
      Parameters:
      key - attribute key
      defaultValue - replacement value to be used if attribute does not exist
      Returns:
      attribute value