Edit File by line
/home/barbar84/public_h.../wp-conte.../plugins/updraftp.../includes/Google/Service
File: Drive.php
<?php
[0] Fix | Delete
/*
[1] Fix | Delete
* Copyright 2010 Google Inc.
[2] Fix | Delete
*
[3] Fix | Delete
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
[4] Fix | Delete
* use this file except in compliance with the License. You may obtain a copy of
[5] Fix | Delete
* the License at
[6] Fix | Delete
*
[7] Fix | Delete
* http://www.apache.org/licenses/LICENSE-2.0
[8] Fix | Delete
*
[9] Fix | Delete
* Unless required by applicable law or agreed to in writing, software
[10] Fix | Delete
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
[11] Fix | Delete
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
[12] Fix | Delete
* License for the specific language governing permissions and limitations under
[13] Fix | Delete
* the License.
[14] Fix | Delete
*/
[15] Fix | Delete
[16] Fix | Delete
/**
[17] Fix | Delete
* Service definition for Drive (v2).
[18] Fix | Delete
*
[19] Fix | Delete
* <p>
[20] Fix | Delete
* The API to interact with Drive.</p>
[21] Fix | Delete
*
[22] Fix | Delete
* <p>
[23] Fix | Delete
* For more information about this service, see the API
[24] Fix | Delete
* <a href="https://developers.google.com/drive/" target="_blank">Documentation</a>
[25] Fix | Delete
* </p>
[26] Fix | Delete
*
[27] Fix | Delete
* @author Google, Inc.
[28] Fix | Delete
*/
[29] Fix | Delete
class UDP_Google_Service_Drive extends UDP_Google_Service
[30] Fix | Delete
{
[31] Fix | Delete
/** View and manage the files in your Google Drive. */
[32] Fix | Delete
const DRIVE =
[33] Fix | Delete
"https://www.googleapis.com/auth/drive";
[34] Fix | Delete
/** View and manage its own configuration data in your Google Drive. */
[35] Fix | Delete
const DRIVE_APPDATA =
[36] Fix | Delete
"https://www.googleapis.com/auth/drive.appdata";
[37] Fix | Delete
/** View your Google Drive apps. */
[38] Fix | Delete
const DRIVE_APPS_READONLY =
[39] Fix | Delete
"https://www.googleapis.com/auth/drive.apps.readonly";
[40] Fix | Delete
/** View and manage Google Drive files that you have opened or created with this app. */
[41] Fix | Delete
const DRIVE_FILE =
[42] Fix | Delete
"https://www.googleapis.com/auth/drive.file";
[43] Fix | Delete
/** View and manage metadata of files in your Google Drive. */
[44] Fix | Delete
const DRIVE_METADATA =
[45] Fix | Delete
"https://www.googleapis.com/auth/drive.metadata";
[46] Fix | Delete
/** View metadata for files in your Google Drive. */
[47] Fix | Delete
const DRIVE_METADATA_READONLY =
[48] Fix | Delete
"https://www.googleapis.com/auth/drive.metadata.readonly";
[49] Fix | Delete
/** View the files in your Google Drive. */
[50] Fix | Delete
const DRIVE_READONLY =
[51] Fix | Delete
"https://www.googleapis.com/auth/drive.readonly";
[52] Fix | Delete
/** Modify your Google Apps Script scripts' behavior. */
[53] Fix | Delete
const DRIVE_SCRIPTS =
[54] Fix | Delete
"https://www.googleapis.com/auth/drive.scripts";
[55] Fix | Delete
[56] Fix | Delete
public $about;
[57] Fix | Delete
public $apps;
[58] Fix | Delete
public $changes;
[59] Fix | Delete
public $channels;
[60] Fix | Delete
public $children;
[61] Fix | Delete
public $comments;
[62] Fix | Delete
public $files;
[63] Fix | Delete
public $parents;
[64] Fix | Delete
public $permissions;
[65] Fix | Delete
public $properties;
[66] Fix | Delete
public $realtime;
[67] Fix | Delete
public $replies;
[68] Fix | Delete
public $revisions;
[69] Fix | Delete
[70] Fix | Delete
[71] Fix | Delete
/**
[72] Fix | Delete
* Constructs the internal representation of the Drive service.
[73] Fix | Delete
*
[74] Fix | Delete
* @param UDP_Google_Client $client
[75] Fix | Delete
*/
[76] Fix | Delete
public function __construct(UDP_Google_Client $client)
[77] Fix | Delete
{
[78] Fix | Delete
parent::__construct($client);
[79] Fix | Delete
$this->servicePath = 'drive/v2/';
[80] Fix | Delete
$this->version = 'v2';
[81] Fix | Delete
$this->serviceName = 'drive';
[82] Fix | Delete
[83] Fix | Delete
$this->about = new Google_Service_Drive_About_Resource(
[84] Fix | Delete
$this,
[85] Fix | Delete
$this->serviceName,
[86] Fix | Delete
'about',
[87] Fix | Delete
array(
[88] Fix | Delete
'methods' => array(
[89] Fix | Delete
'get' => array(
[90] Fix | Delete
'path' => 'about',
[91] Fix | Delete
'httpMethod' => 'GET',
[92] Fix | Delete
'parameters' => array(
[93] Fix | Delete
'includeSubscribed' => array(
[94] Fix | Delete
'location' => 'query',
[95] Fix | Delete
'type' => 'boolean',
[96] Fix | Delete
),
[97] Fix | Delete
'maxChangeIdCount' => array(
[98] Fix | Delete
'location' => 'query',
[99] Fix | Delete
'type' => 'string',
[100] Fix | Delete
),
[101] Fix | Delete
'startChangeId' => array(
[102] Fix | Delete
'location' => 'query',
[103] Fix | Delete
'type' => 'string',
[104] Fix | Delete
),
[105] Fix | Delete
),
[106] Fix | Delete
),
[107] Fix | Delete
)
[108] Fix | Delete
)
[109] Fix | Delete
);
[110] Fix | Delete
$this->apps = new Google_Service_Drive_Apps_Resource(
[111] Fix | Delete
$this,
[112] Fix | Delete
$this->serviceName,
[113] Fix | Delete
'apps',
[114] Fix | Delete
array(
[115] Fix | Delete
'methods' => array(
[116] Fix | Delete
'get' => array(
[117] Fix | Delete
'path' => 'apps/{appId}',
[118] Fix | Delete
'httpMethod' => 'GET',
[119] Fix | Delete
'parameters' => array(
[120] Fix | Delete
'appId' => array(
[121] Fix | Delete
'location' => 'path',
[122] Fix | Delete
'type' => 'string',
[123] Fix | Delete
'required' => true,
[124] Fix | Delete
),
[125] Fix | Delete
),
[126] Fix | Delete
),'list' => array(
[127] Fix | Delete
'path' => 'apps',
[128] Fix | Delete
'httpMethod' => 'GET',
[129] Fix | Delete
'parameters' => array(
[130] Fix | Delete
'languageCode' => array(
[131] Fix | Delete
'location' => 'query',
[132] Fix | Delete
'type' => 'string',
[133] Fix | Delete
),
[134] Fix | Delete
'appFilterExtensions' => array(
[135] Fix | Delete
'location' => 'query',
[136] Fix | Delete
'type' => 'string',
[137] Fix | Delete
),
[138] Fix | Delete
'appFilterMimeTypes' => array(
[139] Fix | Delete
'location' => 'query',
[140] Fix | Delete
'type' => 'string',
[141] Fix | Delete
),
[142] Fix | Delete
),
[143] Fix | Delete
),
[144] Fix | Delete
)
[145] Fix | Delete
)
[146] Fix | Delete
);
[147] Fix | Delete
$this->changes = new Google_Service_Drive_Changes_Resource(
[148] Fix | Delete
$this,
[149] Fix | Delete
$this->serviceName,
[150] Fix | Delete
'changes',
[151] Fix | Delete
array(
[152] Fix | Delete
'methods' => array(
[153] Fix | Delete
'get' => array(
[154] Fix | Delete
'path' => 'changes/{changeId}',
[155] Fix | Delete
'httpMethod' => 'GET',
[156] Fix | Delete
'parameters' => array(
[157] Fix | Delete
'changeId' => array(
[158] Fix | Delete
'location' => 'path',
[159] Fix | Delete
'type' => 'string',
[160] Fix | Delete
'required' => true,
[161] Fix | Delete
),
[162] Fix | Delete
),
[163] Fix | Delete
),'list' => array(
[164] Fix | Delete
'path' => 'changes',
[165] Fix | Delete
'httpMethod' => 'GET',
[166] Fix | Delete
'parameters' => array(
[167] Fix | Delete
'includeSubscribed' => array(
[168] Fix | Delete
'location' => 'query',
[169] Fix | Delete
'type' => 'boolean',
[170] Fix | Delete
),
[171] Fix | Delete
'startChangeId' => array(
[172] Fix | Delete
'location' => 'query',
[173] Fix | Delete
'type' => 'string',
[174] Fix | Delete
),
[175] Fix | Delete
'includeDeleted' => array(
[176] Fix | Delete
'location' => 'query',
[177] Fix | Delete
'type' => 'boolean',
[178] Fix | Delete
),
[179] Fix | Delete
'maxResults' => array(
[180] Fix | Delete
'location' => 'query',
[181] Fix | Delete
'type' => 'integer',
[182] Fix | Delete
),
[183] Fix | Delete
'pageToken' => array(
[184] Fix | Delete
'location' => 'query',
[185] Fix | Delete
'type' => 'string',
[186] Fix | Delete
),
[187] Fix | Delete
),
[188] Fix | Delete
),'watch' => array(
[189] Fix | Delete
'path' => 'changes/watch',
[190] Fix | Delete
'httpMethod' => 'POST',
[191] Fix | Delete
'parameters' => array(
[192] Fix | Delete
'includeSubscribed' => array(
[193] Fix | Delete
'location' => 'query',
[194] Fix | Delete
'type' => 'boolean',
[195] Fix | Delete
),
[196] Fix | Delete
'startChangeId' => array(
[197] Fix | Delete
'location' => 'query',
[198] Fix | Delete
'type' => 'string',
[199] Fix | Delete
),
[200] Fix | Delete
'includeDeleted' => array(
[201] Fix | Delete
'location' => 'query',
[202] Fix | Delete
'type' => 'boolean',
[203] Fix | Delete
),
[204] Fix | Delete
'maxResults' => array(
[205] Fix | Delete
'location' => 'query',
[206] Fix | Delete
'type' => 'integer',
[207] Fix | Delete
),
[208] Fix | Delete
'pageToken' => array(
[209] Fix | Delete
'location' => 'query',
[210] Fix | Delete
'type' => 'string',
[211] Fix | Delete
),
[212] Fix | Delete
),
[213] Fix | Delete
),
[214] Fix | Delete
)
[215] Fix | Delete
)
[216] Fix | Delete
);
[217] Fix | Delete
$this->channels = new Google_Service_Drive_Channels_Resource(
[218] Fix | Delete
$this,
[219] Fix | Delete
$this->serviceName,
[220] Fix | Delete
'channels',
[221] Fix | Delete
array(
[222] Fix | Delete
'methods' => array(
[223] Fix | Delete
'stop' => array(
[224] Fix | Delete
'path' => 'channels/stop',
[225] Fix | Delete
'httpMethod' => 'POST',
[226] Fix | Delete
'parameters' => array(),
[227] Fix | Delete
),
[228] Fix | Delete
)
[229] Fix | Delete
)
[230] Fix | Delete
);
[231] Fix | Delete
$this->children = new Google_Service_Drive_Children_Resource(
[232] Fix | Delete
$this,
[233] Fix | Delete
$this->serviceName,
[234] Fix | Delete
'children',
[235] Fix | Delete
array(
[236] Fix | Delete
'methods' => array(
[237] Fix | Delete
'delete' => array(
[238] Fix | Delete
'path' => 'files/{folderId}/children/{childId}',
[239] Fix | Delete
'httpMethod' => 'DELETE',
[240] Fix | Delete
'parameters' => array(
[241] Fix | Delete
'folderId' => array(
[242] Fix | Delete
'location' => 'path',
[243] Fix | Delete
'type' => 'string',
[244] Fix | Delete
'required' => true,
[245] Fix | Delete
),
[246] Fix | Delete
'childId' => array(
[247] Fix | Delete
'location' => 'path',
[248] Fix | Delete
'type' => 'string',
[249] Fix | Delete
'required' => true,
[250] Fix | Delete
),
[251] Fix | Delete
),
[252] Fix | Delete
),'get' => array(
[253] Fix | Delete
'path' => 'files/{folderId}/children/{childId}',
[254] Fix | Delete
'httpMethod' => 'GET',
[255] Fix | Delete
'parameters' => array(
[256] Fix | Delete
'folderId' => array(
[257] Fix | Delete
'location' => 'path',
[258] Fix | Delete
'type' => 'string',
[259] Fix | Delete
'required' => true,
[260] Fix | Delete
),
[261] Fix | Delete
'childId' => array(
[262] Fix | Delete
'location' => 'path',
[263] Fix | Delete
'type' => 'string',
[264] Fix | Delete
'required' => true,
[265] Fix | Delete
),
[266] Fix | Delete
),
[267] Fix | Delete
),'insert' => array(
[268] Fix | Delete
'path' => 'files/{folderId}/children',
[269] Fix | Delete
'httpMethod' => 'POST',
[270] Fix | Delete
'parameters' => array(
[271] Fix | Delete
'folderId' => array(
[272] Fix | Delete
'location' => 'path',
[273] Fix | Delete
'type' => 'string',
[274] Fix | Delete
'required' => true,
[275] Fix | Delete
),
[276] Fix | Delete
),
[277] Fix | Delete
),'list' => array(
[278] Fix | Delete
'path' => 'files/{folderId}/children',
[279] Fix | Delete
'httpMethod' => 'GET',
[280] Fix | Delete
'parameters' => array(
[281] Fix | Delete
'folderId' => array(
[282] Fix | Delete
'location' => 'path',
[283] Fix | Delete
'type' => 'string',
[284] Fix | Delete
'required' => true,
[285] Fix | Delete
),
[286] Fix | Delete
'q' => array(
[287] Fix | Delete
'location' => 'query',
[288] Fix | Delete
'type' => 'string',
[289] Fix | Delete
),
[290] Fix | Delete
'pageToken' => array(
[291] Fix | Delete
'location' => 'query',
[292] Fix | Delete
'type' => 'string',
[293] Fix | Delete
),
[294] Fix | Delete
'maxResults' => array(
[295] Fix | Delete
'location' => 'query',
[296] Fix | Delete
'type' => 'integer',
[297] Fix | Delete
),
[298] Fix | Delete
),
[299] Fix | Delete
),
[300] Fix | Delete
)
[301] Fix | Delete
)
[302] Fix | Delete
);
[303] Fix | Delete
$this->comments = new Google_Service_Drive_Comments_Resource(
[304] Fix | Delete
$this,
[305] Fix | Delete
$this->serviceName,
[306] Fix | Delete
'comments',
[307] Fix | Delete
array(
[308] Fix | Delete
'methods' => array(
[309] Fix | Delete
'delete' => array(
[310] Fix | Delete
'path' => 'files/{fileId}/comments/{commentId}',
[311] Fix | Delete
'httpMethod' => 'DELETE',
[312] Fix | Delete
'parameters' => array(
[313] Fix | Delete
'fileId' => array(
[314] Fix | Delete
'location' => 'path',
[315] Fix | Delete
'type' => 'string',
[316] Fix | Delete
'required' => true,
[317] Fix | Delete
),
[318] Fix | Delete
'commentId' => array(
[319] Fix | Delete
'location' => 'path',
[320] Fix | Delete
'type' => 'string',
[321] Fix | Delete
'required' => true,
[322] Fix | Delete
),
[323] Fix | Delete
),
[324] Fix | Delete
),'get' => array(
[325] Fix | Delete
'path' => 'files/{fileId}/comments/{commentId}',
[326] Fix | Delete
'httpMethod' => 'GET',
[327] Fix | Delete
'parameters' => array(
[328] Fix | Delete
'fileId' => array(
[329] Fix | Delete
'location' => 'path',
[330] Fix | Delete
'type' => 'string',
[331] Fix | Delete
'required' => true,
[332] Fix | Delete
),
[333] Fix | Delete
'commentId' => array(
[334] Fix | Delete
'location' => 'path',
[335] Fix | Delete
'type' => 'string',
[336] Fix | Delete
'required' => true,
[337] Fix | Delete
),
[338] Fix | Delete
'includeDeleted' => array(
[339] Fix | Delete
'location' => 'query',
[340] Fix | Delete
'type' => 'boolean',
[341] Fix | Delete
),
[342] Fix | Delete
),
[343] Fix | Delete
),'insert' => array(
[344] Fix | Delete
'path' => 'files/{fileId}/comments',
[345] Fix | Delete
'httpMethod' => 'POST',
[346] Fix | Delete
'parameters' => array(
[347] Fix | Delete
'fileId' => array(
[348] Fix | Delete
'location' => 'path',
[349] Fix | Delete
'type' => 'string',
[350] Fix | Delete
'required' => true,
[351] Fix | Delete
),
[352] Fix | Delete
),
[353] Fix | Delete
),'list' => array(
[354] Fix | Delete
'path' => 'files/{fileId}/comments',
[355] Fix | Delete
'httpMethod' => 'GET',
[356] Fix | Delete
'parameters' => array(
[357] Fix | Delete
'fileId' => array(
[358] Fix | Delete
'location' => 'path',
[359] Fix | Delete
'type' => 'string',
[360] Fix | Delete
'required' => true,
[361] Fix | Delete
),
[362] Fix | Delete
'pageToken' => array(
[363] Fix | Delete
'location' => 'query',
[364] Fix | Delete
'type' => 'string',
[365] Fix | Delete
),
[366] Fix | Delete
'updatedMin' => array(
[367] Fix | Delete
'location' => 'query',
[368] Fix | Delete
'type' => 'string',
[369] Fix | Delete
),
[370] Fix | Delete
'includeDeleted' => array(
[371] Fix | Delete
'location' => 'query',
[372] Fix | Delete
'type' => 'boolean',
[373] Fix | Delete
),
[374] Fix | Delete
'maxResults' => array(
[375] Fix | Delete
'location' => 'query',
[376] Fix | Delete
'type' => 'integer',
[377] Fix | Delete
),
[378] Fix | Delete
),
[379] Fix | Delete
),'patch' => array(
[380] Fix | Delete
'path' => 'files/{fileId}/comments/{commentId}',
[381] Fix | Delete
'httpMethod' => 'PATCH',
[382] Fix | Delete
'parameters' => array(
[383] Fix | Delete
'fileId' => array(
[384] Fix | Delete
'location' => 'path',
[385] Fix | Delete
'type' => 'string',
[386] Fix | Delete
'required' => true,
[387] Fix | Delete
),
[388] Fix | Delete
'commentId' => array(
[389] Fix | Delete
'location' => 'path',
[390] Fix | Delete
'type' => 'string',
[391] Fix | Delete
'required' => true,
[392] Fix | Delete
),
[393] Fix | Delete
),
[394] Fix | Delete
),'update' => array(
[395] Fix | Delete
'path' => 'files/{fileId}/comments/{commentId}',
[396] Fix | Delete
'httpMethod' => 'PUT',
[397] Fix | Delete
'parameters' => array(
[398] Fix | Delete
'fileId' => array(
[399] Fix | Delete
'location' => 'path',
[400] Fix | Delete
'type' => 'string',
[401] Fix | Delete
'required' => true,
[402] Fix | Delete
),
[403] Fix | Delete
'commentId' => array(
[404] Fix | Delete
'location' => 'path',
[405] Fix | Delete
'type' => 'string',
[406] Fix | Delete
'required' => true,
[407] Fix | Delete
),
[408] Fix | Delete
),
[409] Fix | Delete
),
[410] Fix | Delete
)
[411] Fix | Delete
)
[412] Fix | Delete
);
[413] Fix | Delete
$this->files = new Google_Service_Drive_Files_Resource(
[414] Fix | Delete
$this,
[415] Fix | Delete
$this->serviceName,
[416] Fix | Delete
'files',
[417] Fix | Delete
array(
[418] Fix | Delete
'methods' => array(
[419] Fix | Delete
'copy' => array(
[420] Fix | Delete
'path' => 'files/{fileId}/copy',
[421] Fix | Delete
'httpMethod' => 'POST',
[422] Fix | Delete
'parameters' => array(
[423] Fix | Delete
'fileId' => array(
[424] Fix | Delete
'location' => 'path',
[425] Fix | Delete
'type' => 'string',
[426] Fix | Delete
'required' => true,
[427] Fix | Delete
),
[428] Fix | Delete
'convert' => array(
[429] Fix | Delete
'location' => 'query',
[430] Fix | Delete
'type' => 'boolean',
[431] Fix | Delete
),
[432] Fix | Delete
'ocrLanguage' => array(
[433] Fix | Delete
'location' => 'query',
[434] Fix | Delete
'type' => 'string',
[435] Fix | Delete
),
[436] Fix | Delete
'visibility' => array(
[437] Fix | Delete
'location' => 'query',
[438] Fix | Delete
'type' => 'string',
[439] Fix | Delete
),
[440] Fix | Delete
'pinned' => array(
[441] Fix | Delete
'location' => 'query',
[442] Fix | Delete
'type' => 'boolean',
[443] Fix | Delete
),
[444] Fix | Delete
'ocr' => array(
[445] Fix | Delete
'location' => 'query',
[446] Fix | Delete
'type' => 'boolean',
[447] Fix | Delete
),
[448] Fix | Delete
'timedTextTrackName' => array(
[449] Fix | Delete
'location' => 'query',
[450] Fix | Delete
'type' => 'string',
[451] Fix | Delete
),
[452] Fix | Delete
'timedTextLanguage' => array(
[453] Fix | Delete
'location' => 'query',
[454] Fix | Delete
'type' => 'string',
[455] Fix | Delete
),
[456] Fix | Delete
),
[457] Fix | Delete
),'delete' => array(
[458] Fix | Delete
'path' => 'files/{fileId}',
[459] Fix | Delete
'httpMethod' => 'DELETE',
[460] Fix | Delete
'parameters' => array(
[461] Fix | Delete
'fileId' => array(
[462] Fix | Delete
'location' => 'path',
[463] Fix | Delete
'type' => 'string',
[464] Fix | Delete
'required' => true,
[465] Fix | Delete
),
[466] Fix | Delete
),
[467] Fix | Delete
),'emptyTrash' => array(
[468] Fix | Delete
'path' => 'files/trash',
[469] Fix | Delete
'httpMethod' => 'DELETE',
[470] Fix | Delete
'parameters' => array(),
[471] Fix | Delete
),'get' => array(
[472] Fix | Delete
'path' => 'files/{fileId}',
[473] Fix | Delete
'httpMethod' => 'GET',
[474] Fix | Delete
'parameters' => array(
[475] Fix | Delete
'fileId' => array(
[476] Fix | Delete
'location' => 'path',
[477] Fix | Delete
'type' => 'string',
[478] Fix | Delete
'required' => true,
[479] Fix | Delete
),
[480] Fix | Delete
'acknowledgeAbuse' => array(
[481] Fix | Delete
'location' => 'query',
[482] Fix | Delete
'type' => 'boolean',
[483] Fix | Delete
),
[484] Fix | Delete
'updateViewedDate' => array(
[485] Fix | Delete
'location' => 'query',
[486] Fix | Delete
'type' => 'boolean',
[487] Fix | Delete
),
[488] Fix | Delete
'revisionId' => array(
[489] Fix | Delete
'location' => 'query',
[490] Fix | Delete
'type' => 'string',
[491] Fix | Delete
),
[492] Fix | Delete
'projection' => array(
[493] Fix | Delete
'location' => 'query',
[494] Fix | Delete
'type' => 'string',
[495] Fix | Delete
),
[496] Fix | Delete
),
[497] Fix | Delete
),'insert' => array(
[498] Fix | Delete
'path' => 'files',
[499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function