Class SequenceScalar

    • Method Detail

      • resurrect_done_swapped

        protected Invariant resurrect_done_swapped()
        Since the order is determined from the vars and the sequence is always first, no permute is necesesary. Subclasses can override if necessary.
      • is_symmetric

        @Pure
        public boolean is_symmetric()
        Since the order is determined from the vars and the sequence is always first, this is essentially symmetric. Subclasses can override if necessary.
        Overrides:
        is_symmetric in class BinaryInvariant
      • resurrect_done

        protected Invariant resurrect_done​(int[] permutation)
        Description copied from class: Invariant
        Called on the new invariant just before resurrect() returns it to allow subclasses to fix any information they might have cached from the old Ppt and VarInfos.
        Specified by:
        resurrect_done in class Invariant
        Parameters:
        permutation - the permutation
        Returns:
        the permuted invariant
      • seq_first

        protected final boolean seq_first​(@GuardSatisfied SequenceScalar this)
      • seq_index

        protected final int seq_index​(@GuardSatisfied SequenceScalar this)
      • scl_index

        protected final int scl_index​(@GuardSatisfied SequenceScalar this)
      • seqvar

        public VarInfo seqvar​(@GuardSatisfied SequenceScalar this)
      • sclvar

        public VarInfo sclvar​(@GuardSatisfied SequenceScalar this)
      • seqvar

        public VarInfo seqvar​(VarInfo[] vis)
        Return the sequence variable in the tuple whose VarInfos are corresponds to this.ppt.var_infos.
      • sclvar

        public VarInfo sclvar​(VarInfo[] vis)
        Return the scalar variable in the tuple whose VarInfos are corresponds to this.ppt.var_infos.
      • check_modified

        public abstract InvariantStatus check_modified​(long @Interned [] v1,
                                                       long v2,
                                                       int count)
        Presents a sample to the invariant. Returns whether the sample is consistent with the invariant. Does not change the state of the invariant.
        Parameters:
        count - how many identical samples were observed in a row. For example, three calls to check_modified with a count parameter of 1 is equivalent to one call to check_modified with a count parameter of 3.
        Returns:
        whether or not the sample is consistent with the invariant
      • add_unmodified

        public InvariantStatus add_unmodified​(long @Interned [] v1,
                                              long v2,
                                              int count)
        By default, do nothing if the value hasn't been seen yet. Subclasses can override this.