Qiniu cloud storage-PHPSDK of qiniu cloud V7 has not been completed yet. Why can't I find the delete and mobile resource functions?

Source: Internet
Author: User
It's strange that the official document clearly states that this SDK includes the following functions: Data upload and download. Manage data: Copy, move, delete, obtain metadata, and retrieve files from columns. Data Processing: image processing, audio/video processing, and document processing. Why is this irresponsible? It's strange that the official document is clearly written.
This SDK includes the following functions:

Upload and download data.

Manage data: Copy, move, delete, obtain metadata, and retrieve files from columns.

Data Processing: image processing, audio/video processing, and document processing.

Why is this irresponsible?

Reply content:

It's strange that the official document is clearly written.
This SDK includes the following functions:

Upload and download data.

Manage data: Copy, move, delete, obtain metadata, and retrieve files from columns.

Data Processing: image processing, audio/video processing, and document processing.

Why is this irresponsible?

Qiniu has these functions. You can look at their source code:

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

All of the functional codes you mentioned are available.

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

Find it.

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

/*** Delete a specified resource ** @ param $ bucket the space where the resource to be deleted is located * @ param $ key the file name of the resource to be deleted ** @ return mixed success return NULL, error returned 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 the resource, which is essentially a move operation. ** @ Param $ bucket space of the resource to be operated * @ param $ oldname name of the resource to be operated * @ param $ newname target resource file name ** @ return mixed success return NULL, failed return object Qiniu \ Http \ Error */public function rename ($ bucket, $ oldname, $ newname) {return $ this-> move ($ bucket, $ oldname, $ bucket, $ newname);}/*** rename the resource, which is essentially a move operation. ** @ Param $ from_bucket space where the resource to be operated is located * @ param $ from_key name of the resource to be operated * @ param $ to_bucket target resource space name * @ param $ to_key Target Resource Name **@ return mixed success return NULL, error returned 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 ;} /*** transfer a resource from one space to another ** @ param $ from_bucket the space where the resource to be operated is located * @ param $ from_key the file name of the resource to be operated * @ param $ to_bucket the target resource space name * @ param $ to_key target resource file name ** @ return mixed success return NULL, error returned object Qiniu \ Http \ 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 ;}

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.