All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.triceo.splitlog.conditions.AllLogWatchMessagesAcceptingCondition Maven / Gradle / Ivy

Go to download

These are the core parts of splitlog. This is where the implementations of the public APIs live. Classes from this package come with no API stability guarantees.

There is a newer version: 1.7.2
Show newest version
package com.github.triceo.splitlog.conditions;

import com.github.triceo.splitlog.api.LogWatch;
import com.github.triceo.splitlog.api.Message;
import com.github.triceo.splitlog.api.MessageDeliveryStatus;
import com.github.triceo.splitlog.api.MidDeliveryMessageCondition;
import com.github.triceo.splitlog.api.SimpleMessageCondition;

/**
 * This will accept any message.
 */
public final class AllLogWatchMessagesAcceptingCondition implements MidDeliveryMessageCondition,
        SimpleMessageCondition {

    public static final AllLogWatchMessagesAcceptingCondition INSTANCE = new AllLogWatchMessagesAcceptingCondition();

    private AllLogWatchMessagesAcceptingCondition() {
        // singleton
    }

    @Override
    public boolean accept(final Message evaluate) {
        return true;
    }

    @Override
    public boolean accept(final Message evaluate, final MessageDeliveryStatus status, final LogWatch source) {
        return this.accept(evaluate);
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy