Class MatchTrace

  • All Implemented Interfaces:
    java.lang.Iterable<Match>, java.util.Collection<Match>

    public class MatchTrace
    extends java.lang.Object
    implements java.util.Collection<Match>
    Since:
    1.6 Can be accessed through Collection API rather than getMatches for convenience
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected boolean concurrent  
      protected java.util.Collection<Match> matches
      All matches tried during the execution of an ECL module
      protected java.lang.String toStringCached  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      Match add​(java.lang.Object left, java.lang.Object right, boolean matching, MatchRule rule)  
      boolean add​(Match match)  
      boolean addAll​(java.util.Collection<? extends Match> c)  
      void clear()  
      boolean contains​(java.lang.Object o)  
      boolean containsAll​(java.util.Collection<?> c)  
      boolean equals​(java.lang.Object obj)  
      Match getMatch​(java.lang.Object object)
      Returns the first match for the object
      Match getMatch​(java.lang.Object left, java.lang.Object right)  
      Match getMatch​(java.lang.Object left, MatchRule rule)  
      java.util.Collection<Match> getMatches()
      Returns all matches, both successful and pairs that have been compared but do not match
      java.util.Collection<Match> getMatches​(java.lang.Object object)
      Returns all the matches for a given object
      MatchTrace getReduced()
      Returns only successful matches
      boolean hasBeenMatched​(java.lang.Object object)  
      int hashCode()  
      boolean isEmpty()  
      java.util.Iterator<Match> iterator()  
      java.util.stream.Stream<Match> parallelStream()  
      boolean remove​(java.lang.Object o)  
      boolean removeAll​(java.util.Collection<?> c)  
      boolean retainAll​(java.util.Collection<?> c)  
      int size()  
      java.util.stream.Stream<Match> stream()  
      java.lang.Object[] toArray()  
      <T> T[] toArray​(T[] a)  
      java.lang.String toString()  
      java.lang.String toString​(IEolContext context)  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Collection

        removeIf, spliterator, toArray
      • Methods inherited from interface java.lang.Iterable

        forEach
    • Field Detail

      • matches

        protected java.util.Collection<Match> matches
        All matches tried during the execution of an ECL module
      • concurrent

        protected boolean concurrent
      • toStringCached

        protected java.lang.String toStringCached
    • Constructor Detail

      • MatchTrace

        public MatchTrace()
      • MatchTrace

        public MatchTrace​(boolean concurrent)
      • MatchTrace

        public MatchTrace​(MatchTrace copy)
    • Method Detail

      • getReduced

        public MatchTrace getReduced()
        Returns only successful matches
      • add

        public Match add​(java.lang.Object left,
                         java.lang.Object right,
                         boolean matching,
                         MatchRule rule)
      • getMatch

        public Match getMatch​(java.lang.Object left,
                              java.lang.Object right)
      • getMatches

        public java.util.Collection<Match> getMatches​(java.lang.Object object)
        Returns all the matches for a given object
        Parameters:
        object -
        Returns:
      • getMatch

        public Match getMatch​(java.lang.Object object)
        Returns the first match for the object
        Parameters:
        object -
        Returns:
      • getMatch

        public Match getMatch​(java.lang.Object left,
                              MatchRule rule)
      • hasBeenMatched

        public boolean hasBeenMatched​(java.lang.Object object)
      • toString

        public java.lang.String toString​(IEolContext context)
      • getMatches

        public java.util.Collection<Match> getMatches()
        Returns all matches, both successful and pairs that have been compared but do not match
        Returns:
      • stream

        public java.util.stream.Stream<Match> stream()
        Specified by:
        stream in interface java.util.Collection<Match>
        Returns:
        Since:
        1.6
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
        Since:
        1.6
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface java.util.Collection<Match>
        Overrides:
        hashCode in class java.lang.Object
        Since:
        1.6
      • equals

        public boolean equals​(java.lang.Object obj)
        Specified by:
        equals in interface java.util.Collection<Match>
        Overrides:
        equals in class java.lang.Object
        Since:
        1.6
      • add

        public boolean add​(Match match)
        Specified by:
        add in interface java.util.Collection<Match>
        Since:
        1.6
      • remove

        public boolean remove​(java.lang.Object o)
        Specified by:
        remove in interface java.util.Collection<Match>
        Since:
        1.6
      • size

        public int size()
        Specified by:
        size in interface java.util.Collection<Match>
        Since:
        1.6
      • isEmpty

        public boolean isEmpty()
        Specified by:
        isEmpty in interface java.util.Collection<Match>
        Since:
        1.6
      • contains

        public boolean contains​(java.lang.Object o)
        Specified by:
        contains in interface java.util.Collection<Match>
        Since:
        1.6
      • iterator

        public java.util.Iterator<Match> iterator()
        Specified by:
        iterator in interface java.util.Collection<Match>
        Specified by:
        iterator in interface java.lang.Iterable<Match>
        Since:
        1.6
      • toArray

        public java.lang.Object[] toArray()
        Specified by:
        toArray in interface java.util.Collection<Match>
        Since:
        1.6
      • toArray

        public <T> T[] toArray​(T[] a)
        Specified by:
        toArray in interface java.util.Collection<Match>
        Since:
        1.6
      • containsAll

        public boolean containsAll​(java.util.Collection<?> c)
        Specified by:
        containsAll in interface java.util.Collection<Match>
        Since:
        1.6
      • addAll

        public boolean addAll​(java.util.Collection<? extends Match> c)
        Specified by:
        addAll in interface java.util.Collection<Match>
        Since:
        1.6
      • removeAll

        public boolean removeAll​(java.util.Collection<?> c)
        Specified by:
        removeAll in interface java.util.Collection<Match>
        Since:
        1.6
      • retainAll

        public boolean retainAll​(java.util.Collection<?> c)
        Specified by:
        retainAll in interface java.util.Collection<Match>
        Since:
        1.6
      • clear

        public void clear()
        Specified by:
        clear in interface java.util.Collection<Match>
        Since:
        1.6
      • parallelStream

        public java.util.stream.Stream<Match> parallelStream()
        Specified by:
        parallelStream in interface java.util.Collection<Match>
        Since:
        1.6