Interface TemplateResolver<V>

    • Method Detail

      • isFlattening

        default boolean isFlattening()
        Indicates if the resolution should be appended to the parent JSON object.

        For instance, ThreadContextDataResolver, i.e., MDC resolver, uses this flag to indicate whether the contents should be appended to the parent JSON object or not.

      • isResolvable

        default boolean isResolvable()
        Indicates if the resolver if applicable at all.

        For instance, the source line resolver can be short-circuited using this check if the location information is disabled in the layout configuration.

      • isResolvable

        default boolean isResolvable​(V value)
        Indicates if the resolver if applicable for the given value.

        For instance, the stack trace resolver can be short-circuited using this check if the stack traces are disabled in the layout configuration.

      • resolve

        void resolve​(V value,
                     JsonWriter jsonWriter)
        Resolves the given value using the provided JsonWriter.
      • resolve

        default void resolve​(V value,
                             JsonWriter jsonWriter,
                             boolean succeedingEntry)
        Resolves the given value using the provided JsonWriter.
        Parameters:
        succeedingEntry - false, if this is the first element in a collection; true, otherwise