MediaWiki  1.34.0
WatchedItem.php
Go to the documentation of this file.
1 <?php
24 
33 class WatchedItem {
37  private $linkTarget;
38 
42  private $user;
43 
48 
54  public function __construct(
58  ) {
59  $this->user = $user;
60  $this->linkTarget = $linkTarget;
61  $this->notificationTimestamp = $notificationTimestamp;
62  }
63 
68  public function getUser() {
69  return User::newFromIdentity( $this->user );
70  }
71 
75  public function getUserIdentity() {
76  return $this->user;
77  }
78 
82  public function getLinkTarget() {
83  return $this->linkTarget;
84  }
85 
91  public function getNotificationTimestamp() {
93  }
94 }
WatchedItem\$notificationTimestamp
null string $notificationTimestamp
the value of the wl_notificationtimestamp field
Definition: WatchedItem.php:47
User\newFromIdentity
static newFromIdentity(UserIdentity $identity)
Returns a User object corresponding to the given UserIdentity.
Definition: User.php:571
MediaWiki\User\UserIdentity
Interface for objects representing user identity.
Definition: UserIdentity.php:32
WatchedItem\$user
UserIdentity $user
Definition: WatchedItem.php:42
WatchedItem\__construct
__construct(UserIdentity $user, LinkTarget $linkTarget, $notificationTimestamp)
Definition: WatchedItem.php:54
WatchedItem\getUserIdentity
getUserIdentity()
Definition: WatchedItem.php:75
WatchedItem\getUser
getUser()
Definition: WatchedItem.php:68
WatchedItem
Representation of a pair of user and title for watchlist entries.
Definition: WatchedItem.php:33
WatchedItem\getLinkTarget
getLinkTarget()
Definition: WatchedItem.php:82
WatchedItem\getNotificationTimestamp
getNotificationTimestamp()
Get the notification timestamp of this entry.
Definition: WatchedItem.php:91
MediaWiki\Linker\LinkTarget
Definition: LinkTarget.php:26
WatchedItem\$linkTarget
LinkTarget $linkTarget
Definition: WatchedItem.php:37