Package net.sf.eBus.client
Interface ECondition
-
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface public interface EConditionThis interface allowsESubscribeFeedandEReplyFeedto automatically test a message in order to determine if it should be passed on to a client. IftestreturnstrueeBus forwards the message to the client. Iftestreturnsfalseor throws an exception, then the message is not forwarded.In eBus v. 4.2.0, this interface is now marked as a
@FunctionalInterface, allowing this interface to be defined using a Java lambda expression.- Author:
- Charles Rapp
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleantest(EMessage msg)Returnstrueif the message meets this condition and so should be passed to the eBus client;falseif the message should not be passed on.
-
-
-
Method Detail
-
test
boolean test(EMessage msg)
Returnstrueif the message meets this condition and so should be passed to the eBus client;falseif the message should not be passed on. If this method throws an exception, it is treated the same as having returnedfalse.- Parameters:
msg- The tested notification message.- Returns:
trueif the message meets this condition and so should be passed to the eBus client.
-
-