Record Class CallStackSlice

java.lang.Object
java.lang.Record
org.kink_lang.kink.internal.callstack.CallStackSlice
Record Components:
callStackElements - call stack elements of the slice.
tailTraceRingBuffers - trace ring buffers of the slice.
lnums - See Lnums.

public record CallStackSlice(Cse[] callStackElements, TailTraceRingBuffer[] tailTraceRingBuffers, long[] lnums) extends Record
Slice of call stack.
  • Constructor Details

    • CallStackSlice

      public CallStackSlice(Cse[] callStackElements, TailTraceRingBuffer[] tailTraceRingBuffers, long[] lnums)
      Constructs a slice.
      Parameters:
      callStackElements - call stack elements of the slice.
      tailTraceRingBuffers - trace ring buffers of the slice.
      lnums - See Lnums.
  • Method Details

    • size

      public int size()
      Returns the size of the slice.
      Returns:
      the size of the slice.
    • dataStackUsage

      public int dataStackUsage()
      Returns the total usage of the dataStack by the slice.
      Returns:
      the total usage of the dataStack by the slice.
    • hashCode

      public 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 boolean equals(Object arg)
      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:
      arg - the object with which to compare
      Returns:
      true if this object is the same as the arg argument; false otherwise.
    • 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
    • callStackElements

      public Cse[] callStackElements()
      Returns the value of the callStackElements record component.
      Returns:
      the value of the callStackElements record component
    • tailTraceRingBuffers

      public TailTraceRingBuffer[] tailTraceRingBuffers()
      Returns the value of the tailTraceRingBuffers record component.
      Returns:
      the value of the tailTraceRingBuffers record component
    • lnums

      public long[] lnums()
      Returns the value of the lnums record component.
      Returns:
      the value of the lnums record component