Record Class TraceRecord

java.lang.Object
java.lang.Record
com.evolveum.midpoint.schema.traces.details.TraceRecord

public record TraceRecord(@NotNull String firstLine, @Nullable String nextLines) extends Record
Default or customized text form of an AbstractTraceEvent.
See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
    TraceRecord(@NotNull String firstLine, @Nullable String nextLines)
    Creates an instance of a TraceRecord record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    final boolean
    Indicates whether some other object is "equal to" this one.
    @NotNull String
    Returns the value of the firstLine record component.
    final int
    Returns a hash code value for this object.
    @Nullable String
    Returns the value of the nextLines record component.
    of(@NotNull String firstLine)
     
    of(@NotNull String firstLine, @Nullable String nextLines)
     
    final String
    Returns a string representation of this record class.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • TraceRecord

      public TraceRecord(@NotNull @NotNull String firstLine, @Nullable @Nullable String nextLines)
      Creates an instance of a TraceRecord record class.
      Parameters:
      firstLine - the value for the firstLine record component
      nextLines - the value for the nextLines record component
  • Method Details

    • of

      public static TraceRecord of(@NotNull @NotNull String firstLine)
    • of

      public static TraceRecord of(@NotNull @NotNull String firstLine, @Nullable @Nullable String nextLines)
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • firstLine

      @NotNull public @NotNull String firstLine()
      Returns the value of the firstLine record component.
      Returns:
      the value of the firstLine record component
    • nextLines

      @Nullable public @Nullable String nextLines()
      Returns the value of the nextLines record component.
      Returns:
      the value of the nextLines record component