See PublishedAPI for packages intended to be used by Plugin and Contrib authors, or browse all packages.
See also Developing plugins, Developer's Bible, Technical Overview
internal package
Foswiki::Contrib::MailerContrib::Subscription Object that represents a subscription to notification on a set of pages. A subscription is expressed as a set of page specs (each of which may contain wildcards) and a depth of children of matching pages that the user is subscribed to.
ClassMethod
new($pages, $childDepth, $options) $pages
- Wildcarded expression matching subscribed pages. $childDepth
- Depth of children of $topic to notify changes for. Defaults to 0 $options
- bitmask of Foswiki::Contrib::MailerContrib::Subscription options Create a new subscription.
Return a string representation of this object, in WebNotify format.
ObjectMethod
matches($topic, $db, $depth) → boolean $topic
- Topic names we are checking (may be an array ref) $db
- Foswiki::Contrib::MailerContrib::UpData database of parent names $depth
- If non-zero, check if the parent of the given topic matches as well. undef = 0. Check if we match this topic. Recurses up the parenthood tree seeing if this is a child of a parent that matches within the depth range.
ObjectMethod
covers($other, $db) → $boolean $other
- Other subscription object we are checking $db
- Foswiki::Contrib::MailerContrib::UpData database of parent names Return true if this subscription already covers all the topics specified by another subscription. Thus:
ObjectMethod
filterExact( \@pages ) → $boolean If this subscription has an exact (string) match to any of the page expressions passed, remove it and return true. * \@pages - list of page expressions to filter
ObjectMethod
getMode() → $mode Get the newsletter mode of this subscription ('', '?' or '!') as specified in WebNotify.
ObjectMethod
equals($other) → $boolean Compare two subscriptions.
This topic: System > Category > DeveloperDocumentationCategory > PerlDoc
Topic revision: 2024-12-23, UnknownUser
Copyright © by the contributing authors. All material on this site is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki? Send feedback