diff --git a/src/Jaeger/GHttp.php b/src/Jaeger/GHttp.php index 592f2cc..0596daa 100644 --- a/src/Jaeger/GHttp.php +++ b/src/Jaeger/GHttp.php @@ -15,12 +15,6 @@ /** * Class GHttp * @package Jaeger - * - * @method static string get($url,$args = null,$otherArgs = []) - * @method static mixed getJson($url, $args = null, $otherArgs = []) - * @method static string post($url,$args = null,$otherArgs = []) - * @method static string postRaw($url, $raw = null, $otherArgs = []) - * @method static string postJson($url, $args = null, $otherArgs = []) */ class GHttp { @@ -40,7 +34,7 @@ public static function getClient(array $config = []) * @param array $otherArgs * @return string */ - protected static function _get($url,$args = null,$otherArgs = []) + public static function get($url,$args = null,$otherArgs = []) { is_string($args) && parse_str($args,$args); $args = array_merge([ @@ -56,7 +50,7 @@ protected static function _get($url,$args = null,$otherArgs = []) return (string)$response->getBody(); } - protected static function _getJson($url, $args = null, $otherArgs = []) + public static function getJson($url, $args = null, $otherArgs = []) { $data = self::get($url, $args , $otherArgs); return json_decode($data,JSON_UNESCAPED_UNICODE); @@ -68,7 +62,7 @@ protected static function _getJson($url, $args = null, $otherArgs = []) * @param array $otherArgs * @return string */ - protected static function _post($url,$args = null,$otherArgs = []) + public static function post($url,$args = null,$otherArgs = []) { is_string($args) && parse_str($args,$args); $args = array_merge([ @@ -90,7 +84,7 @@ protected static function _post($url,$args = null,$otherArgs = []) * @param array $otherArgs * @return string */ - protected static function _postRaw($url, $raw = null, $otherArgs = []) + public static function postRaw($url, $raw = null, $otherArgs = []) { is_array($raw) && $raw = json_encode($raw); $args = array_merge([ @@ -112,7 +106,7 @@ protected static function _postRaw($url, $raw = null, $otherArgs = []) * @param array $otherArgs * @return string */ - protected static function _postJson($url, $args = null, $otherArgs = []) + public static function postJson($url, $args = null, $otherArgs = []) { is_string($args) && parse_str($args,$args); $args = array_merge([