<?php
/**
- * Loads required classes
+ * Load required framework classes first
*
- * @author Roland Haeder <webmaster@mxchange.org>
- * @version 0.3.0
+ * @author Roland Haeder <webmaster@ship-simu.org>
+ * @version 0.0
* @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software
* @license GNU GPL 3.0 or any newer version
- * @link http://www.mxchange.org
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-/**
- * Lower framework classes
- */
+// Lower framework classes
$lowerClasses = array(
0 => "exceptions", // Exceptions
1 => "interfaces", // Interfaces
* The simulator system class is the super class of all other classes. This
* class handles saving of games etc.
*
- * @author Roland Haeder <webmaster@mxchange.org>
+ * @author Roland Haeder <webmaster@ship-simu.org>
* @version 0.3.0
* @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software
* @license GNU GPL 3.0 or any newer version
- * @link http://www.mxchange.org
- *
+ * @link http://www.mxchange.org
+ *
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
const EXCEPTION_VARIABLE_NOT_SET = 0x02a;
const EXCEPTION_ATTRIBUTES_ARE_MISSING = 0x02b;
const EXCEPTION_ARRAY_ELEMENTS_MISSING = 0x02c;
- const EXCEPTION_NOT_CONSTRUCTABLE = 0x02d;
/**
* In the super constructor these system classes shall be ignored or else
"GzipCompressor", // GZIP compressor
"WebOutput", // Web output sub-system
);
-
+
/**
* Private super constructor
*
$this->getDebugInstance()->output(sprintf("[%s::%s] Stub! Args: %s",
$this->__toString(),
$methodName,
- $argsString
+ $argsString
));
// Return nothing
private final function generateIdNumber () {
return sprintf("%s@%s",
$this->__toString(),
- md5(sprintf("%s:%s:%s:%s:%s:%s",
+ md5(sprintf("%s:%s:%s:%s:%s:%s",
$this->__toString(),
$this->getPartDescr(),
time(),
<?php
/**
* BZIP2 compression and decompression class
+ *
+ * @author Roland Haeder <webmaster@ship-simu.org>
+ * @version 0.3.0
+ * @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software
+ * @license GNU GPL 3.0 or any newer version
+ * @link http://www.mxchange.org
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
class Bzip2Compressor extends BaseFrameworkSystem implements Compressor {
/**
<?php
/**
* GZIP compression and decompression class
+ *
+ * @author Roland Haeder <webmaster@ship-simu.org>
+ * @version 0.3.0
+ * @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software
+ * @license GNU GPL 3.0 or any newer version
+ * @link http://www.mxchange.org
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
class GzipCompressor extends BaseFrameworkSystem implements Compressor {
/**
<?php
/**
* Null compression and decompression class
+ *
+ * @author Roland Haeder <webmaster@ship-simu.org>
+ * @version 0.3.0
+ * @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software
+ * @license GNU GPL 3.0 or any newer version
+ * @link http://www.mxchange.org
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
class NullCompressor extends BaseFrameworkSystem implements Compressor {
/**
<?php
/**
- * Kompressor-Auswahl Klasse
+ * Middleware class for selecting the right compressor channel
*
* @author Roland Haeder <webmaster@mxchange.org>
* @version 0.3.0
* NOTE: We cannot put this in inc/classes/ because it would be loaded (again)
* in the class loader. See inc/loader/class_ClassLoader.php for instance
*
- * @see ClassLoader
+ * @see ClassLoader
* @author Roland Haeder <webmaster@mxchange.org>
* @version 0.3.0
* @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software
* @license GNU GPL 3.0 or any newer version
- * @link http://www.mxchange.org
+ * @link http://www.mxchange.org
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
// Cast to string
$path = (string) $path;
+ // Replace backslashes with slashes
+ $path = str_replace("\\", "/", $path);
+
// Is it defined or not?
- if (!is_dir($path)) {
+ if ((!is_dir($path)) || (!is_readable($path))) {
// Is not a valid path
ApplicationEntryPoint::app_die(sprintf("[%s:] Invalid path (not found) specified. Please make sure it is created.",
__CLASS__
* @version 0.3.0
* @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software
* @license GNU GPL 3.0 or any newer version
- * @link http://www.mxchange.org
+ * @link http://www.mxchange.org
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
if ((class_exists($tpl)) && (is_object($lang)) && (is_object($io))) {
// Use the template engine for putting out (nicer look) the message
try {
- $eval = sprintf("$tplEngine = %s::create%s(\"%s%s\", LanguageSystem::getInstance(), FileIOHandler::getInstance());",
+ $eval = sprintf("\$tplEngine = %s::create%s(\"%s%s\", LanguageSystem::getInstance(), FileIOHandler::getInstance());",
FrameworkConfiguration::getInstance()->readConfig("tpl_engine"),
FrameworkConfiguration::getInstance()->readConfig("tpl_engine"),
PATH,