16 |
17 |
18 | More Information
19 | ----------------
20 |
21 | Read the `documentation`_ for more information.
22 |
23 | .. _documentation: https://twig.symfony.com/documentation
24 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/Test/NullTest.php:
--------------------------------------------------------------------------------
1 |
23 | */
24 | class NullTest extends TestExpression
25 | {
26 | public function compile(Compiler $compiler): void
27 | {
28 | $compiler
29 | ->raw('(null === ')
30 | ->subcompile($this->getNode('node'))
31 | ->raw(')')
32 | ;
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/Test/OddTest.php:
--------------------------------------------------------------------------------
1 |
23 | */
24 | class OddTest extends TestExpression
25 | {
26 | public function compile(Compiler $compiler): void
27 | {
28 | $compiler
29 | ->raw('(')
30 | ->subcompile($this->getNode('node'))
31 | ->raw(' % 2 != 0')
32 | ->raw(')')
33 | ;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/Binary/RangeBinary.php:
--------------------------------------------------------------------------------
1 | raw('range(')
22 | ->subcompile($this->getNode('left'))
23 | ->raw(', ')
24 | ->subcompile($this->getNode('right'))
25 | ->raw(')')
26 | ;
27 | }
28 |
29 | public function operator(Compiler $compiler): Compiler
30 | {
31 | return $compiler->raw('..');
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/Test/EvenTest.php:
--------------------------------------------------------------------------------
1 |
23 | */
24 | class EvenTest extends TestExpression
25 | {
26 | public function compile(Compiler $compiler): void
27 | {
28 | $compiler
29 | ->raw('(')
30 | ->subcompile($this->getNode('node'))
31 | ->raw(' % 2 == 0')
32 | ->raw(')')
33 | ;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Sandbox/SecurityNotAllowedTagError.php:
--------------------------------------------------------------------------------
1 |
18 | */
19 | final class SecurityNotAllowedTagError extends SecurityError
20 | {
21 | private string $tagName;
22 |
23 | public function __construct(string $message, string $tagName)
24 | {
25 | parent::__construct($message);
26 | $this->tagName = $tagName;
27 | }
28 |
29 | public function getTagName(): string
30 | {
31 | return $this->tagName;
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/vendor/autoload.php:
--------------------------------------------------------------------------------
1 |
7 | *
8 | * For the full copyright and license information, please view the LICENSE
9 | * file that was distributed with this source code.
10 | */
11 |
12 | use Symfony\Polyfill\Php81 as p;
13 |
14 | if (\PHP_VERSION_ID >= 80100) {
15 | return;
16 | }
17 |
18 | if (defined('MYSQLI_REFRESH_SLAVE') && !defined('MYSQLI_REFRESH_REPLICA')) {
19 | define('MYSQLI_REFRESH_REPLICA', 64);
20 | }
21 |
22 | if (!function_exists('array_is_list')) {
23 | function array_is_list(array $array): bool { return p\Php81::array_is_list($array); }
24 | }
25 |
26 | if (!function_exists('enum_exists')) {
27 | function enum_exists(string $enum, bool $autoload = true): bool { return $autoload && class_exists($enum) && false; }
28 | }
29 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/Binary/InBinary.php:
--------------------------------------------------------------------------------
1 | raw('CoreExtension::inFilter(')
22 | ->subcompile($this->getNode('left'))
23 | ->raw(', ')
24 | ->subcompile($this->getNode('right'))
25 | ->raw(')')
26 | ;
27 | }
28 |
29 | public function operator(Compiler $compiler): Compiler
30 | {
31 | return $compiler->raw('in');
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/TokenParser/FlushTokenParser.php:
--------------------------------------------------------------------------------
1 | parser->getStream()->expect(Token::BLOCK_END_TYPE);
30 |
31 | return new FlushNode($token->getLine());
32 | }
33 |
34 | public function getTag(): string
35 | {
36 | return 'flush';
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/Binary/NotInBinary.php:
--------------------------------------------------------------------------------
1 | raw('!CoreExtension::inFilter(')
22 | ->subcompile($this->getNode('left'))
23 | ->raw(', ')
24 | ->subcompile($this->getNode('right'))
25 | ->raw(')')
26 | ;
27 | }
28 |
29 | public function operator(Compiler $compiler): Compiler
30 | {
31 | return $compiler->raw('not in');
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/vendor/symfony/polyfill-php81/Php81.php:
--------------------------------------------------------------------------------
1 |
7 | *
8 | * For the full copyright and license information, please view the LICENSE
9 | * file that was distributed with this source code.
10 | */
11 |
12 | namespace Symfony\Polyfill\Php81;
13 |
14 | /**
15 | * @author Nicolas Grekas
16 | *
17 | * @internal
18 | */
19 | final class Php81
20 | {
21 | public static function array_is_list(array $array): bool
22 | {
23 | if ([] === $array || $array === array_values($array)) {
24 | return true;
25 | }
26 |
27 | $nextKey = -1;
28 |
29 | foreach ($array as $k => $v) {
30 | if ($k !== ++$nextKey) {
31 | return false;
32 | }
33 | }
34 |
35 | return true;
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/Binary/HasSomeBinary.php:
--------------------------------------------------------------------------------
1 | raw('CoreExtension::arraySome($this->env, ')
22 | ->subcompile($this->getNode('left'))
23 | ->raw(', ')
24 | ->subcompile($this->getNode('right'))
25 | ->raw(')')
26 | ;
27 | }
28 |
29 | public function operator(Compiler $compiler): Compiler
30 | {
31 | return $compiler->raw('');
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Sandbox/SecurityNotAllowedFilterError.php:
--------------------------------------------------------------------------------
1 |
18 | */
19 | final class SecurityNotAllowedFilterError extends SecurityError
20 | {
21 | private string $filterName;
22 |
23 | public function __construct(string $message, string $functionName)
24 | {
25 | parent::__construct($message);
26 | $this->filterName = $functionName;
27 | }
28 |
29 | public function getFilterName(): string
30 | {
31 | return $this->filterName;
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/Binary/HasEveryBinary.php:
--------------------------------------------------------------------------------
1 | raw('CoreExtension::arrayEvery($this->env, ')
22 | ->subcompile($this->getNode('left'))
23 | ->raw(', ')
24 | ->subcompile($this->getNode('right'))
25 | ->raw(')')
26 | ;
27 | }
28 |
29 | public function operator(Compiler $compiler): Compiler
30 | {
31 | return $compiler->raw('');
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Sandbox/SecurityNotAllowedFunctionError.php:
--------------------------------------------------------------------------------
1 |
18 | */
19 | final class SecurityNotAllowedFunctionError extends SecurityError
20 | {
21 | private string $functionName;
22 |
23 | public function __construct(string $message, string $functionName)
24 | {
25 | parent::__construct($message);
26 | $this->functionName = $functionName;
27 | }
28 |
29 | public function getFunctionName(): string
30 | {
31 | return $this->functionName;
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | nbproject
2 | TopLogs
3 | .html
4 | loadtestingresults.ods
5 | /MoodleBook/makemoodlebook.py
6 | gh-md-toc
7 | moodlebook.zip
8 | /makemoodlebook.py
9 | /MoodleBook/
10 | /Screendumps/
11 | Readme.md.*
12 | /tests/fixtures/test-sandbox-config.php
13 | /LocalStuff/
14 | /Preloading/selenium-server-standalone-2.53.0.jar
15 | /selenium-server-standalone-2.53.0.jar
16 | /selenium-server-standalone-3.0.1.jar
17 | striptrailingwhitespace.py
18 | excludesfromstylechecker.txt
19 | miscsqlqueries
20 | moodleopenshift.md
21 | dbquerieswhilefixingbug.sql
22 | /questions-moodle-Questions for export-20171106-1418.xml
23 | /twighacking.php
24 | NonRepoFiles/*
25 | /amd/src/blockly/
26 | /amd/build/blockly/
27 | /amd/build/bak/
28 | /amd/build/ui_blockly.min.js
29 | /amd/build/ui_blockly.min.js.map
30 | /amd/src/partiallyupdatedgraph/
31 | /amd/src/ui_blockly.js
32 | /amd/src/ui_blockly.json
33 | /amd/src/.eslintrc.js
34 | .grunt
35 | .vscode/
36 |
--------------------------------------------------------------------------------
/ace/snippets/drools.js:
--------------------------------------------------------------------------------
1 | ace.define("ace/snippets/drools",["require","exports","module"], function(require, exports, module) {
2 | "use strict";
3 |
4 | exports.snippetText = "\n\
5 | snippet rule\n\
6 | rule \"${1?:rule_name}\"\n\
7 | when\n\
8 | ${2:// when...} \n\
9 | then\n\
10 | ${3:// then...}\n\
11 | end\n\
12 | \n\
13 | snippet query\n\
14 | query ${1?:query_name}\n\
15 | ${2:// find} \n\
16 | end\n\
17 | \n\
18 | snippet declare\n\
19 | declare ${1?:type_name}\n\
20 | ${2:// attributes} \n\
21 | end\n\
22 | \n\
23 | ";
24 | exports.scope = "drools";
25 |
26 | }); (function() {
27 | ace.require(["ace/snippets/drools"], function(m) {
28 | if (typeof module == "object" && typeof exports == "object" && module) {
29 | module.exports = m;
30 | }
31 | });
32 | })();
33 |
--------------------------------------------------------------------------------
/pix/fullscreen.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
23 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/Test/SameasTest.php:
--------------------------------------------------------------------------------
1 |
21 | */
22 | class SameasTest extends TestExpression
23 | {
24 | public function compile(Compiler $compiler): void
25 | {
26 | $compiler
27 | ->raw('(')
28 | ->subcompile($this->getNode('node'))
29 | ->raw(' === ')
30 | ->subcompile($this->getNode('arguments')->getNode('0'))
31 | ->raw(')')
32 | ;
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/pix/windowed.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
23 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/TokenParser/DoTokenParser.php:
--------------------------------------------------------------------------------
1 | parser->getExpressionParser()->parseExpression();
28 |
29 | $this->parser->getStream()->expect(Token::BLOCK_END_TYPE);
30 |
31 | return new DoNode($expr, $token->getLine());
32 | }
33 |
34 | public function getTag(): string
35 | {
36 | return 'do';
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/FlushNode.php:
--------------------------------------------------------------------------------
1 |
21 | */
22 | #[YieldReady]
23 | class FlushNode extends Node
24 | {
25 | public function __construct(int $lineno)
26 | {
27 | parent::__construct([], [], $lineno);
28 | }
29 |
30 | public function compile(Compiler $compiler): void
31 | {
32 | $compiler->addDebugInfo($this);
33 |
34 | if ($compiler->getEnvironment()->useYield()) {
35 | $compiler->write("yield '';\n");
36 | }
37 |
38 | $compiler->write("flush();\n");
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/vendor/composer/autoload_files.php:
--------------------------------------------------------------------------------
1 | $vendorDir . '/symfony/deprecation-contracts/function.php',
10 | '320cde22f66dd4f5d3fd621d3e88b98f' => $vendorDir . '/symfony/polyfill-ctype/bootstrap.php',
11 | '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => $vendorDir . '/symfony/polyfill-mbstring/bootstrap.php',
12 | '23c18046f52bef3eea034657bafda50f' => $vendorDir . '/symfony/polyfill-php81/bootstrap.php',
13 | '89efb1254ef2d1c5d80096acd12c4098' => $vendorDir . '/twig/twig/src/Resources/core.php',
14 | 'ffecb95d45175fd40f75be8a23b34f90' => $vendorDir . '/twig/twig/src/Resources/debug.php',
15 | 'c7baa00073ee9c61edf148c51917cfb4' => $vendorDir . '/twig/twig/src/Resources/escaper.php',
16 | 'f844ccf1d25df8663951193c3fc307c8' => $vendorDir . '/twig/twig/src/Resources/string_loader.php',
17 | );
18 |
--------------------------------------------------------------------------------
/classes/bad_json_exception.php:
--------------------------------------------------------------------------------
1 | .
16 |
17 | /**
18 | * Library routines for qtype_coderunner
19 | */
20 |
21 | /* The class for an exception when bad json passed to util::template_params */
22 | class qtype_coderunner_bad_json_exception extends Exception {
23 | }
24 |
--------------------------------------------------------------------------------
/db/install.php:
--------------------------------------------------------------------------------
1 | .
16 |
17 | /**
18 | * Extra install code for the CodeRunner question type.
19 | */
20 |
21 | function xmldb_qtype_coderunner_install() {
22 | require_once(__DIR__ . '/upgradelib.php');
23 | update_question_types();
24 | }
25 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/Test/DivisiblebyTest.php:
--------------------------------------------------------------------------------
1 |
23 | */
24 | class DivisiblebyTest extends TestExpression
25 | {
26 | public function compile(Compiler $compiler): void
27 | {
28 | $compiler
29 | ->raw('(0 == ')
30 | ->subcompile($this->getNode('node'))
31 | ->raw(' % ')
32 | ->subcompile($this->getNode('arguments')->getNode('0'))
33 | ->raw(')')
34 | ;
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/OperatorPrecedenceChange.php:
--------------------------------------------------------------------------------
1 |
18 | */
19 | class OperatorPrecedenceChange
20 | {
21 | public function __construct(
22 | private string $package,
23 | private string $version,
24 | private int $newPrecedence,
25 | ) {
26 | }
27 |
28 | public function getPackage(): string
29 | {
30 | return $this->package;
31 | }
32 |
33 | public function getVersion(): string
34 | {
35 | return $this->version;
36 | }
37 |
38 | public function getNewPrecedence(): int
39 | {
40 | return $this->newPrecedence;
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Cache/NullCache.php:
--------------------------------------------------------------------------------
1 |
18 | */
19 | final class NullCache implements CacheInterface, RemovableCacheInterface
20 | {
21 | public function generateKey(string $name, string $className): string
22 | {
23 | return '';
24 | }
25 |
26 | public function write(string $key, string $content): void
27 | {
28 | }
29 |
30 | public function load(string $key): void
31 | {
32 | }
33 |
34 | public function getTimestamp(string $key): int
35 | {
36 | return 0;
37 | }
38 |
39 | public function remove(string $name, string $cls): void
40 | {
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/ace/snippets/haml.js:
--------------------------------------------------------------------------------
1 | ace.define("ace/snippets/haml",["require","exports","module"], function(require, exports, module) {
2 | "use strict";
3 |
4 | exports.snippetText = "snippet t\n\
5 | %table\n\
6 | %tr\n\
7 | %th\n\
8 | ${1:headers}\n\
9 | %tr\n\
10 | %td\n\
11 | ${2:headers}\n\
12 | snippet ul\n\
13 | %ul\n\
14 | %li\n\
15 | ${1:item}\n\
16 | %li\n\
17 | snippet =rp\n\
18 | = render :partial => '${1:partial}'\n\
19 | snippet =rpl\n\
20 | = render :partial => '${1:partial}', :locals => {}\n\
21 | snippet =rpc\n\
22 | = render :partial => '${1:partial}', :collection => @$1\n\
23 | \n\
24 | ";
25 | exports.scope = "haml";
26 |
27 | }); (function() {
28 | ace.require(["ace/snippets/haml"], function(m) {
29 | if (typeof module == "object" && typeof exports == "object" && module) {
30 | module.exports = m;
31 | }
32 | });
33 | })();
34 |
--------------------------------------------------------------------------------
/ace/snippets/rst.js:
--------------------------------------------------------------------------------
1 | ace.define("ace/snippets/rst",["require","exports","module"], function(require, exports, module) {
2 | "use strict";
3 |
4 | exports.snippetText = "# rst\n\
5 | \n\
6 | snippet :\n\
7 | :${1:field name}: ${2:field body}\n\
8 | snippet *\n\
9 | *${1:Emphasis}*\n\
10 | snippet **\n\
11 | **${1:Strong emphasis}**\n\
12 | snippet _\n\
13 | \\`${1:hyperlink-name}\\`_\n\
14 | .. _\\`$1\\`: ${2:link-block}\n\
15 | snippet =\n\
16 | ${1:Title}\n\
17 | =====${2:=}\n\
18 | ${3}\n\
19 | snippet -\n\
20 | ${1:Title}\n\
21 | -----${2:-}\n\
22 | ${3}\n\
23 | snippet cont:\n\
24 | .. contents::\n\
25 | \n\
26 | ";
27 | exports.scope = "rst";
28 |
29 | }); (function() {
30 | ace.require(["ace/snippets/rst"], function(m) {
31 | if (typeof module == "object" && typeof exports == "object" && module) {
32 | module.exports = m;
33 | }
34 | });
35 | })();
36 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/DoNode.php:
--------------------------------------------------------------------------------
1 |
22 | */
23 | #[YieldReady]
24 | class DoNode extends Node
25 | {
26 | public function __construct(AbstractExpression $expr, int $lineno)
27 | {
28 | parent::__construct(['expr' => $expr], [], $lineno);
29 | }
30 |
31 | public function compile(Compiler $compiler): void
32 | {
33 | $compiler
34 | ->addDebugInfo($this)
35 | ->write('')
36 | ->subcompile($this->getNode('expr'))
37 | ->raw(";\n")
38 | ;
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/vendor/symfony/deprecation-contracts/composer.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "symfony/deprecation-contracts",
3 | "type": "library",
4 | "description": "A generic function and convention to trigger deprecation notices",
5 | "homepage": "https://symfony.com",
6 | "license": "MIT",
7 | "authors": [
8 | {
9 | "name": "Nicolas Grekas",
10 | "email": "p@tchwork.com"
11 | },
12 | {
13 | "name": "Symfony Community",
14 | "homepage": "https://symfony.com/contributors"
15 | }
16 | ],
17 | "require": {
18 | "php": ">=8.1"
19 | },
20 | "autoload": {
21 | "files": [
22 | "function.php"
23 | ]
24 | },
25 | "minimum-stability": "dev",
26 | "extra": {
27 | "branch-alias": {
28 | "dev-main": "3.6-dev"
29 | },
30 | "thanks": {
31 | "name": "symfony/contracts",
32 | "url": "https://github.com/symfony/contracts"
33 | }
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/RuntimeLoader/ContainerRuntimeLoader.php:
--------------------------------------------------------------------------------
1 |
22 | * @author Robin Chalas
22 | */
23 | function trigger_deprecation(string $package, string $version, string $message, mixed ...$args): void
24 | {
25 | @trigger_error(($package || $version ? "Since $package $version: " : '').($args ? vsprintf($message, $args) : $message), \E_USER_DEPRECATED);
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/vendor/symfony/polyfill-ctype/LICENSE:
--------------------------------------------------------------------------------
1 | Copyright (c) 2018-present Fabien Potencier
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy
4 | of this software and associated documentation files (the "Software"), to deal
5 | in the Software without restriction, including without limitation the rights
6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 | copies of the Software, and to permit persons to whom the Software is furnished
8 | to do so, subject to the following conditions:
9 |
10 | The above copyright notice and this permission notice shall be included in all
11 | copies or substantial portions of the Software.
12 |
13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19 | THE SOFTWARE.
20 |
--------------------------------------------------------------------------------
/vendor/symfony/polyfill-php81/LICENSE:
--------------------------------------------------------------------------------
1 | Copyright (c) 2021-present Fabien Potencier
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy
4 | of this software and associated documentation files (the "Software"), to deal
5 | in the Software without restriction, including without limitation the rights
6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 | copies of the Software, and to permit persons to whom the Software is furnished
8 | to do so, subject to the following conditions:
9 |
10 | The above copyright notice and this permission notice shall be included in all
11 | copies or substantial portions of the Software.
12 |
13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19 | THE SOFTWARE.
20 |
--------------------------------------------------------------------------------
/vendor/symfony/deprecation-contracts/LICENSE:
--------------------------------------------------------------------------------
1 | Copyright (c) 2020-present Fabien Potencier
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy
4 | of this software and associated documentation files (the "Software"), to deal
5 | in the Software without restriction, including without limitation the rights
6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 | copies of the Software, and to permit persons to whom the Software is furnished
8 | to do so, subject to the following conditions:
9 |
10 | The above copyright notice and this permission notice shall be included in all
11 | copies or substantial portions of the Software.
12 |
13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19 | THE SOFTWARE.
20 |
--------------------------------------------------------------------------------
/vendor/symfony/polyfill-mbstring/LICENSE:
--------------------------------------------------------------------------------
1 | Copyright (c) 2015-present Fabien Potencier
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy
4 | of this software and associated documentation files (the "Software"), to deal
5 | in the Software without restriction, including without limitation the rights
6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 | copies of the Software, and to permit persons to whom the Software is furnished
8 | to do so, subject to the following conditions:
9 |
10 | The above copyright notice and this permission notice shall be included in all
11 | copies or substantial portions of the Software.
12 |
13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19 | THE SOFTWARE.
20 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/AbstractExpression.php:
--------------------------------------------------------------------------------
1 |
21 | */
22 | abstract class AbstractExpression extends Node
23 | {
24 | public function isGenerator(): bool
25 | {
26 | return $this->hasAttribute('is_generator') && $this->getAttribute('is_generator');
27 | }
28 |
29 | /**
30 | * @return static
31 | */
32 | public function setExplicitParentheses(): self
33 | {
34 | $this->setAttribute('with_parentheses', true);
35 |
36 | return $this;
37 | }
38 |
39 | public function hasExplicitParentheses(): bool
40 | {
41 | return $this->hasAttribute('with_parentheses') && $this->getAttribute('with_parentheses');
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/ace/snippets/textile.js:
--------------------------------------------------------------------------------
1 | ace.define("ace/snippets/textile",["require","exports","module"], function(require, exports, module) {
2 | "use strict";
3 |
4 | exports.snippetText = "# Jekyll post header\n\
5 | snippet header\n\
6 | ---\n\
7 | title: ${1:title}\n\
8 | layout: post\n\
9 | date: ${2:date} ${3:hour:minute:second} -05:00\n\
10 | ---\n\
11 | \n\
12 | # Image\n\
13 | snippet img\n\
14 | !${1:url}(${2:title}):${3:link}!\n\
15 | \n\
16 | # Table\n\
17 | snippet |\n\
18 | |${1}|${2}\n\
19 | \n\
20 | # Link\n\
21 | snippet link\n\
22 | \"${1:link text}\":${2:url}\n\
23 | \n\
24 | # Acronym\n\
25 | snippet (\n\
26 | (${1:Expand acronym})${2}\n\
27 | \n\
28 | # Footnote\n\
29 | snippet fn\n\
30 | [${1:ref number}] ${3}\n\
31 | \n\
32 | fn$1. ${2:footnote}\n\
33 | \n\
34 | ";
35 | exports.scope = "textile";
36 |
37 | }); (function() {
38 | ace.require(["ace/snippets/textile"], function(m) {
39 | if (typeof module == "object" && typeof exports == "object" && module) {
40 | module.exports = m;
41 | }
42 | });
43 | })();
44 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/Expression/Variable/TemplateVariable.php:
--------------------------------------------------------------------------------
1 | getAttribute('name')) {
22 | $this->setAttribute('name', $compiler->getVarName());
23 | }
24 |
25 | return $this->getAttribute('name');
26 | }
27 |
28 | public function compile(Compiler $compiler): void
29 | {
30 | $name = $this->getName($compiler);
31 |
32 | if ('_self' === $name) {
33 | $compiler->raw('$this');
34 | } else {
35 | $compiler
36 | ->raw('$macros[')
37 | ->string($name)
38 | ->raw(']')
39 | ;
40 | }
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/vendor/symfony/polyfill-mbstring/composer.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "symfony/polyfill-mbstring",
3 | "type": "library",
4 | "description": "Symfony polyfill for the Mbstring extension",
5 | "keywords": ["polyfill", "shim", "compatibility", "portable", "mbstring"],
6 | "homepage": "https://symfony.com",
7 | "license": "MIT",
8 | "authors": [
9 | {
10 | "name": "Nicolas Grekas",
11 | "email": "p@tchwork.com"
12 | },
13 | {
14 | "name": "Symfony Community",
15 | "homepage": "https://symfony.com/contributors"
16 | }
17 | ],
18 | "require": {
19 | "php": ">=7.2",
20 | "ext-iconv": "*"
21 | },
22 | "provide": {
23 | "ext-mbstring": "*"
24 | },
25 | "autoload": {
26 | "psr-4": { "Symfony\\Polyfill\\Mbstring\\": "" },
27 | "files": [ "bootstrap.php" ]
28 | },
29 | "suggest": {
30 | "ext-mbstring": "For best performance"
31 | },
32 | "minimum-stability": "dev",
33 | "extra": {
34 | "thanks": {
35 | "name": "symfony/polyfill",
36 | "url": "https://github.com/symfony/polyfill"
37 | }
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/ace/mode-plain_text.js:
--------------------------------------------------------------------------------
1 | ace.define("ace/mode/plain_text",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/text_highlight_rules","ace/mode/behaviour"], function(require, exports, module) {
2 | "use strict";
3 |
4 | var oop = require("../lib/oop");
5 | var TextMode = require("./text").Mode;
6 | var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
7 | var Behaviour = require("./behaviour").Behaviour;
8 |
9 | var Mode = function() {
10 | this.HighlightRules = TextHighlightRules;
11 | this.$behaviour = new Behaviour();
12 | };
13 |
14 | oop.inherits(Mode, TextMode);
15 |
16 | (function() {
17 | this.type = "text";
18 | this.getNextLineIndent = function(state, line, tab) {
19 | return '';
20 | };
21 | this.$id = "ace/mode/plain_text";
22 | }).call(Mode.prototype);
23 |
24 | exports.Mode = Mode;
25 | }); (function() {
26 | ace.require(["ace/mode/plain_text"], function(m) {
27 | if (typeof module == "object" && typeof exports == "object" && module) {
28 | module.exports = m;
29 | }
30 | });
31 | })();
32 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Node/PrintNode.php:
--------------------------------------------------------------------------------
1 |
23 | */
24 | #[YieldReady]
25 | class PrintNode extends Node implements NodeOutputInterface
26 | {
27 | public function __construct(AbstractExpression $expr, int $lineno)
28 | {
29 | parent::__construct(['expr' => $expr], [], $lineno);
30 | }
31 |
32 | public function compile(Compiler $compiler): void
33 | {
34 | /** @var AbstractExpression */
35 | $expr = $this->getNode('expr');
36 |
37 | $compiler
38 | ->addDebugInfo($this)
39 | ->write($expr->isGenerator() ? 'yield from ' : 'yield ')
40 | ->subcompile($expr)
41 | ->raw(";\n")
42 | ;
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Sandbox/SecurityPolicyInterface.php:
--------------------------------------------------------------------------------
1 |
18 | */
19 | interface SecurityPolicyInterface
20 | {
21 | /**
22 | * @param string[] $tags
23 | * @param string[] $filters
24 | * @param string[] $functions
25 | *
26 | * @throws SecurityError
27 | */
28 | public function checkSecurity($tags, $filters, $functions): void;
29 |
30 | /**
31 | * @param object $obj
32 | * @param string $method
33 | *
34 | * @throws SecurityNotAllowedMethodError
35 | */
36 | public function checkMethodAllowed($obj, $method): void;
37 |
38 | /**
39 | * @param object $obj
40 | * @param string $property
41 | *
42 | * @throws SecurityNotAllowedPropertyError
43 | */
44 | public function checkPropertyAllowed($obj, $property): void;
45 | }
46 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Extension/StringLoaderExtension.php:
--------------------------------------------------------------------------------
1 | true]),
24 | ];
25 | }
26 |
27 | /**
28 | * Loads a template from a string.
29 | *
30 | * {{ include(template_from_string("Hello {{ name }}")) }}
31 | *
32 | * @param string|null $name An optional name of the template to be used in error messages
33 | *
34 | * @internal
35 | */
36 | public static function templateFromString(Environment $env, string|\Stringable $template, ?string $name = null): TemplateWrapper
37 | {
38 | return $env->createTemplate((string) $template, $name);
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/NodeVisitor/NodeVisitorInterface.php:
--------------------------------------------------------------------------------
1 |
21 | */
22 | interface NodeVisitorInterface
23 | {
24 | /**
25 | * Called before child nodes are visited.
26 | *
27 | * @return Node The modified node
28 | */
29 | public function enterNode(Node $node, Environment $env): Node;
30 |
31 | /**
32 | * Called after child nodes are visited.
33 | *
34 | * @return Node|null The modified node or null if the node must be removed
35 | */
36 | public function leaveNode(Node $node, Environment $env): ?Node;
37 |
38 | /**
39 | * Returns the priority for this visitor.
40 | *
41 | * Priority should be between -10 and 10 (0 is the default).
42 | *
43 | * @return int The priority level
44 | */
45 | public function getPriority();
46 | }
47 |
--------------------------------------------------------------------------------
/ace/snippets/velocity.js:
--------------------------------------------------------------------------------
1 | ace.define("ace/snippets/velocity",["require","exports","module"], function(require, exports, module) {
2 | "use strict";
3 |
4 | exports.snippetText = "# macro\n\
5 | snippet #macro\n\
6 | #macro ( ${1:macroName} ${2:\\$var1, [\\$var2, ...]} )\n\
7 | ${3:## macro code}\n\
8 | #end\n\
9 | # foreach\n\
10 | snippet #foreach\n\
11 | #foreach ( ${1:\\$item} in ${2:\\$collection} )\n\
12 | ${3:## foreach code}\n\
13 | #end\n\
14 | # if\n\
15 | snippet #if\n\
16 | #if ( ${1:true} )\n\
17 | ${0}\n\
18 | #end\n\
19 | # if ... else\n\
20 | snippet #ife\n\
21 | #if ( ${1:true} )\n\
22 | ${2}\n\
23 | #else\n\
24 | ${0}\n\
25 | #end\n\
26 | #import\n\
27 | snippet #import\n\
28 | #import ( \"${1:path/to/velocity/format}\" )\n\
29 | # set\n\
30 | snippet #set\n\
31 | #set ( $${1:var} = ${0} )\n\
32 | ";
33 | exports.scope = "velocity";
34 | exports.includeScopes = ["html", "javascript", "css"];
35 |
36 | }); (function() {
37 | ace.require(["ace/snippets/velocity"], function(m) {
38 | if (typeof module == "object" && typeof exports == "object" && module) {
39 | module.exports = m;
40 | }
41 | });
42 | })();
43 |
--------------------------------------------------------------------------------
/classes/exception.php:
--------------------------------------------------------------------------------
1 | .
16 |
17 | /**
18 | * Library routines for qtype_coderunner
19 | */
20 |
21 | /* The class for exceptions thrown in the coderunner plugin */
22 | class qtype_coderunner_exception extends moodle_exception {
23 | /**
24 | * @param string $errorcode exception description identifier
25 | * @param mixed $debuginfo debugging data to display
26 | */
27 | public function __construct($errorcode, $a = null, $debuginfo = null) {
28 | parent::__construct($errorcode, 'qtype_coderunner', '', $a, $debuginfo);
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/downloadquizattemptsanon.php:
--------------------------------------------------------------------------------
1 | .
16 |
17 | /**
18 | * This admin script is a variant of downloadquizattempts.php (q.v.) that
19 | * differs only in that the user name and email are replaced by a single
20 | * hashed_email field.
21 | *
22 | * @package qtype_coderunner
23 | * @copyright 2017 Richard Lobb, The University of Canterbury
24 | * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
25 | */
26 | defined('MOODLE_INTERNAL') || die();
27 |
28 | define('ANONYMISE', 1);
29 | require(__DIR__ . '/downloadquizattempts.php');
30 |
--------------------------------------------------------------------------------
/ace/snippets/graphqlschema.js:
--------------------------------------------------------------------------------
1 | ace.define("ace/snippets/graphqlschema",["require","exports","module"], function(require, exports, module) {
2 | "use strict";
3 |
4 | exports.snippetText = "# Type Snippet\n\
5 | trigger type\n\
6 | snippet type\n\
7 | type ${1:type_name} {\n\
8 | ${2:type_siblings}\n\
9 | }\n\
10 | \n\
11 | # Input Snippet\n\
12 | trigger input\n\
13 | snippet input\n\
14 | input ${1:input_name} {\n\
15 | ${2:input_siblings}\n\
16 | }\n\
17 | \n\
18 | # Interface Snippet\n\
19 | trigger interface\n\
20 | snippet interface\n\
21 | interface ${1:interface_name} {\n\
22 | ${2:interface_siblings}\n\
23 | }\n\
24 | \n\
25 | # Interface Snippet\n\
26 | trigger union\n\
27 | snippet union\n\
28 | union ${1:union_name} = ${2:type} | ${3: type}\n\
29 | \n\
30 | # Enum Snippet\n\
31 | trigger enum\n\
32 | snippet enum\n\
33 | enum ${1:enum_name} {\n\
34 | ${2:enum_siblings}\n\
35 | }\n\
36 | ";
37 | exports.scope = "graphqlschema";
38 |
39 | }); (function() {
40 | ace.require(["ace/snippets/graphqlschema"], function(m) {
41 | if (typeof module == "object" && typeof exports == "object" && module) {
42 | module.exports = m;
43 | }
44 | });
45 | })();
46 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Extension/ProfilerExtension.php:
--------------------------------------------------------------------------------
1 | actives[] = $profile;
24 | }
25 |
26 | /**
27 | * @return void
28 | */
29 | public function enter(Profile $profile)
30 | {
31 | $this->actives[0]->addProfile($profile);
32 | array_unshift($this->actives, $profile);
33 | }
34 |
35 | /**
36 | * @return void
37 | */
38 | public function leave(Profile $profile)
39 | {
40 | $profile->leave();
41 | array_shift($this->actives);
42 |
43 | if (1 === \count($this->actives)) {
44 | $this->actives[0]->leave();
45 | }
46 | }
47 |
48 | public function getNodeVisitors(): array
49 | {
50 | return [new ProfilerNodeVisitor(static::class)];
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/vendor/symfony/deprecation-contracts/README.md:
--------------------------------------------------------------------------------
1 | Symfony Deprecation Contracts
2 | =============================
3 |
4 | A generic function and convention to trigger deprecation notices.
5 |
6 | This package provides a single global function named `trigger_deprecation()` that triggers silenced deprecation notices.
7 |
8 | By using a custom PHP error handler such as the one provided by the Symfony ErrorHandler component,
9 | the triggered deprecations can be caught and logged for later discovery, both on dev and prod environments.
10 |
11 | The function requires at least 3 arguments:
12 | - the name of the Composer package that is triggering the deprecation
13 | - the version of the package that introduced the deprecation
14 | - the message of the deprecation
15 | - more arguments can be provided: they will be inserted in the message using `printf()` formatting
16 |
17 | Example:
18 | ```php
19 | trigger_deprecation('symfony/blockchain', '8.9', 'Using "%s" is deprecated, use "%s" instead.', 'bitcoin', 'fabcoin');
20 | ```
21 |
22 | This will generate the following message:
23 | `Since symfony/blockchain 8.9: Using "bitcoin" is deprecated, use "fabcoin" instead.`
24 |
25 | While not recommended, the deprecation notices can be completely ignored by declaring an empty
26 | `function trigger_deprecation() {}` in your application.
27 |
--------------------------------------------------------------------------------
/vendor/twig/twig/src/Markup.php:
--------------------------------------------------------------------------------
1 |
18 | */
19 | class Markup implements \Countable, \JsonSerializable, \Stringable
20 | {
21 | private $content;
22 | private ?string $charset;
23 |
24 | public function __construct($content, $charset)
25 | {
26 | $this->content = (string) $content;
27 | $this->charset = $charset;
28 | }
29 |
30 | public function __toString(): string
31 | {
32 | return $this->content;
33 | }
34 |
35 | public function getCharset(): string
36 | {
37 | return $this->charset;
38 | }
39 |
40 | /**
41 | * @return int
42 | */
43 | #[\ReturnTypeWillChange]
44 | public function count()
45 | {
46 | return mb_strlen($this->content, $this->charset);
47 | }
48 |
49 | /**
50 | * @return mixed
51 | */
52 | #[\ReturnTypeWillChange]
53 | public function jsonSerialize()
54 | {
55 | return $this->content;
56 | }
57 | }
58 |
--------------------------------------------------------------------------------