1<?php
2/*
3 * Copyright 2014 Google Inc.
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
6 * use this file except in compliance with the License. You may obtain a copy of
7 * the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14 * License for the specific language governing permissions and limitations under
15 * the License.
16 */
17
18/**
19 * The "processes" collection of methods.
20 * Typical usage is:
21 *  <code>
22 *   $scriptService = new Google_Service_Script(...);
23 *   $processes = $scriptService->processes;
24 *  </code>
25 */
26class Google_Service_Script_Resource_Processes extends Google_Service_Resource
27{
28  /**
29   * List information about processes made by or on behalf of a user, such as
30   * process type and current status. (processes.listProcesses)
31   *
32   * @param array $optParams Optional parameters.
33   *
34   * @opt_param int pageSize The maximum number of returned processes per page of
35   * results. Defaults to 50.
36   * @opt_param string pageToken The token for continuing a previous list request
37   * on the next page. This should be set to the value of `nextPageToken` from a
38   * previous response.
39   * @opt_param string userProcessFilter.deploymentId Optional field used to limit
40   * returned processes to those originating from projects with a specific
41   * deployment ID.
42   * @opt_param string userProcessFilter.endTime Optional field used to limit
43   * returned processes to those that completed on or before the given timestamp.
44   * @opt_param string userProcessFilter.functionName Optional field used to limit
45   * returned processes to those originating from a script function with the given
46   * function name.
47   * @opt_param string userProcessFilter.projectName Optional field used to limit
48   * returned processes to those originating from projects with project names
49   * containing a specific string.
50   * @opt_param string userProcessFilter.scriptId Optional field used to limit
51   * returned processes to those originating from projects with a specific script
52   * ID.
53   * @opt_param string userProcessFilter.startTime Optional field used to limit
54   * returned processes to those that were started on or after the given
55   * timestamp.
56   * @opt_param string userProcessFilter.statuses Optional field used to limit
57   * returned processes to those having one of the specified process statuses.
58   * @opt_param string userProcessFilter.types Optional field used to limit
59   * returned processes to those having one of the specified process types.
60   * @opt_param string userProcessFilter.userAccessLevels Optional field used to
61   * limit returned processes to those having one of the specified user access
62   * levels.
63   * @return Google_Service_Script_ListUserProcessesResponse
64   */
65  public function listProcesses($optParams = array())
66  {
67    $params = array();
68    $params = array_merge($params, $optParams);
69    return $this->call('list', array($params), "Google_Service_Script_ListUserProcessesResponse");
70  }
71  /**
72   * List information about a script's executed processes, such as process type
73   * and current status. (processes.listScriptProcesses)
74   *
75   * @param array $optParams Optional parameters.
76   *
77   * @opt_param int pageSize The maximum number of returned processes per page of
78   * results. Defaults to 50.
79   * @opt_param string pageToken The token for continuing a previous list request
80   * on the next page. This should be set to the value of `nextPageToken` from a
81   * previous response.
82   * @opt_param string scriptId The script ID of the project whose processes are
83   * listed.
84   * @opt_param string scriptProcessFilter.deploymentId Optional field used to
85   * limit returned processes to those originating from projects with a specific
86   * deployment ID.
87   * @opt_param string scriptProcessFilter.endTime Optional field used to limit
88   * returned processes to those that completed on or before the given timestamp.
89   * @opt_param string scriptProcessFilter.functionName Optional field used to
90   * limit returned processes to those originating from a script function with the
91   * given function name.
92   * @opt_param string scriptProcessFilter.startTime Optional field used to limit
93   * returned processes to those that were started on or after the given
94   * timestamp.
95   * @opt_param string scriptProcessFilter.statuses Optional field used to limit
96   * returned processes to those having one of the specified process statuses.
97   * @opt_param string scriptProcessFilter.types Optional field used to limit
98   * returned processes to those having one of the specified process types.
99   * @opt_param string scriptProcessFilter.userAccessLevels Optional field used to
100   * limit returned processes to those having one of the specified user access
101   * levels.
102   * @return Google_Service_Script_ListScriptProcessesResponse
103   */
104  public function listScriptProcesses($optParams = array())
105  {
106    $params = array();
107    $params = array_merge($params, $optParams);
108    return $this->call('listScriptProcesses', array($params), "Google_Service_Script_ListScriptProcessesResponse");
109  }
110}
111