Google_KernelsServiceResource

The "kernels" collection of methods.

Defined (1)

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

/inc/google-api-php-client/src/contrib/Google_ComputeService.php  
  1. class Google_KernelsServiceResource extends Google_ServiceResource { 
  2.  
  3.  
  4. /** 
  5. * Retrieves the list of kernel resources available to the specified project. (kernels.list) 
  6. * @param string $project Name of the project scoping this request. 
  7. * @param array $optParams Optional parameters. 
  8. * @opt_param string filter Optional. Filter expression for filtering listed resources. 
  9. * @opt_param string pageToken Optional. Tag returned by a previous list request truncated by maxResults. Used to continue a previous list request. 
  10. * @opt_param string maxResults Optional. Maximum count of results to be returned. Maximum and default value is 100. 
  11. * @return Google_KernelList 
  12. */ 
  13. public function listKernels($project, $optParams = array()) { 
  14. $params = array('project' => $project); 
  15. $params = array_merge($params, $optParams); 
  16. $data = $this->__call('list', array($params)); 
  17. if ($this->useObjects()) { 
  18. return new Google_KernelList($data); 
  19. } else { 
  20. return $data; 
  21. /** 
  22. * Returns the specified kernel resource. (kernels.get) 
  23. * @param string $project Name of the project scoping this request. 
  24. * @param string $kernel Name of the kernel resource to return. 
  25. * @param array $optParams Optional parameters. 
  26. * @return Google_Kernel 
  27. */ 
  28. public function get($project, $kernel, $optParams = array()) { 
  29. $params = array('project' => $project, 'kernel' => $kernel); 
  30. $params = array_merge($params, $optParams); 
  31. $data = $this->__call('get', array($params)); 
  32. if ($this->useObjects()) { 
  33. return new Google_Kernel($data); 
  34. } else { 
  35. return $data;