src/Upyun/Upyun.php
public function usage($path = '/')
    {
        $path = rtrim($path, '/') . '/';
        $req = new Rest($this->config);
        $response = $req->request('GET', $path . '?usage')
            ->send();

        return $response->getBody()->getContents();
    }
public function usage($path = '/')
    {
        $path = rtrim($path, '/') . '/';
        $req = new Rest($this->config);
        $response = $req->request('GET', $path . '?usage')
            ->send();

        return $response->getBody()->getContents();
    }
public function usage ( $ path = '/' ) { $ path = rtrim ( $ path , '/' ) . '/' ; $ req = new Rest ( $ this -> config ) ; $ response = $ req -> request ( 'GET' , $ path . '?usage' ) -> send ( ) ; return $ response -> getBody ( ) -> getContents ( ) ; }
获取目录下存储使用量

@param string $path 云存储目录路径，默认为根目录，表示整个云存储服务使用的空间大小
@return string 存储使用量，单位字节
@throws \Exception
获取目录下存储使用量