private function __construct() { $this->phpInput = file_get_contents('php://input'); $this->serverQueryString = $_SERVER['QUERY_STRING']; $this->serverRequestMethod = $_SERVER['REQUEST_METHOD']; $this->httpResponse = HttpResponse::getInstance(); $this->json = JSON::getInstance(); }
public static function decode($str, $use = 0) { $json = JSON::getInstance($use); return $json->decode($str); }