Seven Qiniu Storage-seven Qiniu V7 version of the PHP SDK is not yet done, why can't I find the function of deleting, moving resources?

Source: Internet
Author: User
Well, it's a weird official document, clearly written.
The SDK includes the following features:

Uploading and downloading of data.

Data management: Copy, move, delete, get meta information, and list files.

Processing of data: processing of pictures, processing of audio and video, processing of documents.

Why is that so irresponsible?

Reply content:

Well, it's a weird official document, clearly written.
The SDK includes the following features:

Uploading and downloading of data.

Data management: Copy, move, delete, get meta information, and list files.

Processing of data: processing of pictures, processing of audio and video, processing of documents.

Why is that so irresponsible?

Seven cows these functions have ah, you can look at their source code:

https://github.com/qiniu/php-sdk/tree/v7.0.4

There are all these functional codes you're talking about.

use Qiniu\Storage\BucketManager;$bucketMgr = New BucketManager($this->auth);$bucketMgr->move(...);$bucketMgr->delete(...);

I found it as soon as I found it.

View: https://github.com/qiniu/php-sdk/blob/v7.0.4/src/Qiniu/Storage/BucketManager.php
There is a corresponding method

/** * Delete the specified resource * @param $bucket the space where the resource is to be deleted * @param $key the file name of the resource to be deleted * * @return Mixed    Successfully returned null, failed to return object Qiniu\http\error * @link http://developer.qiniu.com/docs/v6/api/reference/rs/delete.html */        Public Function Delete ($bucket, $key) {$path = '/delete/'. \qiniu\entry ($bucket, $key);        List (, $error) = $this->rspost ($path);    return $error;     /** * Rename a resource, essentially a move operation. * * @param $bucket the space where the resource is to be manipulated * @param $oldname the resource file name * @param $newname target Resource file name * * @retur n mixed successfully returned null, failed to return object Qiniu\http\error */Public Function rename ($bucket, $oldname, $newname) {RET    Urn $this->move ($bucket, $oldname, $bucket, $newname);     /** * Rename a resource, essentially a move operation.     * * @param $from _bucket where to operate resources * @param $from _key resource file name * @param $to _bucket target Resource space name * @param $to _key target Resource file name * * @return mixed successfully returned null, failedReturn Object Qiniu\http\error * @link http://developer.qiniu.com/docs/v6/api/reference/rs/copy.html */Public function        Copy ($from _bucket, $from _key, $to _bucket, $to _key) {$from = \qiniu\entry ($from _bucket, $from _key);        $to = \qiniu\entry ($to _bucket, $to _key); $path = '/copy/'. $from. '/' .        $to;        List (, $error) = $this->rspost ($path);    return $error; /** * The resource from one space to another * * @param $from _bucket The space to be manipulated * @param $from _key resource file name * @ param $to _bucket Target resource space name * @param $to _key target Resource file name * * @return mixed successfully returned null, failed to return object qiniu\h Ttp\error * @link http://developer.qiniu.com/docs/v6/api/reference/rs/move.html */Public Function Move ($from _        Bucket, $from _key, $to _bucket, $to _key) {$from = \qiniu\entry ($from _bucket, $from _key);        $to = \qiniu\entry ($to _bucket, $to _key); $path = '/move/'. $from. '/' .        $to; List (, $error) = $this->rspost ($pATH);    return $error; }
  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.