Skip to content

Commit

Permalink
Avoid namespace clashes.
Browse files Browse the repository at this point in the history
  • Loading branch information
= committed Apr 15, 2016
1 parent 0b0b970 commit dc86c3f
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "qtism/qtism",
"description": "OAT QTI Software Module Library",
"type": "library",
"version": "0.9.25",
"version": "0.9.26",
"authors": [
{
"name": "Open Assessment Technologies S.A.",
Expand Down
8 changes: 4 additions & 4 deletions qtism/runtime/expressions/operators/AnyNProcessor.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
use qtism\common\datatypes\Integer;
use qtism\data\expressions\operators\AnyN;
use qtism\data\expressions\Expression;
use qtism\runtime\expressions\Utils;
use qtism\runtime\expressions\Utils as ProcessingUtils;
use \InvalidArgumentException;

/**
Expand Down Expand Up @@ -82,7 +82,7 @@ public function process() {
if (is_string($min) === true) {
// variable reference for 'min' to handle.
$state = $this->getState();
$varName = Utils::sanitizeVariableRef($min);
$varName = ProcessingUtils::sanitizeVariableRef($min);
$varValue = $state[$varName];

if (is_null($varValue)) {
Expand All @@ -101,7 +101,7 @@ public function process() {
if (is_string($max) === true) {
// variable reference for 'max' to handle.
$state = $this->getState();
$varName = Utils::sanitizeVariableRef($max);
$varName = ProcessingUtils::sanitizeVariableRef($max);
$varValue = $state[$varName];

if (is_null($varValue)) {
Expand Down Expand Up @@ -151,4 +151,4 @@ public function process() {
}
}
}
}
}
8 changes: 4 additions & 4 deletions qtism/runtime/expressions/operators/EqualProcessor.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
use qtism\data\expressions\operators\ToleranceMode;
use qtism\data\expressions\operators\Equal;
use qtism\data\expressions\Expression;
use qtism\runtime\expressions\Utils;
use qtism\runtime\expressions\Utils as ProcessingUtils;
use \InvalidArgumentException;

/**
Expand Down Expand Up @@ -116,7 +116,7 @@ public function process() {

// variableRef to handle.
$state = $this->getState();
$tolerance0Name = Utils::sanitizeVariableRef($strTolerance[0]);
$tolerance0Name = ProcessingUtils::sanitizeVariableRef($strTolerance[0]);
$varValue = $state[$tolerance0Name];

if (is_null($varValue)) {
Expand All @@ -132,7 +132,7 @@ public function process() {

if (isset($strTolerance[1]) && gettype($strTolerance[1]) === 'string') {
// A second variableRef to handle.
$tolerance1Name = Utils::sanitizeVariableRef($strTolerance[1]);
$tolerance1Name = ProcessingUtils::sanitizeVariableRef($strTolerance[1]);

if (($varValue = $state[$tolerance1Name]) !== null && $varValue instanceof Float) {
$tolerance[] = $varValue->getValue();
Expand Down Expand Up @@ -163,4 +163,4 @@ public function process() {
}
}
}
}
}
6 changes: 3 additions & 3 deletions qtism/runtime/expressions/operators/EqualRoundedProcessor.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
use qtism\runtime\common\Utils as RuntimeUtils;
use qtism\data\expressions\operators\EqualRounded;
use qtism\data\expressions\Expression;
use qtism\runtime\expressions\Utils;
use qtism\runtime\expressions\Utils as ProcessingUtils;
use \InvalidArgumentException;

/**
Expand Down Expand Up @@ -103,7 +103,7 @@ public function process() {
if (gettype($figures) === 'string') {
// Variable reference to deal with.
$state = $this->getState();
$varName = Utils::sanitizeVariableRef($figures);
$varName = ProcessingUtils::sanitizeVariableRef($figures);
$varValue = $state[$varName];

if (is_null($varValue) === true) {
Expand Down Expand Up @@ -137,4 +137,4 @@ public function process() {

return new Boolean($rounded[0]->getValue() == $rounded[1]->getValue());
}
}
}

0 comments on commit dc86c3f

Please sign in to comment.