Chatterino
|
Abstract base class for message predicates. More...
#include <MessagePredicate.hpp>
Public Member Functions | |
virtual | ~MessagePredicate ()=default |
virtual bool | appliesTo (const Message &message)=0 |
Checks whether this predicate applies to the passed message. More... | |
Abstract base class for message predicates.
Message predicates define certain features a message can satisfy. Features are represented by classes derived from this abstract class. A derived class must override appliesTo
in order to test for the desired feature.
|
virtualdefault |
|
pure virtual |
Checks whether this predicate applies to the passed message.
Implementations of appliesTo
should never change the message's content in order to be compatible with other MessagePredicates.
message | the message to check for this predicate |
Implemented in chatterino::MessageFlagsPredicate, chatterino::RegexPredicate, chatterino::SubstringPredicate, chatterino::AuthorPredicate, chatterino::BadgePredicate, chatterino::ChannelPredicate, chatterino::SubtierPredicate, and chatterino::LinkPredicate.