+ /** Returns true whether or not the given string is covered by this line.
+ * @param str The string to match against. The details of what must be
+ * in this string and the mechanics of the match are defined by the
+ * derived class.
+ * @return True if there is a match
+ */
+ virtual bool Matches(const std::string &str) = 0;
+
+ /** Apply a line against a user. The mechanics of what occurs when
+ * the line is applied are specific to the derived class.
+ * @param u The user to apply against
+ */
+ virtual void Apply(User* u);
+
+ /** Called when the line is unset either via expiry or
+ * via explicit removal.
+ */
+ virtual void Unset() { }
+
+ /** Called when the expiry message is to be displayed for the
+ * line. Usually a line in the form 'expiring Xline blah, set by...'
+ * see the DisplayExpiry methods of GLine, ELine etc.
+ */
+ virtual void DisplayExpiry();
+
+ /** Returns the displayable form of the pattern for this xline,
+ * e.g. '*\@foo' or '*baz*'. This must always return the full pattern
+ * in a form which can be used to construct an entire derived xline,
+ * even if it is stored differently internally (e.g. GLine stores the
+ * ident and host parts seperately but will still return ident\@host
+ * for its Displayable() method)
+ */
+ virtual const char* Displayable() = 0;
+
+ /** Called when the xline has just been added.
+ */
+ virtual void OnAdd() { }