<commit_before>package com.github.stream4j;
public interface Predicate<T> {
	boolean test(T t);
}<commit_msg>changed Predicate to abstract class<commit_after>package com.github.stream4j;

public abstract class Predicate<T> {
	public abstract boolean test(T t);

	public Predicate<T> isEqual(final Object targetRef) {
		return new Predicate<T>() {
			@Override
			public boolean test(T t) {
				return t.equals(targetRef);
			}
		};
	}

	public Predicate<T> negate() {
		final Predicate<T> that = this;
		return new Predicate<T>() {

			@Override
			public boolean test(T t) {
				return !that.test(t);
			}
		};
	}

	public Predicate<T> and(final Predicate<? super T> other) {
		final Predicate<T> that = this;
		return new Predicate<T>() {

			@Override
			public boolean test(T t) {
				return that.test(t) && other.test(t);
			}
		};

	}

	public Predicate<T> or(final Predicate<? super T> other) {
		final Predicate<T> that = this;
		return new Predicate<T>() {

			@Override
			public boolean test(T t) {
				return that.test(t) || other.test(t);
			}
		};
	}
}
{'fraction_non_alphanumeric': 0.13414634146341464, 'fraction_numerical': 0.001876172607879925, 'mean_word_length': 3.5598290598290596, 'pattern_counts': {'":': 0, '<': 18, '<?xml version=': 0, '>': 18, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4109600', 'n_tokens_mistral': 426, 'n_tokens_neox': 369, 'n_words': 99}