/**
* Socket resource
*/
- private $socketResource = false;
+ private $socketResource = FALSE;
/**
* Package data
} elseif (is_array($arg)) {
// .. or size if array
$argsString .= ', ' . count($arg);
- } elseif ($arg === true) {
+ } elseif ($arg === TRUE) {
// ... is boolean 'true'
$argsString .= ', true';
- } elseif ($arg === false) {
+ } elseif ($arg === FALSE) {
// ... is boolean 'true'
$argsString .= ', false';
}
print('</pre>');
// Exit program?
- if ($doExit === true) {
+ if ($doExit === TRUE) {
exit();
} // END - if
}
* @paran $stripTags Whether to strip tags (default: false)
* @return void
*/
- public function debugOutput ($message, $doPrint = true, $stripTags = false) {
+ public function debugOutput ($message, $doPrint = TRUE, $stripTags = FALSE) {
// Set debug instance to NULL
$debugInstance = NULL;
// Use debug output handler
$debugInstance->output($message, $stripTags);
- if ($doPrint === false) {
+ if ($doPrint === FALSE) {
// Die here if not printed
exit();
} // END - if
} // END - if
// Put directly out
- if ($doPrint === true) {
+ if ($doPrint === TRUE) {
// Print message
print($message . chr(10));
} else {
$this->getResultInstance()->rewind();
// Do we have an entry?
- if ($this->getResultInstance()->valid() === false) {
+ if ($this->getResultInstance()->valid() === FALSE) {
throw new InvalidDatabaseResultException(array($this, $this->getResultInstance()), DatabaseResult::EXCEPTION_INVALID_DATABASE_RESULT);
} // END - if
*/
public function idle ($milliSeconds) {
// Sleep is fine by default
- $hasSlept = true;
+ $hasSlept = TRUE;
// Idle so long with found function
if (function_exists('time_sleep_until')) {
*/
protected function isBase64Encoded ($encodedData) {
// Determine it
- $isBase64 = (@base64_decode($encodedData, true) !== false);
+ $isBase64 = (@base64_decode($encodedData, true) !== FALSE);
// Return it
return $isBase64;
* @param $assertMismatch Whether to assert mismatches
* @return $ret The (hopefully) secured numbered value
*/
- public function bigintval ($num, $castValue = true, $assertMismatch = false) {
+ public function bigintval ($num, $castValue = TRUE, $assertMismatch = FALSE) {
// Filter all numbers out
$ret = preg_replace('/[^0123456789]/', '', $num);
// Shall we cast?
- if ($castValue === true) {
+ if ($castValue === TRUE) {
// Cast to biggest numeric type
$ret = (double) $ret;
} // END - if
// Assert only if requested
- if ($assertMismatch === true) {
+ if ($assertMismatch === TRUE) {
// Has the whole value changed?
assert(('' . $ret . '' != '' . $num . '') && (!is_null($num)));
} // END - if
* @param $assertMismatch Whether to assert mismatches
* @return $ret The (hopefully) secured hext-numbered value
*/
- public function hexval ($num, $assertMismatch = false) {
+ public function hexval ($num, $assertMismatch = FALSE) {
// Filter all numbers out
$ret = preg_replace('/[^0123456789abcdefABCDEF]/', '', $num);
// Assert only if requested
- if ($assertMismatch === true) {
+ if ($assertMismatch === TRUE) {
// Has the whole value changed?
assert(('' . $ret . '' != '' . $num . '') && (!is_null($num)));
} // END - if