gestione documentale avanzata 1 parte

This commit is contained in:
2026-05-28 09:34:28 +02:00
parent 3471befb1a
commit f2b0833b90
34482 changed files with 4312269 additions and 546 deletions
+69
View File
@@ -0,0 +1,69 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class Content extends \Google\Collection
{
protected $collection_key = 'files';
protected $filesType = ScriptFile::class;
protected $filesDataType = 'array';
/**
* The script project's Drive ID.
*
* @var string
*/
public $scriptId;
/**
* The list of script project files. One of the files is a script manifest; it
* must be named "appsscript", must have type of JSON, and include the
* manifest configurations for the project.
*
* @param ScriptFile[] $files
*/
public function setFiles($files)
{
$this->files = $files;
}
/**
* @return ScriptFile[]
*/
public function getFiles()
{
return $this->files;
}
/**
* The script project's Drive ID.
*
* @param string $scriptId
*/
public function setScriptId($scriptId)
{
$this->scriptId = $scriptId;
}
/**
* @return string
*/
public function getScriptId()
{
return $this->scriptId;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Content::class, 'Google_Service_Script_Content');
@@ -0,0 +1,74 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class CreateProjectRequest extends \Google\Model
{
/**
* The Drive ID of a parent file that the created script project is bound to.
* This is usually the ID of a Google Doc, Google Sheet, Google Form, or
* Google Slides file. If not set, a standalone script project is created.
*
* @var string
*/
public $parentId;
/**
* The title for the project.
*
* @var string
*/
public $title;
/**
* The Drive ID of a parent file that the created script project is bound to.
* This is usually the ID of a Google Doc, Google Sheet, Google Form, or
* Google Slides file. If not set, a standalone script project is created.
*
* @param string $parentId
*/
public function setParentId($parentId)
{
$this->parentId = $parentId;
}
/**
* @return string
*/
public function getParentId()
{
return $this->parentId;
}
/**
* The title for the project.
*
* @param string $title
*/
public function setTitle($title)
{
$this->title = $title;
}
/**
* @return string
*/
public function getTitle()
{
return $this->title;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(CreateProjectRequest::class, 'Google_Service_Script_CreateProjectRequest');
@@ -0,0 +1,107 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class Deployment extends \Google\Collection
{
protected $collection_key = 'entryPoints';
protected $deploymentConfigType = DeploymentConfig::class;
protected $deploymentConfigDataType = '';
/**
* The deployment ID for this deployment.
*
* @var string
*/
public $deploymentId;
protected $entryPointsType = EntryPoint::class;
protected $entryPointsDataType = 'array';
/**
* Last modified date time stamp.
*
* @var string
*/
public $updateTime;
/**
* The deployment configuration.
*
* @param DeploymentConfig $deploymentConfig
*/
public function setDeploymentConfig(DeploymentConfig $deploymentConfig)
{
$this->deploymentConfig = $deploymentConfig;
}
/**
* @return DeploymentConfig
*/
public function getDeploymentConfig()
{
return $this->deploymentConfig;
}
/**
* The deployment ID for this deployment.
*
* @param string $deploymentId
*/
public function setDeploymentId($deploymentId)
{
$this->deploymentId = $deploymentId;
}
/**
* @return string
*/
public function getDeploymentId()
{
return $this->deploymentId;
}
/**
* The deployment's entry points.
*
* @param EntryPoint[] $entryPoints
*/
public function setEntryPoints($entryPoints)
{
$this->entryPoints = $entryPoints;
}
/**
* @return EntryPoint[]
*/
public function getEntryPoints()
{
return $this->entryPoints;
}
/**
* Last modified date time stamp.
*
* @param string $updateTime
*/
public function setUpdateTime($updateTime)
{
$this->updateTime = $updateTime;
}
/**
* @return string
*/
public function getUpdateTime()
{
return $this->updateTime;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Deployment::class, 'Google_Service_Script_Deployment');
@@ -0,0 +1,114 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class DeploymentConfig extends \Google\Model
{
/**
* The description for this deployment.
*
* @var string
*/
public $description;
/**
* The manifest file name for this deployment.
*
* @var string
*/
public $manifestFileName;
/**
* The script project's Drive ID.
*
* @var string
*/
public $scriptId;
/**
* The version number on which this deployment is based.
*
* @var int
*/
public $versionNumber;
/**
* The description for this deployment.
*
* @param string $description
*/
public function setDescription($description)
{
$this->description = $description;
}
/**
* @return string
*/
public function getDescription()
{
return $this->description;
}
/**
* The manifest file name for this deployment.
*
* @param string $manifestFileName
*/
public function setManifestFileName($manifestFileName)
{
$this->manifestFileName = $manifestFileName;
}
/**
* @return string
*/
public function getManifestFileName()
{
return $this->manifestFileName;
}
/**
* The script project's Drive ID.
*
* @param string $scriptId
*/
public function setScriptId($scriptId)
{
$this->scriptId = $scriptId;
}
/**
* @return string
*/
public function getScriptId()
{
return $this->scriptId;
}
/**
* The version number on which this deployment is based.
*
* @param int $versionNumber
*/
public function setVersionNumber($versionNumber)
{
$this->versionNumber = $versionNumber;
}
/**
* @return int
*/
public function getVersionNumber()
{
return $this->versionNumber;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(DeploymentConfig::class, 'Google_Service_Script_DeploymentConfig');
@@ -0,0 +1,121 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class EntryPoint extends \Google\Model
{
/**
* An unspecified entry point.
*/
public const ENTRY_POINT_TYPE_ENTRY_POINT_TYPE_UNSPECIFIED = 'ENTRY_POINT_TYPE_UNSPECIFIED';
/**
* A web application entry point.
*/
public const ENTRY_POINT_TYPE_WEB_APP = 'WEB_APP';
/**
* An API executable entry point.
*/
public const ENTRY_POINT_TYPE_EXECUTION_API = 'EXECUTION_API';
/**
* An Add-On entry point.
*/
public const ENTRY_POINT_TYPE_ADD_ON = 'ADD_ON';
protected $addOnType = GoogleAppsScriptTypeAddOnEntryPoint::class;
protected $addOnDataType = '';
/**
* The type of the entry point.
*
* @var string
*/
public $entryPointType;
protected $executionApiType = GoogleAppsScriptTypeExecutionApiEntryPoint::class;
protected $executionApiDataType = '';
protected $webAppType = GoogleAppsScriptTypeWebAppEntryPoint::class;
protected $webAppDataType = '';
/**
* Add-on properties.
*
* @param GoogleAppsScriptTypeAddOnEntryPoint $addOn
*/
public function setAddOn(GoogleAppsScriptTypeAddOnEntryPoint $addOn)
{
$this->addOn = $addOn;
}
/**
* @return GoogleAppsScriptTypeAddOnEntryPoint
*/
public function getAddOn()
{
return $this->addOn;
}
/**
* The type of the entry point.
*
* Accepted values: ENTRY_POINT_TYPE_UNSPECIFIED, WEB_APP, EXECUTION_API,
* ADD_ON
*
* @param self::ENTRY_POINT_TYPE_* $entryPointType
*/
public function setEntryPointType($entryPointType)
{
$this->entryPointType = $entryPointType;
}
/**
* @return self::ENTRY_POINT_TYPE_*
*/
public function getEntryPointType()
{
return $this->entryPointType;
}
/**
* An entry point specification for Apps Script API execution calls.
*
* @param GoogleAppsScriptTypeExecutionApiEntryPoint $executionApi
*/
public function setExecutionApi(GoogleAppsScriptTypeExecutionApiEntryPoint $executionApi)
{
$this->executionApi = $executionApi;
}
/**
* @return GoogleAppsScriptTypeExecutionApiEntryPoint
*/
public function getExecutionApi()
{
return $this->executionApi;
}
/**
* An entry point specification for web apps.
*
* @param GoogleAppsScriptTypeWebAppEntryPoint $webApp
*/
public function setWebApp(GoogleAppsScriptTypeWebAppEntryPoint $webApp)
{
$this->webApp = $webApp;
}
/**
* @return GoogleAppsScriptTypeWebAppEntryPoint
*/
public function getWebApp()
{
return $this->webApp;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(EntryPoint::class, 'Google_Service_Script_EntryPoint');
@@ -0,0 +1,42 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ExecuteStreamResponse extends \Google\Model
{
protected $resultType = ScriptExecutionResult::class;
protected $resultDataType = '';
/**
* @param ScriptExecutionResult
*/
public function setResult(ScriptExecutionResult $result)
{
$this->result = $result;
}
/**
* @return ScriptExecutionResult
*/
public function getResult()
{
return $this->result;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ExecuteStreamResponse::class, 'Google_Service_Script_ExecuteStreamResponse');
@@ -0,0 +1,94 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ExecutionError extends \Google\Collection
{
protected $collection_key = 'scriptStackTraceElements';
/**
* The error message thrown by Apps Script, usually localized into the user's
* language.
*
* @var string
*/
public $errorMessage;
/**
* The error type, for example `TypeError` or `ReferenceError`. If the error
* type is unavailable, this field is not included.
*
* @var string
*/
public $errorType;
protected $scriptStackTraceElementsType = ScriptStackTraceElement::class;
protected $scriptStackTraceElementsDataType = 'array';
/**
* The error message thrown by Apps Script, usually localized into the user's
* language.
*
* @param string $errorMessage
*/
public function setErrorMessage($errorMessage)
{
$this->errorMessage = $errorMessage;
}
/**
* @return string
*/
public function getErrorMessage()
{
return $this->errorMessage;
}
/**
* The error type, for example `TypeError` or `ReferenceError`. If the error
* type is unavailable, this field is not included.
*
* @param string $errorType
*/
public function setErrorType($errorType)
{
$this->errorType = $errorType;
}
/**
* @return string
*/
public function getErrorType()
{
return $this->errorType;
}
/**
* An array of objects that provide a stack trace through the script to show
* where the execution failed, with the deepest call first.
*
* @param ScriptStackTraceElement[] $scriptStackTraceElements
*/
public function setScriptStackTraceElements($scriptStackTraceElements)
{
$this->scriptStackTraceElements = $scriptStackTraceElements;
}
/**
* @return ScriptStackTraceElement[]
*/
public function getScriptStackTraceElements()
{
return $this->scriptStackTraceElements;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ExecutionError::class, 'Google_Service_Script_ExecutionError');
@@ -0,0 +1,149 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ExecutionRequest extends \Google\Collection
{
protected $collection_key = 'parameters';
/**
* If `true` and the user is an owner of the script, the script runs at the
* most recently saved version rather than the version deployed for use with
* the Apps Script API. Optional; default is `false`.
*
* @var bool
*/
public $devMode;
/**
* The name of the function to execute in the given script. The name does not
* include parentheses or parameters. It can reference a function in an
* included library such as `Library.libFunction1`.
*
* @var string
*/
public $function;
/**
* The parameters to be passed to the function being executed. The object type
* for each parameter should match the expected type in Apps Script.
* Parameters cannot be Apps Script-specific object types (such as a
* `Document` or a `Calendar`); they can only be primitive types such as
* `string`, `number`, `array`, `object`, or `boolean`. Optional.
*
* @var array[]
*/
public $parameters;
/**
* *Deprecated*. For use with Android add-ons only. An ID that represents the
* user's current session in the Android app for Google Docs or Sheets,
* included as extra data in the
* [Intent](https://developer.android.com/guide/components/intents-
* filters.html) that launches the add-on. When an Android add-on is run with
* a session state, it gains the privileges of a
* [bound](https://developers.google.com/apps-script/guides/bound) script—that
* is, it can access information like the user's current cursor position (in
* Docs) or selected cell (in Sheets). To retrieve the state, call `Intent.get
* StringExtra("com.google.android.apps.docs.addons.SessionState")`. Optional.
*
* @var string
*/
public $sessionState;
/**
* If `true` and the user is an owner of the script, the script runs at the
* most recently saved version rather than the version deployed for use with
* the Apps Script API. Optional; default is `false`.
*
* @param bool $devMode
*/
public function setDevMode($devMode)
{
$this->devMode = $devMode;
}
/**
* @return bool
*/
public function getDevMode()
{
return $this->devMode;
}
/**
* The name of the function to execute in the given script. The name does not
* include parentheses or parameters. It can reference a function in an
* included library such as `Library.libFunction1`.
*
* @param string $function
*/
public function setFunction($function)
{
$this->function = $function;
}
/**
* @return string
*/
public function getFunction()
{
return $this->function;
}
/**
* The parameters to be passed to the function being executed. The object type
* for each parameter should match the expected type in Apps Script.
* Parameters cannot be Apps Script-specific object types (such as a
* `Document` or a `Calendar`); they can only be primitive types such as
* `string`, `number`, `array`, `object`, or `boolean`. Optional.
*
* @param array[] $parameters
*/
public function setParameters($parameters)
{
$this->parameters = $parameters;
}
/**
* @return array[]
*/
public function getParameters()
{
return $this->parameters;
}
/**
* *Deprecated*. For use with Android add-ons only. An ID that represents the
* user's current session in the Android app for Google Docs or Sheets,
* included as extra data in the
* [Intent](https://developer.android.com/guide/components/intents-
* filters.html) that launches the add-on. When an Android add-on is run with
* a session state, it gains the privileges of a
* [bound](https://developers.google.com/apps-script/guides/bound) script—that
* is, it can access information like the user's current cursor position (in
* Docs) or selected cell (in Sheets). To retrieve the state, call `Intent.get
* StringExtra("com.google.android.apps.docs.addons.SessionState")`. Optional.
*
* @param string $sessionState
*/
public function setSessionState($sessionState)
{
$this->sessionState = $sessionState;
}
/**
* @return string
*/
public function getSessionState()
{
return $this->sessionState;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ExecutionRequest::class, 'Google_Service_Script_ExecutionRequest');
@@ -0,0 +1,56 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ExecutionResponse extends \Google\Model
{
/**
* The return value of the script function. The type matches the object type
* returned in Apps Script. Functions called using the Apps Script API cannot
* return Apps Script-specific objects (such as a `Document` or a `Calendar`);
* they can only return primitive types such as a `string`, `number`, `array`,
* `object`, or `boolean`.
*
* @var array
*/
public $result;
/**
* The return value of the script function. The type matches the object type
* returned in Apps Script. Functions called using the Apps Script API cannot
* return Apps Script-specific objects (such as a `Document` or a `Calendar`);
* they can only return primitive types such as a `string`, `number`, `array`,
* `object`, or `boolean`.
*
* @param array $result
*/
public function setResult($result)
{
$this->result = $result;
}
/**
* @return array
*/
public function getResult()
{
return $this->result;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ExecutionResponse::class, 'Google_Service_Script_ExecutionResponse');
@@ -0,0 +1,172 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class GoogleAppsScriptTypeAddOnEntryPoint extends \Google\Model
{
/**
* Default value, unknown add-on type.
*/
public const ADD_ON_TYPE_UNKNOWN_ADDON_TYPE = 'UNKNOWN_ADDON_TYPE';
/**
* Add-on type for Gmail.
*/
public const ADD_ON_TYPE_GMAIL = 'GMAIL';
/**
* Add-on type for Data Studio.
*/
public const ADD_ON_TYPE_DATA_STUDIO = 'DATA_STUDIO';
/**
* The add-on's required list of supported container types.
*
* @var string
*/
public $addOnType;
/**
* The add-on's optional description.
*
* @var string
*/
public $description;
/**
* The add-on's optional help URL.
*
* @var string
*/
public $helpUrl;
/**
* The add-on's required post install tip URL.
*
* @var string
*/
public $postInstallTipUrl;
/**
* The add-on's optional report issue URL.
*
* @var string
*/
public $reportIssueUrl;
/**
* The add-on's required title.
*
* @var string
*/
public $title;
/**
* The add-on's required list of supported container types.
*
* Accepted values: UNKNOWN_ADDON_TYPE, GMAIL, DATA_STUDIO
*
* @param self::ADD_ON_TYPE_* $addOnType
*/
public function setAddOnType($addOnType)
{
$this->addOnType = $addOnType;
}
/**
* @return self::ADD_ON_TYPE_*
*/
public function getAddOnType()
{
return $this->addOnType;
}
/**
* The add-on's optional description.
*
* @param string $description
*/
public function setDescription($description)
{
$this->description = $description;
}
/**
* @return string
*/
public function getDescription()
{
return $this->description;
}
/**
* The add-on's optional help URL.
*
* @param string $helpUrl
*/
public function setHelpUrl($helpUrl)
{
$this->helpUrl = $helpUrl;
}
/**
* @return string
*/
public function getHelpUrl()
{
return $this->helpUrl;
}
/**
* The add-on's required post install tip URL.
*
* @param string $postInstallTipUrl
*/
public function setPostInstallTipUrl($postInstallTipUrl)
{
$this->postInstallTipUrl = $postInstallTipUrl;
}
/**
* @return string
*/
public function getPostInstallTipUrl()
{
return $this->postInstallTipUrl;
}
/**
* The add-on's optional report issue URL.
*
* @param string $reportIssueUrl
*/
public function setReportIssueUrl($reportIssueUrl)
{
$this->reportIssueUrl = $reportIssueUrl;
}
/**
* @return string
*/
public function getReportIssueUrl()
{
return $this->reportIssueUrl;
}
/**
* The add-on's required title.
*
* @param string $title
*/
public function setTitle($title)
{
$this->title = $title;
}
/**
* @return string
*/
public function getTitle()
{
return $this->title;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GoogleAppsScriptTypeAddOnEntryPoint::class, 'Google_Service_Script_GoogleAppsScriptTypeAddOnEntryPoint');
@@ -0,0 +1,72 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class GoogleAppsScriptTypeExecutionApiConfig extends \Google\Model
{
/**
* Default value, should not be used.
*/
public const ACCESS_UNKNOWN_ACCESS = 'UNKNOWN_ACCESS';
/**
* Only the user who deployed the web app or executable can access it. Note
* that this is not necessarily the owner of the script project.
*/
public const ACCESS_MYSELF = 'MYSELF';
/**
* Only users in the same domain as the user who deployed the web app or
* executable can access it.
*/
public const ACCESS_DOMAIN = 'DOMAIN';
/**
* Any logged in user can access the web app or executable.
*/
public const ACCESS_ANYONE = 'ANYONE';
/**
* Any user, logged in or not, can access the web app or executable.
*/
public const ACCESS_ANYONE_ANONYMOUS = 'ANYONE_ANONYMOUS';
/**
* Who has permission to run the API executable.
*
* @var string
*/
public $access;
/**
* Who has permission to run the API executable.
*
* Accepted values: UNKNOWN_ACCESS, MYSELF, DOMAIN, ANYONE, ANYONE_ANONYMOUS
*
* @param self::ACCESS_* $access
*/
public function setAccess($access)
{
$this->access = $access;
}
/**
* @return self::ACCESS_*
*/
public function getAccess()
{
return $this->access;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GoogleAppsScriptTypeExecutionApiConfig::class, 'Google_Service_Script_GoogleAppsScriptTypeExecutionApiConfig');
@@ -0,0 +1,44 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class GoogleAppsScriptTypeExecutionApiEntryPoint extends \Google\Model
{
protected $entryPointConfigType = GoogleAppsScriptTypeExecutionApiConfig::class;
protected $entryPointConfigDataType = '';
/**
* The entry point's configuration.
*
* @param GoogleAppsScriptTypeExecutionApiConfig $entryPointConfig
*/
public function setEntryPointConfig(GoogleAppsScriptTypeExecutionApiConfig $entryPointConfig)
{
$this->entryPointConfig = $entryPointConfig;
}
/**
* @return GoogleAppsScriptTypeExecutionApiConfig
*/
public function getEntryPointConfig()
{
return $this->entryPointConfig;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GoogleAppsScriptTypeExecutionApiEntryPoint::class, 'Google_Service_Script_GoogleAppsScriptTypeExecutionApiEntryPoint');
@@ -0,0 +1,71 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class GoogleAppsScriptTypeFunction extends \Google\Collection
{
protected $collection_key = 'parameters';
/**
* The function name in the script project.
*
* @var string
*/
public $name;
/**
* The ordered list of parameter names of the function in the script project.
*
* @var string[]
*/
public $parameters;
/**
* The function name in the script project.
*
* @param string $name
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* The ordered list of parameter names of the function in the script project.
*
* @param string[] $parameters
*/
public function setParameters($parameters)
{
$this->parameters = $parameters;
}
/**
* @return string[]
*/
public function getParameters()
{
return $this->parameters;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GoogleAppsScriptTypeFunction::class, 'Google_Service_Script_GoogleAppsScriptTypeFunction');
@@ -0,0 +1,45 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class GoogleAppsScriptTypeFunctionSet extends \Google\Collection
{
protected $collection_key = 'values';
protected $valuesType = GoogleAppsScriptTypeFunction::class;
protected $valuesDataType = 'array';
/**
* A list of functions composing the set.
*
* @param GoogleAppsScriptTypeFunction[] $values
*/
public function setValues($values)
{
$this->values = $values;
}
/**
* @return GoogleAppsScriptTypeFunction[]
*/
public function getValues()
{
return $this->values;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GoogleAppsScriptTypeFunctionSet::class, 'Google_Service_Script_GoogleAppsScriptTypeFunctionSet');
@@ -0,0 +1,324 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class GoogleAppsScriptTypeProcess extends \Google\Model
{
/**
* Unspecified status.
*/
public const PROCESS_STATUS_PROCESS_STATUS_UNSPECIFIED = 'PROCESS_STATUS_UNSPECIFIED';
/**
* The process is currently running.
*/
public const PROCESS_STATUS_RUNNING = 'RUNNING';
/**
* The process has paused.
*/
public const PROCESS_STATUS_PAUSED = 'PAUSED';
/**
* The process has completed.
*/
public const PROCESS_STATUS_COMPLETED = 'COMPLETED';
/**
* The process was cancelled.
*/
public const PROCESS_STATUS_CANCELED = 'CANCELED';
/**
* The process failed.
*/
public const PROCESS_STATUS_FAILED = 'FAILED';
/**
* The process timed out.
*/
public const PROCESS_STATUS_TIMED_OUT = 'TIMED_OUT';
/**
* Process status unknown.
*/
public const PROCESS_STATUS_UNKNOWN = 'UNKNOWN';
/**
* The process is delayed, waiting for quota.
*/
public const PROCESS_STATUS_DELAYED = 'DELAYED';
/**
* AppsScript executions are disabled by Admin.
*/
public const PROCESS_STATUS_EXECUTION_DISABLED = 'EXECUTION_DISABLED';
/**
* Unspecified type.
*/
public const PROCESS_TYPE_PROCESS_TYPE_UNSPECIFIED = 'PROCESS_TYPE_UNSPECIFIED';
/**
* The process was started from an add-on entry point.
*/
public const PROCESS_TYPE_ADD_ON = 'ADD_ON';
/**
* The process was started using the Apps Script API.
*/
public const PROCESS_TYPE_EXECUTION_API = 'EXECUTION_API';
/**
* The process was started from a time-based trigger.
*/
public const PROCESS_TYPE_TIME_DRIVEN = 'TIME_DRIVEN';
/**
* The process was started from an event-based trigger.
*/
public const PROCESS_TYPE_TRIGGER = 'TRIGGER';
/**
* The process was started from a web app entry point.
*/
public const PROCESS_TYPE_WEBAPP = 'WEBAPP';
/**
* The process was started using the Apps Script IDE.
*/
public const PROCESS_TYPE_EDITOR = 'EDITOR';
/**
* The process was started from a G Suite simple trigger.
*/
public const PROCESS_TYPE_SIMPLE_TRIGGER = 'SIMPLE_TRIGGER';
/**
* The process was started from a G Suite menu item.
*/
public const PROCESS_TYPE_MENU = 'MENU';
/**
* The process was started as a task in a batch job.
*/
public const PROCESS_TYPE_BATCH_TASK = 'BATCH_TASK';
/**
* Runtime version unset / unknown.
*/
public const RUNTIME_VERSION_RUNTIME_VERSION_UNSPECIFIED = 'RUNTIME_VERSION_UNSPECIFIED';
/**
* Legacy rhino version of the Apps script runtime
*/
public const RUNTIME_VERSION_DEPRECATED_ES5 = 'DEPRECATED_ES5';
/**
* Current default V8 version of the apps script runtime.
*/
public const RUNTIME_VERSION_V8 = 'V8';
/**
* User access level unspecified
*/
public const USER_ACCESS_LEVEL_USER_ACCESS_LEVEL_UNSPECIFIED = 'USER_ACCESS_LEVEL_UNSPECIFIED';
/**
* The user has no access.
*/
public const USER_ACCESS_LEVEL_NONE = 'NONE';
/**
* The user has read-only access.
*/
public const USER_ACCESS_LEVEL_READ = 'READ';
/**
* The user has write access.
*/
public const USER_ACCESS_LEVEL_WRITE = 'WRITE';
/**
* The user is an owner.
*/
public const USER_ACCESS_LEVEL_OWNER = 'OWNER';
/**
* Duration the execution spent executing.
*
* @var string
*/
public $duration;
/**
* Name of the function the started the execution.
*
* @var string
*/
public $functionName;
/**
* The executions status.
*
* @var string
*/
public $processStatus;
/**
* The executions type.
*
* @var string
*/
public $processType;
/**
* Name of the script being executed.
*
* @var string
*/
public $projectName;
/**
* Which version of maestro to use to execute the script.
*
* @var string
*/
public $runtimeVersion;
/**
* Time the execution started.
*
* @var string
*/
public $startTime;
/**
* The executing users access level to the script.
*
* @var string
*/
public $userAccessLevel;
/**
* Duration the execution spent executing.
*
* @param string $duration
*/
public function setDuration($duration)
{
$this->duration = $duration;
}
/**
* @return string
*/
public function getDuration()
{
return $this->duration;
}
/**
* Name of the function the started the execution.
*
* @param string $functionName
*/
public function setFunctionName($functionName)
{
$this->functionName = $functionName;
}
/**
* @return string
*/
public function getFunctionName()
{
return $this->functionName;
}
/**
* The executions status.
*
* Accepted values: PROCESS_STATUS_UNSPECIFIED, RUNNING, PAUSED, COMPLETED,
* CANCELED, FAILED, TIMED_OUT, UNKNOWN, DELAYED, EXECUTION_DISABLED
*
* @param self::PROCESS_STATUS_* $processStatus
*/
public function setProcessStatus($processStatus)
{
$this->processStatus = $processStatus;
}
/**
* @return self::PROCESS_STATUS_*
*/
public function getProcessStatus()
{
return $this->processStatus;
}
/**
* The executions type.
*
* Accepted values: PROCESS_TYPE_UNSPECIFIED, ADD_ON, EXECUTION_API,
* TIME_DRIVEN, TRIGGER, WEBAPP, EDITOR, SIMPLE_TRIGGER, MENU, BATCH_TASK
*
* @param self::PROCESS_TYPE_* $processType
*/
public function setProcessType($processType)
{
$this->processType = $processType;
}
/**
* @return self::PROCESS_TYPE_*
*/
public function getProcessType()
{
return $this->processType;
}
/**
* Name of the script being executed.
*
* @param string $projectName
*/
public function setProjectName($projectName)
{
$this->projectName = $projectName;
}
/**
* @return string
*/
public function getProjectName()
{
return $this->projectName;
}
/**
* Which version of maestro to use to execute the script.
*
* Accepted values: RUNTIME_VERSION_UNSPECIFIED, DEPRECATED_ES5, V8
*
* @param self::RUNTIME_VERSION_* $runtimeVersion
*/
public function setRuntimeVersion($runtimeVersion)
{
$this->runtimeVersion = $runtimeVersion;
}
/**
* @return self::RUNTIME_VERSION_*
*/
public function getRuntimeVersion()
{
return $this->runtimeVersion;
}
/**
* Time the execution started.
*
* @param string $startTime
*/
public function setStartTime($startTime)
{
$this->startTime = $startTime;
}
/**
* @return string
*/
public function getStartTime()
{
return $this->startTime;
}
/**
* The executing users access level to the script.
*
* Accepted values: USER_ACCESS_LEVEL_UNSPECIFIED, NONE, READ, WRITE, OWNER
*
* @param self::USER_ACCESS_LEVEL_* $userAccessLevel
*/
public function setUserAccessLevel($userAccessLevel)
{
$this->userAccessLevel = $userAccessLevel;
}
/**
* @return self::USER_ACCESS_LEVEL_*
*/
public function getUserAccessLevel()
{
return $this->userAccessLevel;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GoogleAppsScriptTypeProcess::class, 'Google_Service_Script_GoogleAppsScriptTypeProcess');
@@ -0,0 +1,114 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class GoogleAppsScriptTypeUser extends \Google\Model
{
/**
* The user's domain.
*
* @var string
*/
public $domain;
/**
* The user's identifying email address.
*
* @var string
*/
public $email;
/**
* The user's display name.
*
* @var string
*/
public $name;
/**
* The user's photo.
*
* @var string
*/
public $photoUrl;
/**
* The user's domain.
*
* @param string $domain
*/
public function setDomain($domain)
{
$this->domain = $domain;
}
/**
* @return string
*/
public function getDomain()
{
return $this->domain;
}
/**
* The user's identifying email address.
*
* @param string $email
*/
public function setEmail($email)
{
$this->email = $email;
}
/**
* @return string
*/
public function getEmail()
{
return $this->email;
}
/**
* The user's display name.
*
* @param string $name
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* The user's photo.
*
* @param string $photoUrl
*/
public function setPhotoUrl($photoUrl)
{
$this->photoUrl = $photoUrl;
}
/**
* @return string
*/
public function getPhotoUrl()
{
return $this->photoUrl;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GoogleAppsScriptTypeUser::class, 'Google_Service_Script_GoogleAppsScriptTypeUser');
@@ -0,0 +1,109 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class GoogleAppsScriptTypeWebAppConfig extends \Google\Model
{
/**
* Default value, should not be used.
*/
public const ACCESS_UNKNOWN_ACCESS = 'UNKNOWN_ACCESS';
/**
* Only the user who deployed the web app or executable can access it. Note
* that this is not necessarily the owner of the script project.
*/
public const ACCESS_MYSELF = 'MYSELF';
/**
* Only users in the same domain as the user who deployed the web app or
* executable can access it.
*/
public const ACCESS_DOMAIN = 'DOMAIN';
/**
* Any logged in user can access the web app or executable.
*/
public const ACCESS_ANYONE = 'ANYONE';
/**
* Any user, logged in or not, can access the web app or executable.
*/
public const ACCESS_ANYONE_ANONYMOUS = 'ANYONE_ANONYMOUS';
/**
* Default value, should not be used.
*/
public const EXECUTE_AS_UNKNOWN_EXECUTE_AS = 'UNKNOWN_EXECUTE_AS';
/**
* The script runs as the user accessing the web app.
*/
public const EXECUTE_AS_USER_ACCESSING = 'USER_ACCESSING';
/**
* The script runs as the user who deployed the web app. Note that this is not
* necessarily the owner of the script project.
*/
public const EXECUTE_AS_USER_DEPLOYING = 'USER_DEPLOYING';
/**
* Who has permission to run the web app.
*
* @var string
*/
public $access;
/**
* Who to execute the web app as.
*
* @var string
*/
public $executeAs;
/**
* Who has permission to run the web app.
*
* Accepted values: UNKNOWN_ACCESS, MYSELF, DOMAIN, ANYONE, ANYONE_ANONYMOUS
*
* @param self::ACCESS_* $access
*/
public function setAccess($access)
{
$this->access = $access;
}
/**
* @return self::ACCESS_*
*/
public function getAccess()
{
return $this->access;
}
/**
* Who to execute the web app as.
*
* Accepted values: UNKNOWN_EXECUTE_AS, USER_ACCESSING, USER_DEPLOYING
*
* @param self::EXECUTE_AS_* $executeAs
*/
public function setExecuteAs($executeAs)
{
$this->executeAs = $executeAs;
}
/**
* @return self::EXECUTE_AS_*
*/
public function getExecuteAs()
{
return $this->executeAs;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GoogleAppsScriptTypeWebAppConfig::class, 'Google_Service_Script_GoogleAppsScriptTypeWebAppConfig');
@@ -0,0 +1,66 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class GoogleAppsScriptTypeWebAppEntryPoint extends \Google\Model
{
protected $entryPointConfigType = GoogleAppsScriptTypeWebAppConfig::class;
protected $entryPointConfigDataType = '';
/**
* The URL for the web application.
*
* @var string
*/
public $url;
/**
* The entry point's configuration.
*
* @param GoogleAppsScriptTypeWebAppConfig $entryPointConfig
*/
public function setEntryPointConfig(GoogleAppsScriptTypeWebAppConfig $entryPointConfig)
{
$this->entryPointConfig = $entryPointConfig;
}
/**
* @return GoogleAppsScriptTypeWebAppConfig
*/
public function getEntryPointConfig()
{
return $this->entryPointConfig;
}
/**
* The URL for the web application.
*
* @param string $url
*/
public function setUrl($url)
{
$this->url = $url;
}
/**
* @return string
*/
public function getUrl()
{
return $this->url;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GoogleAppsScriptTypeWebAppEntryPoint::class, 'Google_Service_Script_GoogleAppsScriptTypeWebAppEntryPoint');
@@ -0,0 +1,69 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ListDeploymentsResponse extends \Google\Collection
{
protected $collection_key = 'deployments';
protected $deploymentsType = Deployment::class;
protected $deploymentsDataType = 'array';
/**
* The token that can be used in the next call to get the next page of
* results.
*
* @var string
*/
public $nextPageToken;
/**
* The list of deployments.
*
* @param Deployment[] $deployments
*/
public function setDeployments($deployments)
{
$this->deployments = $deployments;
}
/**
* @return Deployment[]
*/
public function getDeployments()
{
return $this->deployments;
}
/**
* The token that can be used in the next call to get the next page of
* results.
*
* @param string $nextPageToken
*/
public function setNextPageToken($nextPageToken)
{
$this->nextPageToken = $nextPageToken;
}
/**
* @return string
*/
public function getNextPageToken()
{
return $this->nextPageToken;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListDeploymentsResponse::class, 'Google_Service_Script_ListDeploymentsResponse');
@@ -0,0 +1,69 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ListScriptProcessesResponse extends \Google\Collection
{
protected $collection_key = 'processes';
/**
* Token for the next page of results. If empty, there are no more pages
* remaining.
*
* @var string
*/
public $nextPageToken;
protected $processesType = GoogleAppsScriptTypeProcess::class;
protected $processesDataType = 'array';
/**
* Token for the next page of results. If empty, there are no more pages
* remaining.
*
* @param string $nextPageToken
*/
public function setNextPageToken($nextPageToken)
{
$this->nextPageToken = $nextPageToken;
}
/**
* @return string
*/
public function getNextPageToken()
{
return $this->nextPageToken;
}
/**
* List of processes matching request parameters.
*
* @param GoogleAppsScriptTypeProcess[] $processes
*/
public function setProcesses($processes)
{
$this->processes = $processes;
}
/**
* @return GoogleAppsScriptTypeProcess[]
*/
public function getProcesses()
{
return $this->processes;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListScriptProcessesResponse::class, 'Google_Service_Script_ListScriptProcessesResponse');
@@ -0,0 +1,69 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ListUserProcessesResponse extends \Google\Collection
{
protected $collection_key = 'processes';
/**
* Token for the next page of results. If empty, there are no more pages
* remaining.
*
* @var string
*/
public $nextPageToken;
protected $processesType = GoogleAppsScriptTypeProcess::class;
protected $processesDataType = 'array';
/**
* Token for the next page of results. If empty, there are no more pages
* remaining.
*
* @param string $nextPageToken
*/
public function setNextPageToken($nextPageToken)
{
$this->nextPageToken = $nextPageToken;
}
/**
* @return string
*/
public function getNextPageToken()
{
return $this->nextPageToken;
}
/**
* List of processes matching request parameters.
*
* @param GoogleAppsScriptTypeProcess[] $processes
*/
public function setProcesses($processes)
{
$this->processes = $processes;
}
/**
* @return GoogleAppsScriptTypeProcess[]
*/
public function getProcesses()
{
return $this->processes;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListUserProcessesResponse::class, 'Google_Service_Script_ListUserProcessesResponse');
@@ -0,0 +1,43 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ListValue extends \Google\Collection
{
protected $collection_key = 'values';
protected $valuesType = Value::class;
protected $valuesDataType = 'array';
/**
* @param Value[]
*/
public function setValues($values)
{
$this->values = $values;
}
/**
* @return Value[]
*/
public function getValues()
{
return $this->values;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListValue::class, 'Google_Service_Script_ListValue');
@@ -0,0 +1,69 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ListVersionsResponse extends \Google\Collection
{
protected $collection_key = 'versions';
/**
* The token use to fetch the next page of records. if not exist in the
* response, that means no more versions to list.
*
* @var string
*/
public $nextPageToken;
protected $versionsType = Version::class;
protected $versionsDataType = 'array';
/**
* The token use to fetch the next page of records. if not exist in the
* response, that means no more versions to list.
*
* @param string $nextPageToken
*/
public function setNextPageToken($nextPageToken)
{
$this->nextPageToken = $nextPageToken;
}
/**
* @return string
*/
public function getNextPageToken()
{
return $this->nextPageToken;
}
/**
* The list of versions.
*
* @param Version[] $versions
*/
public function setVersions($versions)
{
$this->versions = $versions;
}
/**
* @return Version[]
*/
public function getVersions()
{
return $this->versions;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListVersionsResponse::class, 'Google_Service_Script_ListVersionsResponse');
+81
View File
@@ -0,0 +1,81 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class Metrics extends \Google\Collection
{
protected $collection_key = 'totalExecutions';
protected $activeUsersType = MetricsValue::class;
protected $activeUsersDataType = 'array';
protected $failedExecutionsType = MetricsValue::class;
protected $failedExecutionsDataType = 'array';
protected $totalExecutionsType = MetricsValue::class;
protected $totalExecutionsDataType = 'array';
/**
* Number of active users.
*
* @param MetricsValue[] $activeUsers
*/
public function setActiveUsers($activeUsers)
{
$this->activeUsers = $activeUsers;
}
/**
* @return MetricsValue[]
*/
public function getActiveUsers()
{
return $this->activeUsers;
}
/**
* Number of failed executions.
*
* @param MetricsValue[] $failedExecutions
*/
public function setFailedExecutions($failedExecutions)
{
$this->failedExecutions = $failedExecutions;
}
/**
* @return MetricsValue[]
*/
public function getFailedExecutions()
{
return $this->failedExecutions;
}
/**
* Number of total executions.
*
* @param MetricsValue[] $totalExecutions
*/
public function setTotalExecutions($totalExecutions)
{
$this->totalExecutions = $totalExecutions;
}
/**
* @return MetricsValue[]
*/
public function getTotalExecutions()
{
return $this->totalExecutions;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Metrics::class, 'Google_Service_Script_Metrics');
@@ -0,0 +1,92 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class MetricsValue extends \Google\Model
{
/**
* Required field indicating the end time of the interval.
*
* @var string
*/
public $endTime;
/**
* Required field indicating the start time of the interval.
*
* @var string
*/
public $startTime;
/**
* Indicates the number of executions counted.
*
* @var string
*/
public $value;
/**
* Required field indicating the end time of the interval.
*
* @param string $endTime
*/
public function setEndTime($endTime)
{
$this->endTime = $endTime;
}
/**
* @return string
*/
public function getEndTime()
{
return $this->endTime;
}
/**
* Required field indicating the start time of the interval.
*
* @param string $startTime
*/
public function setStartTime($startTime)
{
$this->startTime = $startTime;
}
/**
* @return string
*/
public function getStartTime()
{
return $this->startTime;
}
/**
* Indicates the number of executions counted.
*
* @param string $value
*/
public function setValue($value)
{
$this->value = $value;
}
/**
* @return string
*/
public function getValue()
{
return $this->value;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(MetricsValue::class, 'Google_Service_Script_MetricsValue');
@@ -0,0 +1,97 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class Operation extends \Google\Model
{
/**
* This field indicates whether the script execution has completed. A
* completed execution has a populated `response` field containing the
* ExecutionResponse from function that was executed.
*
* @var bool
*/
public $done;
protected $errorType = Status::class;
protected $errorDataType = '';
/**
* If the script function returns successfully, this field contains an
* ExecutionResponse object with the function's return value.
*
* @var array[]
*/
public $response;
/**
* This field indicates whether the script execution has completed. A
* completed execution has a populated `response` field containing the
* ExecutionResponse from function that was executed.
*
* @param bool $done
*/
public function setDone($done)
{
$this->done = $done;
}
/**
* @return bool
*/
public function getDone()
{
return $this->done;
}
/**
* If a `run` call succeeds but the script function (or Apps Script itself)
* throws an exception, this field contains a Status object. The `Status`
* object's `details` field contains an array with a single ExecutionError
* object that provides information about the nature of the error.
*
* @param Status $error
*/
public function setError(Status $error)
{
$this->error = $error;
}
/**
* @return Status
*/
public function getError()
{
return $this->error;
}
/**
* If the script function returns successfully, this field contains an
* ExecutionResponse object with the function's return value.
*
* @param array[] $response
*/
public function setResponse($response)
{
$this->response = $response;
}
/**
* @return array[]
*/
public function getResponse()
{
return $this->response;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Operation::class, 'Google_Service_Script_Operation');
+176
View File
@@ -0,0 +1,176 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class Project extends \Google\Model
{
/**
* When the script was created.
*
* @var string
*/
public $createTime;
protected $creatorType = GoogleAppsScriptTypeUser::class;
protected $creatorDataType = '';
protected $lastModifyUserType = GoogleAppsScriptTypeUser::class;
protected $lastModifyUserDataType = '';
/**
* The parent's Drive ID that the script will be attached to. This is usually
* the ID of a Google Document or Google Sheet. This field is optional, and if
* not set, a stand-alone script will be created.
*
* @var string
*/
public $parentId;
/**
* The script project's Drive ID.
*
* @var string
*/
public $scriptId;
/**
* The title for the project.
*
* @var string
*/
public $title;
/**
* When the script was last updated.
*
* @var string
*/
public $updateTime;
/**
* When the script was created.
*
* @param string $createTime
*/
public function setCreateTime($createTime)
{
$this->createTime = $createTime;
}
/**
* @return string
*/
public function getCreateTime()
{
return $this->createTime;
}
/**
* User who originally created the script.
*
* @param GoogleAppsScriptTypeUser $creator
*/
public function setCreator(GoogleAppsScriptTypeUser $creator)
{
$this->creator = $creator;
}
/**
* @return GoogleAppsScriptTypeUser
*/
public function getCreator()
{
return $this->creator;
}
/**
* User who last modified the script.
*
* @param GoogleAppsScriptTypeUser $lastModifyUser
*/
public function setLastModifyUser(GoogleAppsScriptTypeUser $lastModifyUser)
{
$this->lastModifyUser = $lastModifyUser;
}
/**
* @return GoogleAppsScriptTypeUser
*/
public function getLastModifyUser()
{
return $this->lastModifyUser;
}
/**
* The parent's Drive ID that the script will be attached to. This is usually
* the ID of a Google Document or Google Sheet. This field is optional, and if
* not set, a stand-alone script will be created.
*
* @param string $parentId
*/
public function setParentId($parentId)
{
$this->parentId = $parentId;
}
/**
* @return string
*/
public function getParentId()
{
return $this->parentId;
}
/**
* The script project's Drive ID.
*
* @param string $scriptId
*/
public function setScriptId($scriptId)
{
$this->scriptId = $scriptId;
}
/**
* @return string
*/
public function getScriptId()
{
return $this->scriptId;
}
/**
* The title for the project.
*
* @param string $title
*/
public function setTitle($title)
{
$this->title = $title;
}
/**
* @return string
*/
public function getTitle()
{
return $this->title;
}
/**
* When the script was last updated.
*
* @param string $updateTime
*/
public function setUpdateTime($updateTime)
{
$this->updateTime = $updateTime;
}
/**
* @return string
*/
public function getUpdateTime()
{
return $this->updateTime;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Project::class, 'Google_Service_Script_Project');
@@ -0,0 +1,120 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script\Resource;
use Google\Service\Script\ListScriptProcessesResponse;
use Google\Service\Script\ListUserProcessesResponse;
/**
* The "processes" collection of methods.
* Typical usage is:
* <code>
* $scriptService = new Google\Service\Script(...);
* $processes = $scriptService->processes;
* </code>
*/
class Processes extends \Google\Service\Resource
{
/**
* List information about processes made by or on behalf of a user, such as
* process type and current status. (processes.listProcesses)
*
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize The maximum number of returned processes per page of
* results. Defaults to 50.
* @opt_param string pageToken The token for continuing a previous list request
* on the next page. This should be set to the value of `nextPageToken` from a
* previous response.
* @opt_param string userProcessFilter.deploymentId Optional field used to limit
* returned processes to those originating from projects with a specific
* deployment ID.
* @opt_param string userProcessFilter.endTime Optional field used to limit
* returned processes to those that completed on or before the given timestamp.
* @opt_param string userProcessFilter.functionName Optional field used to limit
* returned processes to those originating from a script function with the given
* function name.
* @opt_param string userProcessFilter.projectName Optional field used to limit
* returned processes to those originating from projects with project names
* containing a specific string.
* @opt_param string userProcessFilter.scriptId Optional field used to limit
* returned processes to those originating from projects with a specific script
* ID.
* @opt_param string userProcessFilter.startTime Optional field used to limit
* returned processes to those that were started on or after the given
* timestamp.
* @opt_param string userProcessFilter.statuses Optional field used to limit
* returned processes to those having one of the specified process statuses.
* @opt_param string userProcessFilter.types Optional field used to limit
* returned processes to those having one of the specified process types.
* @opt_param string userProcessFilter.userAccessLevels Optional field used to
* limit returned processes to those having one of the specified user access
* levels.
* @return ListUserProcessesResponse
* @throws \Google\Service\Exception
*/
public function listProcesses($optParams = [])
{
$params = [];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListUserProcessesResponse::class);
}
/**
* List information about a script's executed processes, such as process type
* and current status. (processes.listScriptProcesses)
*
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize The maximum number of returned processes per page of
* results. Defaults to 50.
* @opt_param string pageToken The token for continuing a previous list request
* on the next page. This should be set to the value of `nextPageToken` from a
* previous response.
* @opt_param string scriptId The script ID of the project whose processes are
* listed.
* @opt_param string scriptProcessFilter.deploymentId Optional field used to
* limit returned processes to those originating from projects with a specific
* deployment ID.
* @opt_param string scriptProcessFilter.endTime Optional field used to limit
* returned processes to those that completed on or before the given timestamp.
* @opt_param string scriptProcessFilter.functionName Optional field used to
* limit returned processes to those originating from a script function with the
* given function name.
* @opt_param string scriptProcessFilter.startTime Optional field used to limit
* returned processes to those that were started on or after the given
* timestamp.
* @opt_param string scriptProcessFilter.statuses Optional field used to limit
* returned processes to those having one of the specified process statuses.
* @opt_param string scriptProcessFilter.types Optional field used to limit
* returned processes to those having one of the specified process types.
* @opt_param string scriptProcessFilter.userAccessLevels Optional field used to
* limit returned processes to those having one of the specified user access
* levels.
* @return ListScriptProcessesResponse
* @throws \Google\Service\Exception
*/
public function listScriptProcesses($optParams = [])
{
$params = [];
$params = array_merge($params, $optParams);
return $this->call('listScriptProcesses', [$params], ListScriptProcessesResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Processes::class, 'Google_Service_Script_Resource_Processes');
@@ -0,0 +1,125 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script\Resource;
use Google\Service\Script\Content;
use Google\Service\Script\CreateProjectRequest;
use Google\Service\Script\Metrics;
use Google\Service\Script\Project;
/**
* The "projects" collection of methods.
* Typical usage is:
* <code>
* $scriptService = new Google\Service\Script(...);
* $projects = $scriptService->projects;
* </code>
*/
class Projects extends \Google\Service\Resource
{
/**
* Creates a new, empty script project with no script files and a base manifest
* file. (projects.create)
*
* @param CreateProjectRequest $postBody
* @param array $optParams Optional parameters.
* @return Project
* @throws \Google\Service\Exception
*/
public function create(CreateProjectRequest $postBody, $optParams = [])
{
$params = ['postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Project::class);
}
/**
* Gets a script project's metadata. (projects.get)
*
* @param string $scriptId The script project's Drive ID.
* @param array $optParams Optional parameters.
* @return Project
* @throws \Google\Service\Exception
*/
public function get($scriptId, $optParams = [])
{
$params = ['scriptId' => $scriptId];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Project::class);
}
/**
* Gets the content of the script project, including the code source and
* metadata for each script file. (projects.getContent)
*
* @param string $scriptId The script project's Drive ID.
* @param array $optParams Optional parameters.
*
* @opt_param int versionNumber The version number of the project to retrieve.
* If not provided, the project's HEAD version is returned.
* @return Content
* @throws \Google\Service\Exception
*/
public function getContent($scriptId, $optParams = [])
{
$params = ['scriptId' => $scriptId];
$params = array_merge($params, $optParams);
return $this->call('getContent', [$params], Content::class);
}
/**
* Get metrics data for scripts, such as number of executions and active users.
* (projects.getMetrics)
*
* @param string $scriptId Required field indicating the script to get metrics
* for.
* @param array $optParams Optional parameters.
*
* @opt_param string metricsFilter.deploymentId Optional field indicating a
* specific deployment to retrieve metrics from.
* @opt_param string metricsGranularity Required field indicating what
* granularity of metrics are returned.
* @return Metrics
* @throws \Google\Service\Exception
*/
public function getMetrics($scriptId, $optParams = [])
{
$params = ['scriptId' => $scriptId];
$params = array_merge($params, $optParams);
return $this->call('getMetrics', [$params], Metrics::class);
}
/**
* Updates the content of the specified script project. This content is stored
* as the HEAD version, and is used when the script is executed as a trigger, in
* the script editor, in add-on preview mode, or as a web app or Apps Script API
* in development mode. This clears all the existing files in the project.
* (projects.updateContent)
*
* @param string $scriptId The script project's Drive ID.
* @param Content $postBody
* @param array $optParams Optional parameters.
* @return Content
* @throws \Google\Service\Exception
*/
public function updateContent($scriptId, Content $postBody, $optParams = [])
{
$params = ['scriptId' => $scriptId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('updateContent', [$params], Content::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Projects::class, 'Google_Service_Script_Resource_Projects');
@@ -0,0 +1,121 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script\Resource;
use Google\Service\Script\Deployment;
use Google\Service\Script\DeploymentConfig;
use Google\Service\Script\ListDeploymentsResponse;
use Google\Service\Script\ScriptEmpty;
use Google\Service\Script\UpdateDeploymentRequest;
/**
* The "deployments" collection of methods.
* Typical usage is:
* <code>
* $scriptService = new Google\Service\Script(...);
* $deployments = $scriptService->projects_deployments;
* </code>
*/
class ProjectsDeployments extends \Google\Service\Resource
{
/**
* Creates a deployment of an Apps Script project. (deployments.create)
*
* @param string $scriptId The script project's Drive ID.
* @param DeploymentConfig $postBody
* @param array $optParams Optional parameters.
* @return Deployment
* @throws \Google\Service\Exception
*/
public function create($scriptId, DeploymentConfig $postBody, $optParams = [])
{
$params = ['scriptId' => $scriptId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Deployment::class);
}
/**
* Deletes a deployment of an Apps Script project. (deployments.delete)
*
* @param string $scriptId The script project's Drive ID.
* @param string $deploymentId The deployment ID to be undeployed.
* @param array $optParams Optional parameters.
* @return ScriptEmpty
* @throws \Google\Service\Exception
*/
public function delete($scriptId, $deploymentId, $optParams = [])
{
$params = ['scriptId' => $scriptId, 'deploymentId' => $deploymentId];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], ScriptEmpty::class);
}
/**
* Gets a deployment of an Apps Script project. (deployments.get)
*
* @param string $scriptId The script project's Drive ID.
* @param string $deploymentId The deployment ID.
* @param array $optParams Optional parameters.
* @return Deployment
* @throws \Google\Service\Exception
*/
public function get($scriptId, $deploymentId, $optParams = [])
{
$params = ['scriptId' => $scriptId, 'deploymentId' => $deploymentId];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Deployment::class);
}
/**
* Lists the deployments of an Apps Script project.
* (deployments.listProjectsDeployments)
*
* @param string $scriptId The script project's Drive ID.
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize The maximum number of deployments on each returned
* page. Defaults to 50.
* @opt_param string pageToken The token for continuing a previous list request
* on the next page. This should be set to the value of `nextPageToken` from a
* previous response.
* @return ListDeploymentsResponse
* @throws \Google\Service\Exception
*/
public function listProjectsDeployments($scriptId, $optParams = [])
{
$params = ['scriptId' => $scriptId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListDeploymentsResponse::class);
}
/**
* Updates a deployment of an Apps Script project. (deployments.update)
*
* @param string $scriptId The script project's Drive ID.
* @param string $deploymentId The deployment ID for this deployment.
* @param UpdateDeploymentRequest $postBody
* @param array $optParams Optional parameters.
* @return Deployment
* @throws \Google\Service\Exception
*/
public function update($scriptId, $deploymentId, UpdateDeploymentRequest $postBody, $optParams = [])
{
$params = ['scriptId' => $scriptId, 'deploymentId' => $deploymentId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('update', [$params], Deployment::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsDeployments::class, 'Google_Service_Script_Resource_ProjectsDeployments');
@@ -0,0 +1,87 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script\Resource;
use Google\Service\Script\ListVersionsResponse;
use Google\Service\Script\Version;
/**
* The "versions" collection of methods.
* Typical usage is:
* <code>
* $scriptService = new Google\Service\Script(...);
* $versions = $scriptService->projects_versions;
* </code>
*/
class ProjectsVersions extends \Google\Service\Resource
{
/**
* Creates a new immutable version using the current code, with a unique version
* number. (versions.create)
*
* @param string $scriptId The script project's Drive ID.
* @param Version $postBody
* @param array $optParams Optional parameters.
* @return Version
* @throws \Google\Service\Exception
*/
public function create($scriptId, Version $postBody, $optParams = [])
{
$params = ['scriptId' => $scriptId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Version::class);
}
/**
* Gets a version of a script project. (versions.get)
*
* @param string $scriptId The script project's Drive ID.
* @param int $versionNumber The version number.
* @param array $optParams Optional parameters.
* @return Version
* @throws \Google\Service\Exception
*/
public function get($scriptId, $versionNumber, $optParams = [])
{
$params = ['scriptId' => $scriptId, 'versionNumber' => $versionNumber];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Version::class);
}
/**
* List the versions of a script project. (versions.listProjectsVersions)
*
* @param string $scriptId The script project's Drive ID.
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize The maximum number of versions on each returned page.
* Defaults to 50.
* @opt_param string pageToken The token for continuing a previous list request
* on the next page. This should be set to the value of `nextPageToken` from a
* previous response.
* @return ListVersionsResponse
* @throws \Google\Service\Exception
*/
public function listProjectsVersions($scriptId, $optParams = [])
{
$params = ['scriptId' => $scriptId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListVersionsResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsVersions::class, 'Google_Service_Script_Resource_ProjectsVersions');
@@ -0,0 +1,55 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script\Resource;
use Google\Service\Script\ExecutionRequest;
use Google\Service\Script\Operation;
/**
* The "scripts" collection of methods.
* Typical usage is:
* <code>
* $scriptService = new Google\Service\Script(...);
* $scripts = $scriptService->scripts;
* </code>
*/
class Scripts extends \Google\Service\Resource
{
/**
* (scripts.run)
*
* @param string $scriptId The script ID of the script to be executed. Find the
* script ID on the **Project settings** page under "IDs." As multiple
* executable APIs can be deployed in new IDE for same script, this field should
* be populated with DeploymentID generated while deploying in new IDE instead
* of script ID.
* @param ExecutionRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function run($scriptId, ExecutionRequest $postBody, $optParams = [])
{
$params = ['scriptId' => $scriptId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('run', [$params], Operation::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Scripts::class, 'Google_Service_Script_Resource_Scripts');
@@ -0,0 +1,25 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ScriptEmpty extends \Google\Model
{
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ScriptEmpty::class, 'Google_Service_Script_ScriptEmpty');
@@ -0,0 +1,42 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ScriptExecutionResult extends \Google\Model
{
protected $returnValueType = Value::class;
protected $returnValueDataType = '';
/**
* @param Value
*/
public function setReturnValue(Value $returnValue)
{
$this->returnValue = $returnValue;
}
/**
* @return Value
*/
public function getReturnValue()
{
return $this->returnValue;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ScriptExecutionResult::class, 'Google_Service_Script_ScriptExecutionResult');
@@ -0,0 +1,196 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ScriptFile extends \Google\Model
{
/**
* Undetermined file type; never actually used.
*/
public const TYPE_ENUM_TYPE_UNSPECIFIED = 'ENUM_TYPE_UNSPECIFIED';
/**
* An Apps Script server-side code file.
*/
public const TYPE_SERVER_JS = 'SERVER_JS';
/**
* A file containing client-side HTML.
*/
public const TYPE_HTML = 'HTML';
/**
* A file in JSON format. This type is only used for the script project's
* manifest. The manifest file content must match the structure of a valid
* [ScriptManifest](/apps-script/concepts/manifests)
*/
public const TYPE_JSON = 'JSON';
/**
* Creation date timestamp.
*
* @var string
*/
public $createTime;
protected $functionSetType = GoogleAppsScriptTypeFunctionSet::class;
protected $functionSetDataType = '';
protected $lastModifyUserType = GoogleAppsScriptTypeUser::class;
protected $lastModifyUserDataType = '';
/**
* The name of the file. The file extension is not part of the file name,
* which can be identified from the type field.
*
* @var string
*/
public $name;
/**
* The file content.
*
* @var string
*/
public $source;
/**
* The type of the file.
*
* @var string
*/
public $type;
/**
* Last modified date timestamp.
*
* @var string
*/
public $updateTime;
/**
* Creation date timestamp.
*
* @param string $createTime
*/
public function setCreateTime($createTime)
{
$this->createTime = $createTime;
}
/**
* @return string
*/
public function getCreateTime()
{
return $this->createTime;
}
/**
* The defined set of functions in the script file, if any.
*
* @param GoogleAppsScriptTypeFunctionSet $functionSet
*/
public function setFunctionSet(GoogleAppsScriptTypeFunctionSet $functionSet)
{
$this->functionSet = $functionSet;
}
/**
* @return GoogleAppsScriptTypeFunctionSet
*/
public function getFunctionSet()
{
return $this->functionSet;
}
/**
* The user who modified the file most recently. The details visible in this
* object are controlled by the profile visibility settings of the last
* modifying user.
*
* @param GoogleAppsScriptTypeUser $lastModifyUser
*/
public function setLastModifyUser(GoogleAppsScriptTypeUser $lastModifyUser)
{
$this->lastModifyUser = $lastModifyUser;
}
/**
* @return GoogleAppsScriptTypeUser
*/
public function getLastModifyUser()
{
return $this->lastModifyUser;
}
/**
* The name of the file. The file extension is not part of the file name,
* which can be identified from the type field.
*
* @param string $name
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* The file content.
*
* @param string $source
*/
public function setSource($source)
{
$this->source = $source;
}
/**
* @return string
*/
public function getSource()
{
return $this->source;
}
/**
* The type of the file.
*
* Accepted values: ENUM_TYPE_UNSPECIFIED, SERVER_JS, HTML, JSON
*
* @param self::TYPE_* $type
*/
public function setType($type)
{
$this->type = $type;
}
/**
* @return self::TYPE_*
*/
public function getType()
{
return $this->type;
}
/**
* Last modified date timestamp.
*
* @param string $updateTime
*/
public function setUpdateTime($updateTime)
{
$this->updateTime = $updateTime;
}
/**
* @return string
*/
public function getUpdateTime()
{
return $this->updateTime;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ScriptFile::class, 'Google_Service_Script_ScriptFile');
@@ -0,0 +1,70 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class ScriptStackTraceElement extends \Google\Model
{
/**
* The name of the function that failed.
*
* @var string
*/
public $function;
/**
* The line number where the script failed.
*
* @var int
*/
public $lineNumber;
/**
* The name of the function that failed.
*
* @param string $function
*/
public function setFunction($function)
{
$this->function = $function;
}
/**
* @return string
*/
public function getFunction()
{
return $this->function;
}
/**
* The line number where the script failed.
*
* @param int $lineNumber
*/
public function setLineNumber($lineNumber)
{
$this->lineNumber = $lineNumber;
}
/**
* @return int
*/
public function getLineNumber()
{
return $this->lineNumber;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ScriptStackTraceElement::class, 'Google_Service_Script_ScriptStackTraceElement');
+103
View File
@@ -0,0 +1,103 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class Status extends \Google\Collection
{
protected $collection_key = 'details';
/**
* The status code. For this API, this value either: - 10, indicating a
* `SCRIPT_TIMEOUT` error, - 3, indicating an `INVALID_ARGUMENT` error, or -
* 1, indicating a `CANCELLED` execution.
*
* @var int
*/
public $code;
/**
* An array that contains a single ExecutionError object that provides
* information about the nature of the error.
*
* @var array[]
*/
public $details;
/**
* A developer-facing error message, which is in English. Any user-facing
* error message is localized and sent in the details field, or localized by
* the client.
*
* @var string
*/
public $message;
/**
* The status code. For this API, this value either: - 10, indicating a
* `SCRIPT_TIMEOUT` error, - 3, indicating an `INVALID_ARGUMENT` error, or -
* 1, indicating a `CANCELLED` execution.
*
* @param int $code
*/
public function setCode($code)
{
$this->code = $code;
}
/**
* @return int
*/
public function getCode()
{
return $this->code;
}
/**
* An array that contains a single ExecutionError object that provides
* information about the nature of the error.
*
* @param array[] $details
*/
public function setDetails($details)
{
$this->details = $details;
}
/**
* @return array[]
*/
public function getDetails()
{
return $this->details;
}
/**
* A developer-facing error message, which is in English. Any user-facing
* error message is localized and sent in the details field, or localized by
* the client.
*
* @param string $message
*/
public function setMessage($message)
{
$this->message = $message;
}
/**
* @return string
*/
public function getMessage()
{
return $this->message;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Status::class, 'Google_Service_Script_Status');
+42
View File
@@ -0,0 +1,42 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class Struct extends \Google\Model
{
protected $fieldsType = Value::class;
protected $fieldsDataType = 'map';
/**
* @param Value[]
*/
public function setFields($fields)
{
$this->fields = $fields;
}
/**
* @return Value[]
*/
public function getFields()
{
return $this->fields;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Struct::class, 'Google_Service_Script_Struct');
@@ -0,0 +1,44 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class UpdateDeploymentRequest extends \Google\Model
{
protected $deploymentConfigType = DeploymentConfig::class;
protected $deploymentConfigDataType = '';
/**
* The deployment configuration.
*
* @param DeploymentConfig $deploymentConfig
*/
public function setDeploymentConfig(DeploymentConfig $deploymentConfig)
{
$this->deploymentConfig = $deploymentConfig;
}
/**
* @return DeploymentConfig
*/
public function getDeploymentConfig()
{
return $this->deploymentConfig;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UpdateDeploymentRequest::class, 'Google_Service_Script_UpdateDeploymentRequest');
+175
View File
@@ -0,0 +1,175 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class Value extends \Google\Model
{
/**
* @var bool
*/
public $boolValue;
/**
* @var string
*/
public $bytesValue;
/**
* @var string
*/
public $dateValue;
protected $listValueType = ListValue::class;
protected $listValueDataType = '';
/**
* @var string
*/
public $nullValue;
public $numberValue;
/**
* @var array[]
*/
public $protoValue;
/**
* @var string
*/
public $stringValue;
protected $structValueType = Struct::class;
protected $structValueDataType = '';
/**
* @param bool
*/
public function setBoolValue($boolValue)
{
$this->boolValue = $boolValue;
}
/**
* @return bool
*/
public function getBoolValue()
{
return $this->boolValue;
}
/**
* @param string
*/
public function setBytesValue($bytesValue)
{
$this->bytesValue = $bytesValue;
}
/**
* @return string
*/
public function getBytesValue()
{
return $this->bytesValue;
}
/**
* @param string
*/
public function setDateValue($dateValue)
{
$this->dateValue = $dateValue;
}
/**
* @return string
*/
public function getDateValue()
{
return $this->dateValue;
}
/**
* @param ListValue
*/
public function setListValue(ListValue $listValue)
{
$this->listValue = $listValue;
}
/**
* @return ListValue
*/
public function getListValue()
{
return $this->listValue;
}
/**
* @param string
*/
public function setNullValue($nullValue)
{
$this->nullValue = $nullValue;
}
/**
* @return string
*/
public function getNullValue()
{
return $this->nullValue;
}
public function setNumberValue($numberValue)
{
$this->numberValue = $numberValue;
}
public function getNumberValue()
{
return $this->numberValue;
}
/**
* @param array[]
*/
public function setProtoValue($protoValue)
{
$this->protoValue = $protoValue;
}
/**
* @return array[]
*/
public function getProtoValue()
{
return $this->protoValue;
}
/**
* @param string
*/
public function setStringValue($stringValue)
{
$this->stringValue = $stringValue;
}
/**
* @return string
*/
public function getStringValue()
{
return $this->stringValue;
}
/**
* @param Struct
*/
public function setStructValue(Struct $structValue)
{
$this->structValue = $structValue;
}
/**
* @return Struct
*/
public function getStructValue()
{
return $this->structValue;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Value::class, 'Google_Service_Script_Value');
+116
View File
@@ -0,0 +1,116 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Script;
class Version extends \Google\Model
{
/**
* When the version was created.
*
* @var string
*/
public $createTime;
/**
* The description for this version.
*
* @var string
*/
public $description;
/**
* The script project's Drive ID.
*
* @var string
*/
public $scriptId;
/**
* The incremental ID that is created by Apps Script when a version is
* created. This is system assigned number and is immutable once created.
*
* @var int
*/
public $versionNumber;
/**
* When the version was created.
*
* @param string $createTime
*/
public function setCreateTime($createTime)
{
$this->createTime = $createTime;
}
/**
* @return string
*/
public function getCreateTime()
{
return $this->createTime;
}
/**
* The description for this version.
*
* @param string $description
*/
public function setDescription($description)
{
$this->description = $description;
}
/**
* @return string
*/
public function getDescription()
{
return $this->description;
}
/**
* The script project's Drive ID.
*
* @param string $scriptId
*/
public function setScriptId($scriptId)
{
$this->scriptId = $scriptId;
}
/**
* @return string
*/
public function getScriptId()
{
return $this->scriptId;
}
/**
* The incremental ID that is created by Apps Script when a version is
* created. This is system assigned number and is immutable once created.
*
* @param int $versionNumber
*/
public function setVersionNumber($versionNumber)
{
$this->versionNumber = $versionNumber;
}
/**
* @return int
*/
public function getVersionNumber()
{
return $this->versionNumber;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Version::class, 'Google_Service_Script_Version');