Google_Service_Storage_Buckets_Resource

The "buckets" collection of methods.

Defined (1)

The class is defined in the following location(s).

/includes/api-libs/Google/Service/Storage.php  
  1. class Google_Service_Storage_Buckets_Resource extends Google_Service_Resource 
  2.  
  3. /** 
  4. * Permanently deletes an empty bucket. (buckets.delete) 
  5. * @param string $bucket Name of a bucket. 
  6. * @param array $optParams Optional parameters. 
  7. * @opt_param string ifMetagenerationMatch If set, only deletes the bucket if 
  8. * its metageneration matches this value. 
  9. * @opt_param string ifMetagenerationNotMatch If set, only deletes the bucket if 
  10. * its metageneration does not match this value. 
  11. */ 
  12. public function delete($bucket, $optParams = array()) 
  13. $params = array('bucket' => $bucket); 
  14. $params = array_merge($params, $optParams); 
  15. return $this->call('delete', array($params)); 
  16.  
  17. /** 
  18. * Returns metadata for the specified bucket. (buckets.get) 
  19. * @param string $bucket Name of a bucket. 
  20. * @param array $optParams Optional parameters. 
  21. * @opt_param string ifMetagenerationMatch Makes the return of the bucket 
  22. * metadata conditional on whether the bucket's current metageneration matches 
  23. * the given value. 
  24. * @opt_param string ifMetagenerationNotMatch Makes the return of the bucket 
  25. * metadata conditional on whether the bucket's current metageneration does not 
  26. * match the given value. 
  27. * @opt_param string projection Set of properties to return. Defaults to noAcl. 
  28. * @return Google_Service_Storage_Bucket 
  29. */ 
  30. public function get($bucket, $optParams = array()) 
  31. $params = array('bucket' => $bucket); 
  32. $params = array_merge($params, $optParams); 
  33. return $this->call('get', array($params), "Google_Service_Storage_Bucket"); 
  34.  
  35. /** 
  36. * Creates a new bucket. (buckets.insert) 
  37. * @param string $project A valid API project identifier. 
  38. * @param Google_Bucket $postBody 
  39. * @param array $optParams Optional parameters. 
  40. * @opt_param string predefinedAcl Apply a predefined set of access controls to 
  41. * this bucket. 
  42. * @opt_param string projection Set of properties to return. Defaults to noAcl,  
  43. * unless the bucket resource specifies acl or defaultObjectAcl properties, when 
  44. * it defaults to full. 
  45. * @opt_param string predefinedDefaultObjectAcl Apply a predefined set of 
  46. * default object access controls to this bucket. 
  47. * @return Google_Service_Storage_Bucket 
  48. */ 
  49. public function insert($project, Google_Service_Storage_Bucket $postBody, $optParams = array()) 
  50. $params = array('project' => $project, 'postBody' => $postBody); 
  51. $params = array_merge($params, $optParams); 
  52. return $this->call('insert', array($params), "Google_Service_Storage_Bucket"); 
  53.  
  54. /** 
  55. * Retrieves a list of buckets for a given project. (buckets.listBuckets) 
  56. * @param string $project A valid API project identifier. 
  57. * @param array $optParams Optional parameters. 
  58. * @opt_param string pageToken A previously-returned page token representing 
  59. * part of the larger set of results to view. 
  60. * @opt_param string prefix Filter results to buckets whose names begin with 
  61. * this prefix. 
  62. * @opt_param string projection Set of properties to return. Defaults to noAcl. 
  63. * @opt_param string maxResults Maximum number of buckets to return. 
  64. * @return Google_Service_Storage_Buckets 
  65. */ 
  66. public function listBuckets($project, $optParams = array()) 
  67. $params = array('project' => $project); 
  68. $params = array_merge($params, $optParams); 
  69. return $this->call('list', array($params), "Google_Service_Storage_Buckets"); 
  70.  
  71. /** 
  72. * Updates a bucket. This method supports patch semantics. (buckets.patch) 
  73. * @param string $bucket Name of a bucket. 
  74. * @param Google_Bucket $postBody 
  75. * @param array $optParams Optional parameters. 
  76. * @opt_param string projection Set of properties to return. Defaults to full. 
  77. * @opt_param string ifMetagenerationMatch Makes the return of the bucket 
  78. * metadata conditional on whether the bucket's current metageneration matches 
  79. * the given value. 
  80. * @opt_param string predefinedDefaultObjectAcl Apply a predefined set of 
  81. * default object access controls to this bucket. 
  82. * @opt_param string predefinedAcl Apply a predefined set of access controls to 
  83. * this bucket. 
  84. * @opt_param string ifMetagenerationNotMatch Makes the return of the bucket 
  85. * metadata conditional on whether the bucket's current metageneration does not 
  86. * match the given value. 
  87. * @return Google_Service_Storage_Bucket 
  88. */ 
  89. public function patch($bucket, Google_Service_Storage_Bucket $postBody, $optParams = array()) 
  90. $params = array('bucket' => $bucket, 'postBody' => $postBody); 
  91. $params = array_merge($params, $optParams); 
  92. return $this->call('patch', array($params), "Google_Service_Storage_Bucket"); 
  93.  
  94. /** 
  95. * Updates a bucket. (buckets.update) 
  96. * @param string $bucket Name of a bucket. 
  97. * @param Google_Bucket $postBody 
  98. * @param array $optParams Optional parameters. 
  99. * @opt_param string projection Set of properties to return. Defaults to full. 
  100. * @opt_param string ifMetagenerationMatch Makes the return of the bucket 
  101. * metadata conditional on whether the bucket's current metageneration matches 
  102. * the given value. 
  103. * @opt_param string predefinedDefaultObjectAcl Apply a predefined set of 
  104. * default object access controls to this bucket. 
  105. * @opt_param string predefinedAcl Apply a predefined set of access controls to 
  106. * this bucket. 
  107. * @opt_param string ifMetagenerationNotMatch Makes the return of the bucket 
  108. * metadata conditional on whether the bucket's current metageneration does not 
  109. * match the given value. 
  110. * @return Google_Service_Storage_Bucket 
  111. */ 
  112. public function update($bucket, Google_Service_Storage_Bucket $postBody, $optParams = array()) 
  113. $params = array('bucket' => $bucket, 'postBody' => $postBody); 
  114. $params = array_merge($params, $optParams); 
  115. return $this->call('update', array($params), "Google_Service_Storage_Bucket");