MediaWiki master
MediaWiki\RecentChanges\ChangesListQuery\WatchlistJoin Class Reference

A watchlist join with a settable condition on wl_user. More...

Inherits MediaWiki\RecentChanges\ChangesListQuery\BasicJoin.

Collaboration diagram for MediaWiki\RecentChanges\ChangesListQuery\WatchlistJoin:

Public Member Functions

 __construct ()
 
 setUser (UserIdentity $user)
 Set the user whose watchlist will be queried.
 
- Public Member Functions inherited from MediaWiki\RecentChanges\ChangesListQuery\BasicJoin
 __construct (string $tableName, ?string $defaultAlias, $conds, $dependencies=[],)
 
 alias (JoinDependencyProvider $provider, string $alias)
 Add or retrieve an instance of the join with the given table alias.
Parameters
JoinDependencyProvider$provider
string$alias
Returns
ChangesListJoinBuilder

 
 forConds (JoinDependencyProvider $provider)
 Declare that the join is required to provide fields for the WHERE clause.Add or retrieve the default instance of the join.
Parameters
JoinDependencyProvider$provider
Returns
ChangesListJoinBuilder

 
 forFields (JoinDependencyProvider $provider)
 Declare that the join is required to provide fields in the SELECT clause.Add or retrieve the default instance of the join.
Parameters
JoinDependencyProvider$provider
Returns
ChangesListJoinBuilder

 
 prepare (SelectQueryBuilder $sqb)
 Add all registered instances of the join to a SELECT query.
Parameters
SelectQueryBuilder$sqb

 

Protected Member Functions

 getExtraConds (?string $alias)
 Add the wl_user condition.
 

Additional Inherited Members

- Protected Attributes inherited from MediaWiki\RecentChanges\ChangesListQuery\BasicJoin
ChangesListJoinBuilder[] $instances = []
 

Detailed Description

A watchlist join with a settable condition on wl_user.

Since
1.45

Definition at line 12 of file WatchlistJoin.php.

Constructor & Destructor Documentation

◆ __construct()

MediaWiki\RecentChanges\ChangesListQuery\WatchlistJoin::__construct ( )

Definition at line 15 of file WatchlistJoin.php.

Member Function Documentation

◆ getExtraConds()

MediaWiki\RecentChanges\ChangesListQuery\WatchlistJoin::getExtraConds ( ?string $alias)
protected

Add the wl_user condition.

Parameters
string | null$alias
Returns
array

Reimplemented from MediaWiki\RecentChanges\ChangesListQuery\BasicJoin.

Definition at line 41 of file WatchlistJoin.php.

◆ setUser()

MediaWiki\RecentChanges\ChangesListQuery\WatchlistJoin::setUser ( UserIdentity $user)

Set the user whose watchlist will be queried.

Parameters
UserIdentity$user

Definition at line 31 of file WatchlistJoin.php.

References MediaWiki\User\UserIdentity\getId().


The documentation for this class was generated from the following file: