package com.tinkerrocks.process.traversal;

import java.util.function.BiPredicate;

/**
 * Created by ashishn on 9/3/15.
 */
public enum StringContains implements BiPredicate<String, String> {
    subString {
        @Override
        public boolean test(final String first, final String second) {
            return second.contains(first);
        }
    };

    @Override
    public abstract boolean test(String o, String s);

    @Override
    public BiPredicate<String, String> negate() {
        return this.equals(subString) ? subString : null;
    }

}

@@ -344,16 +344,155 @@
       %7D%0A
+    %7D,%0A    notSubString %7B%0A        @Override%0A        public boolean test(String o, String s) %7B%0A            return !s.contains(o);%0A        %7D%0A
     %7D;%0A%0A
@@ -681,11 +681,19 @@
  : n
-ull
+otSubString
 ;%0A  

add negate case