Interface NuggetCliTicker

Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface NuggetCliTicker
Monotonic time source used by the nugget CLI for local deadlines and credential-cache expiry.

The value has the same comparison semantics as System.nanoTime(): it is not a wall-clock timestamp and is meaningful only for elapsed-time calculations within one process. Implementations used by tests and demos should be deterministic and non-blocking.

  • Method Summary

    Modifier and Type
    Method
    Description
    long
    Returns the current monotonic time in nanoseconds.
    Returns a ticker backed by System.nanoTime().
  • Method Details

    • nanoTime

      long nanoTime()
      Returns the current monotonic time in nanoseconds.
      Returns:
      monotonic nanosecond value
    • system

      static NuggetCliTicker system()
      Returns a ticker backed by System.nanoTime().
      Returns:
      system monotonic ticker