Interface ImmutableTrace

  • All Known Subinterfaces:
    SearchTrace, Trace

    public interface ImmutableTrace
    A trace contains information about processed data. A trace should conform to the trace model defined by Hansken. Unlike a Trace, an ImmutableTrace instance lacks methods to modify or update its properties and data streams after the instance is created.
    • Method Detail

      • traceId

        String traceId()
        Get the trace id of this trace. Note: This value is equal to the id of a Hansken Trace.
        Returns:
        the id of this trace
      • types

        Set<String> types()
        Get all the types of this trace.
        Returns:
        all types of this trace
      • properties

        Set<String> properties()
        Return the names of all the properties contained in this trace.
        Returns:
        the properties of this trace
      • get

        <T> T get​(String name)
        Get the value of the property with given name on this trace.

        Note: the method is declared with a type parameter to allow for automatic casting. It is an unchecked cast, so implementers have to make sure that the type of the value returned is of type T.

        Type Parameters:
        T - the type of the value
        Parameters:
        name - the name of the value to get
        Returns:
        the value of the property