Class IOContinuousSignal<I>

java.lang.Object
net.maswag.falcaun.AbstractIOSignal<I>
net.maswag.falcaun.IOContinuousSignal<I>
Type Parameters:
I - the type of the input and output signals
All Implemented Interfaces:
IOSignal<I>

public class IOContinuousSignal<I> extends AbstractIOSignal<I>
A signal with continuous output values.
  • Field Details

  • Constructor Details

    • IOContinuousSignal

      public IOContinuousSignal(net.automatalib.word.Word<I> inputSignal, net.automatalib.word.Word<I> outputSignal, ValueWithTime<I> continuousOutputSignal, double signalStep)
      Constructor for the continuous signal.

      The input and output signals must have the same length. The continuous output signal values must be left-right inclusive.

      Parameters:
      inputSignal - the input signal
      outputSignal - the output signal
      continuousOutputSignal - the continuous output signal values with time stamps
      signalStep - the time between each element of inputSignal and outputSignal
  • Method Details

    • stream

      public Stream<IOSignalPiece<I>> stream()
      Constructs a stream of ExtendedIOSignalPiece instances that hold an input signal, an output signal, and the continuous output segment from after the previous input up to and including this input.
      Returns:
      a stream of ExtendedIOSignalPiece
      Throws:
      IllegalArgumentException - if the number of steps in continuousOutputSignal (determined by signalStep) is less than the length of inputSignal
      RuntimeException - if continuousOutputSignal contains null
    • prefixes

      public List<IOSignal<I>> prefixes(boolean longestFirst)
      Description copied from interface: IOSignal
      Returns all the prefix of the signal.
      Parameters:
      longestFirst - if true, the longest prefixes are returned first.
      Returns:
      the list of prefixes of the signal.
    • suffixes

      public List<IOSignal<I>> suffixes(boolean longestFirst)
      Description copied from interface: IOSignal
      Constructs all suffixes of the signal.
      Parameters:
      longestFirst - if true, the longest suffixes are returned first.
      Returns:
      the list of suffixes of the signal.
    • suffix

      public IOSignal<I> suffix(int suffixLen)
      Description copied from interface: IOSignal
      Constructs a suffix of the signal.
      Parameters:
      suffixLen - the length of the suffix
      Returns:
      the suffix of the signal with the given length.
    • subWord

      public IOSignal<I> subWord(int fromIndex)
      Description copied from interface: IOSignal
      Constructs a sub-signal of the signal.
      Parameters:
      fromIndex - the start index (inclusive)
      Returns:
      the sub-signal of the signal from the given index (inclusive) to the end of the signal.
    • subWord

      public IOSignal<I> subWord(int fromIndex, int toIndex)
      Constructs a sub-signal of the signal.
      Parameters:
      fromIndex - the start index (inclusive)
      toIndex - the end index (exclusive)
      Returns:
      the sub-signal of the signal from the given index (inclusive) to the given index (exclusive).