class_WebOutput.php
Go to the documentation of this file.00001 <?php
00025 class WebOutput extends BaseFrameworkSystem implements OutputStreamer, Registerable {
00029 private static $webInstance = null;
00030
00036 protected function __construct () {
00037
00038 parent::__construct(__CLASS__);
00039 }
00040
00047 public final static function createWebOutput ($contentType) {
00048
00049 if (is_null(self::$webInstance)) {
00050
00051 $contentType = (string) $contentType;
00052 $contentType = trim($contentType);
00053
00054
00055 if (!empty($contentType)) {
00056 @header(sprintf("Content-type: %s",
00057 $contentType
00058 ));
00059 }
00060
00061
00062 self::$webInstance = new WebOutput();
00063 }
00064
00065
00066 return self::$webInstance;
00067 }
00068
00076 public function assignVariable($var, $value) {
00077
00078 trigger_error(__METHOD__.": Stub!");
00079 }
00080
00086 public final function output ($outStream=false) {
00087 print(stripslashes($outStream));
00088 }
00089 }
00090
00091
00092 ?>