mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Scribunto
synced 2024-11-28 02:00:01 +00:00
Merge "Use public instead of var in classes"
This commit is contained in:
commit
13c590892b
|
@ -266,9 +266,9 @@ abstract class ScribuntoModuleBase {
|
||||||
/**
|
/**
|
||||||
* @var ScribuntoEngineBase
|
* @var ScribuntoEngineBase
|
||||||
*/
|
*/
|
||||||
var $engine;
|
public $engine;
|
||||||
|
|
||||||
var $code, $chunkName;
|
public $code, $chunkName;
|
||||||
|
|
||||||
public function __construct( $engine, $code, $chunkName ) {
|
public function __construct( $engine, $code, $chunkName ) {
|
||||||
$this->engine = $engine;
|
$this->engine = $engine;
|
||||||
|
|
|
@ -117,7 +117,7 @@ class Scribunto {
|
||||||
* normally abort the request, instead it is caught and shown to the user.
|
* normally abort the request, instead it is caught and shown to the user.
|
||||||
*/
|
*/
|
||||||
class ScribuntoException extends MWException {
|
class ScribuntoException extends MWException {
|
||||||
var $messageName, $messageArgs, $params;
|
public $messageName, $messageArgs, $params;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param $messageName string
|
* @param $messageName string
|
||||||
|
|
|
@ -3,8 +3,8 @@
|
||||||
class Scribunto_LuaLanguageLibrary extends Scribunto_LuaLibraryBase {
|
class Scribunto_LuaLanguageLibrary extends Scribunto_LuaLibraryBase {
|
||||||
const MAX_LANG_CACHE_SIZE = 20;
|
const MAX_LANG_CACHE_SIZE = 20;
|
||||||
|
|
||||||
var $langCache = array();
|
public $langCache = array();
|
||||||
var $timeCache = array();
|
public $timeCache = array();
|
||||||
|
|
||||||
function register() {
|
function register() {
|
||||||
// Pre-populate the language cache
|
// Pre-populate the language cache
|
||||||
|
|
|
@ -791,7 +791,7 @@ class Scribunto_LuaModule extends ScribuntoModuleBase {
|
||||||
}
|
}
|
||||||
|
|
||||||
class Scribunto_LuaError extends ScribuntoException {
|
class Scribunto_LuaError extends ScribuntoException {
|
||||||
var $luaMessage, $lineMap = array();
|
public $luaMessage, $lineMap = array();
|
||||||
|
|
||||||
function __construct( $message, $options = array() ) {
|
function __construct( $message, $options = array() ) {
|
||||||
$this->luaMessage = $message;
|
$this->luaMessage = $message;
|
||||||
|
|
|
@ -209,7 +209,7 @@ class Scribunto_LuaSandboxEngine extends Scribunto_LuaEngine {
|
||||||
}
|
}
|
||||||
|
|
||||||
class Scribunto_LuaSandboxInterpreter extends Scribunto_LuaInterpreter {
|
class Scribunto_LuaSandboxInterpreter extends Scribunto_LuaInterpreter {
|
||||||
var $engine, $sandbox, $libraries, $profilerEnabled;
|
public $engine, $sandbox, $libraries, $profilerEnabled;
|
||||||
|
|
||||||
const SAMPLES = 0;
|
const SAMPLES = 0;
|
||||||
const SECONDS = 1;
|
const SECONDS = 1;
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
class Scribunto_LuaStandaloneEngine extends Scribunto_LuaEngine {
|
class Scribunto_LuaStandaloneEngine extends Scribunto_LuaEngine {
|
||||||
static $clockTick;
|
static $clockTick;
|
||||||
var $initialStatus;
|
public $initialStatus;
|
||||||
|
|
||||||
public function load() {
|
public function load() {
|
||||||
parent::load();
|
parent::load();
|
||||||
|
@ -128,7 +128,7 @@ class Scribunto_LuaStandaloneEngine extends Scribunto_LuaEngine {
|
||||||
|
|
||||||
class Scribunto_LuaStandaloneInterpreter extends Scribunto_LuaInterpreter {
|
class Scribunto_LuaStandaloneInterpreter extends Scribunto_LuaInterpreter {
|
||||||
static $nextInterpreterId = 0;
|
static $nextInterpreterId = 0;
|
||||||
var $engine, $enableDebug, $proc, $writePipe, $readPipe, $exitError, $id;
|
public $engine, $enableDebug, $proc, $writePipe, $readPipe, $exitError, $id;
|
||||||
|
|
||||||
function __construct( $engine, $options ) {
|
function __construct( $engine, $options ) {
|
||||||
$this->id = self::$nextInterpreterId++;
|
$this->id = self::$nextInterpreterId++;
|
||||||
|
|
|
@ -6,12 +6,12 @@
|
||||||
* @group LuaStandalone
|
* @group LuaStandalone
|
||||||
*/
|
*/
|
||||||
class Scribunto_LuaEnvironmentComparisonTest extends MediaWikiTestCase {
|
class Scribunto_LuaEnvironmentComparisonTest extends MediaWikiTestCase {
|
||||||
var $sandboxOpts = array(
|
public $sandboxOpts = array(
|
||||||
'memoryLimit' => 50000000,
|
'memoryLimit' => 50000000,
|
||||||
'cpuLimit' => 30,
|
'cpuLimit' => 30,
|
||||||
'allowEnvFuncs' => true,
|
'allowEnvFuncs' => true,
|
||||||
);
|
);
|
||||||
var $standaloneOpts = array(
|
public $standaloneOpts = array(
|
||||||
'errorFile' => null,
|
'errorFile' => null,
|
||||||
'luaPath' => null,
|
'luaPath' => null,
|
||||||
'memoryLimit' => 50000000,
|
'memoryLimit' => 50000000,
|
||||||
|
|
|
@ -8,7 +8,7 @@ require_once( dirname( __FILE__ ) .'/../LuaCommon/LuaInterpreterTest.php' );
|
||||||
* @group LuaSandbox
|
* @group LuaSandbox
|
||||||
*/
|
*/
|
||||||
class Scribunto_LuaSandboxInterpreterTest extends Scribunto_LuaInterpreterTest {
|
class Scribunto_LuaSandboxInterpreterTest extends Scribunto_LuaInterpreterTest {
|
||||||
var $stdOpts = array(
|
public $stdOpts = array(
|
||||||
'memoryLimit' => 50000000,
|
'memoryLimit' => 50000000,
|
||||||
'cpuLimit' => 30,
|
'cpuLimit' => 30,
|
||||||
);
|
);
|
||||||
|
|
|
@ -8,7 +8,7 @@ require_once( dirname( __FILE__ ) .'/../LuaCommon/LuaInterpreterTest.php' );
|
||||||
* @group LuaStandalone
|
* @group LuaStandalone
|
||||||
*/
|
*/
|
||||||
class Scribunto_LuaStandaloneInterpreterTest extends Scribunto_LuaInterpreterTest {
|
class Scribunto_LuaStandaloneInterpreterTest extends Scribunto_LuaInterpreterTest {
|
||||||
var $stdOpts = array(
|
public $stdOpts = array(
|
||||||
'errorFile' => null,
|
'errorFile' => null,
|
||||||
'luaPath' => null,
|
'luaPath' => null,
|
||||||
'memoryLimit' => 50000000,
|
'memoryLimit' => 50000000,
|
||||||
|
|
Loading…
Reference in a new issue