Public Member Functions | |
| isWatched () | |
| Is mTitle being watched by mUser? | |
| addWatch () | |
| Given a title and user (assumes the object is setup), add the watch to the database. | |
| removeWatch () | |
| Same as addWatch, only the opposite. | |
Static Public Member Functions | |
| static | fromUserTitle ($user, $title) |
| Create a WatchedItem object with the given user and title. | |
| static | duplicateEntries ($ot, $nt) |
| Check if the given title already is watched by the user, and if so add watches on a new title. | |
Public Attributes | |
| $mTitle | |
| $mUser | |
| $id | |
| $ns | |
| $ti | |
Static Private Member Functions | |
| static | doDuplicateEntries ($ot, $nt) |
| Handle duplicate entries. | |
Definition at line 10 of file WatchedItem.php.
| WatchedItem::addWatch | ( | ) |
Given a title and user (assumes the object is setup), add the watch to the database.
Definition at line 54 of file WatchedItem.php.
References $dbw, MWNamespace::getSubject(), MWNamespace::getTalk(), wfGetDB(), wfProfileIn(), and wfProfileOut().
| static WatchedItem::doDuplicateEntries | ( | $ | ot, | |
| $ | nt | |||
| ) | [static, private] |
Handle duplicate entries.
Backend for duplicateEntries().
Definition at line 133 of file WatchedItem.php.
References $dbw, $res, $s, and wfGetDB().
Referenced by duplicateEntries().
| static WatchedItem::duplicateEntries | ( | $ | ot, | |
| $ | nt | |||
| ) | [static] |
Check if the given title already is watched by the user, and if so add watches on a new title.
To be used for page renames and such.
| $ot | Title: page title to duplicate entries from, if present | |
| $nt | Title: page title to add watches on |
Definition at line 125 of file WatchedItem.php.
References doDuplicateEntries().
Referenced by Title::moveTo().
| static WatchedItem::fromUserTitle | ( | $ | user, | |
| $ | title | |||
| ) | [static] |
Create a WatchedItem object with the given user and title.
| $user | User: the user to use for (un)watching | |
| $title | Title: the title we're going to (un)watch |
Definition at line 19 of file WatchedItem.php.
Referenced by User::addWatch(), User::isWatched(), and User::removeWatch().
| WatchedItem::isWatched | ( | ) |
| WatchedItem::removeWatch | ( | ) |
Same as addWatch, only the opposite.
Definition at line 86 of file WatchedItem.php.
References $dbw, $success, MWNamespace::getSubject(), MWNamespace::getTalk(), and wfGetDB().
| WatchedItem::$id |
Definition at line 11 of file WatchedItem.php.
| WatchedItem::$mTitle |
Definition at line 11 of file WatchedItem.php.
| WatchedItem::$mUser |
Definition at line 11 of file WatchedItem.php.
| WatchedItem::$ns |
Definition at line 11 of file WatchedItem.php.
| WatchedItem::$ti |
Definition at line 11 of file WatchedItem.php.
1.5.9