public function flush() { if (!$this->_flushedStatus) { $this->_flushedStatus = true; php_Web::setReturnCode($this->status); } if (!$this->_flushedCookies) { $this->_flushedCookies = true; try { if (null == $this->_cookies) { throw new HException('null iterable'); } $__hx__it = $this->_cookies->iterator(); while ($__hx__it->hasNext()) { unset($cookie); $cookie = $__hx__it->next(); php_Web::setCookie($cookie->name, $cookie->value, $cookie->expires, $cookie->domain, $cookie->path, $cookie->secure, $cookie->httpOnly); } } catch (Exception $__hx__e) { $_ex_ = $__hx__e instanceof HException ? $__hx__e->e : $__hx__e; $e = $_ex_; throw new HException(ufront_web_HttpError::internalServerError("Failed to set cookie on response", $e, _hx_anonymous(array("fileName" => "HttpResponse.hx", "lineNumber" => 34, "className" => "sys.ufront.web.context.HttpResponse", "methodName" => "flush")))); } } if (!$this->_flushedHeaders) { $this->_flushedHeaders = true; if (null == $this->_headers) { throw new HException('null iterable'); } $__hx__it = $this->_headers->keys(); while ($__hx__it->hasNext()) { unset($key); $key = $__hx__it->next(); $val = $this->_headers->get($key); if ($key === "Content-type" && null !== $this->charset && StringTools::startsWith($val, "text/")) { $val .= "; charset=" . _hx_string_or_null($this->charset); } try { header(_hx_string_or_null($key) . ": " . _hx_string_or_null($val)); } catch (Exception $__hx__e) { $_ex_ = $__hx__e instanceof HException ? $__hx__e->e : $__hx__e; $e1 = $_ex_; throw new HException(ufront_web_HttpError::internalServerError("Invalid header: \"" . _hx_string_or_null($key) . ": " . _hx_string_or_null($val) . "\", or output already sent", $e1, _hx_anonymous(array("fileName" => "HttpResponse.hx", "lineNumber" => 50, "className" => "sys.ufront.web.context.HttpResponse", "methodName" => "flush")))); } unset($val, $e1); } } if (!$this->_flushedContent) { $this->_flushedContent = true; Sys::hprint($this->_buff->b); } }
public function onRemoteError($remote) { $remote->event->error->addCrumb($this, "remoteCall"); Sys::hprint(zcale_core_boot_targets_ServerBoot_2($this, $remote)); }
public function updateRecords() { $naw = new zcale_sys_db_tests_zcale_Naw(); $sql = null; $this1 = null; $this2 = null; $this3 = null; $this4 = null; $this4 = zcale_sys_db_tests_DatabaseTest_3($this, $naw, $sql, $this1, $this2, $this3, $this4); $str1 = _hx_string_or_null($this4) . " SET " . Std::string($naw->naam) . "=" . _hx_string_or_null(zcale_sys_db_SqlTools::evalValue("Martinez Martinez")); $this3 = $str1; $str2 = _hx_string_or_null($this3) . " WHERE " . Std::string($naw->naam); $this2 = $str2; $str3 = _hx_string_or_null($this2) . "=" . _hx_string_or_null(zcale_sys_db_SqlTools::evalValue("Martinez")); $this1 = $str3; $sql = $this1; $this->cnx->request($sql); Sys::hprint("<br/>Record updated in " . Std::string($naw) . ": " . _hx_string_or_null($sql)); }
static function println($v) { Sys::hprint($v); Sys::hprint("\n"); }