Go to the documentation of this file.
22 use InvalidArgumentException;
23 use Wikimedia\ScopedCallback;
40 const TRIGGER_IDLE = 1;
42 const TRIGGER_COMMIT = 2;
44 const TRIGGER_ROLLBACK = 3;
47 const TRANSACTION_EXPLICIT =
'';
49 const TRANSACTION_INTERNAL =
'implicit';
52 const ATOMIC_NOT_CANCELABLE =
'';
54 const ATOMIC_CANCELABLE =
'cancelable';
57 const FLUSHING_ONE =
'';
59 const FLUSHING_ALL_PEERS =
'flush';
61 const FLUSHING_INTERNAL =
'flush-internal';
64 const REMEMBER_NOTHING =
'';
66 const REMEMBER_PRIOR =
'remember';
68 const RESTORE_PRIOR =
'prior';
70 const RESTORE_INITIAL =
'initial';
73 const ESTIMATE_TOTAL =
'total';
75 const ESTIMATE_DB_APPLY =
'apply';
187 public function dbSchema( $schema =
null );
325 public function setFlag( $flag, $remember = self::REMEMBER_NOTHING );
339 public function clearFlag( $flag, $remember = self::REMEMBER_NOTHING );
347 public function restoreFlags( $state = self::RESTORE_PRIOR );
359 public function getFlag( $flag );
508 public function close();
536 public function query( $sql,
$fname = __METHOD__, $tempIgnore =
false );
567 $table, $var, $cond =
'',
$fname = __METHOD__,
$options = [], $join_conds = []
591 $table, $var, $cond =
'',
$fname = __METHOD__,
$options = [], $join_conds = []
829 $table, $var =
'*', $conds =
'',
$fname = __METHOD__,
$options = [], $join_conds = []
866 $table, $conds =
'',
$fname = __METHOD__,
$options = [], $join_conds = []
1009 public function aggregateValue( $valuedata, $valuename =
'value' );
1015 public function bitNot( $field );
1022 public function bitAnd( $fieldLeft, $fieldRight );
1029 public function bitOr( $fieldLeft, $fieldRight );
1056 $delim, $table, $field, $conds =
'', $join_conds = []
1301 public function deleteJoin( $delTable, $joinTable, $delVar, $joinVar, $conds,
1316 public function delete( $table, $conds,
$fname = __METHOD__ );
1354 public function insertSelect( $destTable, $srcTable, $varMap, $conds,
1356 $insertOptions = [], $selectOptions = [], $selectJoinConds = []
1403 $table,
$vars,
array $permute_conds, $extra_conds =
'',
$fname = __METHOD__,
1416 public function conditional( $cond, $trueVal, $falseVal );
1428 public function strreplace( $orig, $old, $new );
1701 public function startAtomic(
$fname = __METHOD__, $cancelable = self::ATOMIC_NOT_CANCELABLE );
1816 $fname, callable $callback, $cancelable = self::ATOMIC_NOT_CANCELABLE
1839 public function begin(
$fname = __METHOD__, $mode = self::TRANSACTION_EXPLICIT );
1861 public function commit(
$fname = __METHOD__, $flush =
'' );
1933 public function ping( &$rtt =
null );
1943 public function getLag();
2020 public function lockIsFree( $lockName, $method );
2033 public function lock( $lockName, $method, $timeout = 5 );
2049 public function unlock( $lockName, $method );
2106 public function decodeExpiry( $expiry, $format = TS_MW );
this hook is for auditing only RecentChangesLinked and Watchlist Do not use this to implement individual filters if they are compatible with the ChangesListFilter and ChangesListFilterGroup structure use sub classes of those in conjunction with the ChangesListSpecialPageStructuredFilters hook This hook can be used to implement filters that do not implement that or custom behavior that is not an individual filter e g Watchlist & $tables
injection txt This is an overview of how MediaWiki makes use of dependency injection The design described here grew from the discussion of RFC T384 The term dependency this means that anything an object needs to operate should be injected from the the object itself should only know narrow no concrete implementation of the logic it relies on The requirement to inject everything typically results in an architecture that based on two main types of and essentially stateless service objects that use other service objects to operate on the value objects As of the beginning MediaWiki is only starting to use the DI approach Much of the code still relies on global state or direct resulting in a highly cyclical dependency which acts as the top level factory for services in MediaWiki which can be used to gain access to default instances of various services MediaWikiServices however also allows new services to be defined and default services to be redefined Services are defined or redefined by providing a callback the instantiator that will return a new instance of the service When it will create an instance of MediaWikiServices and populate it with the services defined in the files listed by thereby bootstrapping the DI framework Per $wgServiceWiringFiles lists includes ServiceWiring php
if(is_array( $mode)) switch( $mode) $input
as see the revision history and available at free of to any person obtaining a copy of this software and associated documentation to deal in the Software without including without limitation the rights to use
static configuration should be added through ResourceLoaderGetConfigVars instead & $vars
The wiki should then use memcached to cache various data To use multiple just add more items to the array To increase the weight of a make its entry a array("192.168.0.1:11211", 2))
if(defined( 'MW_SETUP_CALLBACK')) $fname
Customization point after all loading (constants, functions, classes, DefaultSettings,...
Allows to change the fields on the form that will be generated $name
do that in ParserLimitReportFormat instead use this to modify the parameters of the image all existing parser cache entries will be invalid To avoid you ll need to handle that somehow(e.g. with the RejectParserCacheValue hook) because MediaWiki won 't do it for you. & $defaults also a ContextSource after deleting those rows but within the same transaction $rows
null means default in associative array with keys and values unescaped Should be merged with default with a value of false meaning to suppress the attribute in associative array with keys and values unescaped & $options
you have access to all of the normal MediaWiki so you can get a DB use the etc For full docs on the Maintenance class