Initial commit

This commit is contained in:
Local Administrator
2025-04-18 10:32:42 +02:00
commit b83134aca3
29643 changed files with 3045897 additions and 0 deletions

View File

@@ -0,0 +1,152 @@
<?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\Translate;
class AdaptiveMtDataset extends \Google\Model
{
/**
* @var string
*/
public $createTime;
/**
* @var string
*/
public $displayName;
/**
* @var int
*/
public $exampleCount;
/**
* @var string
*/
public $name;
/**
* @var string
*/
public $sourceLanguageCode;
/**
* @var string
*/
public $targetLanguageCode;
/**
* @var string
*/
public $updateTime;
/**
* @param string
*/
public function setCreateTime($createTime)
{
$this->createTime = $createTime;
}
/**
* @return string
*/
public function getCreateTime()
{
return $this->createTime;
}
/**
* @param string
*/
public function setDisplayName($displayName)
{
$this->displayName = $displayName;
}
/**
* @return string
*/
public function getDisplayName()
{
return $this->displayName;
}
/**
* @param int
*/
public function setExampleCount($exampleCount)
{
$this->exampleCount = $exampleCount;
}
/**
* @return int
*/
public function getExampleCount()
{
return $this->exampleCount;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param string
*/
public function setSourceLanguageCode($sourceLanguageCode)
{
$this->sourceLanguageCode = $sourceLanguageCode;
}
/**
* @return string
*/
public function getSourceLanguageCode()
{
return $this->sourceLanguageCode;
}
/**
* @param string
*/
public function setTargetLanguageCode($targetLanguageCode)
{
$this->targetLanguageCode = $targetLanguageCode;
}
/**
* @return string
*/
public function getTargetLanguageCode()
{
return $this->targetLanguageCode;
}
/**
* @param string
*/
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(AdaptiveMtDataset::class, 'Google_Service_Translate_AdaptiveMtDataset');

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\Translate;
class AdaptiveMtFile extends \Google\Model
{
/**
* @var string
*/
public $createTime;
/**
* @var string
*/
public $displayName;
/**
* @var int
*/
public $entryCount;
/**
* @var string
*/
public $name;
/**
* @var string
*/
public $updateTime;
/**
* @param string
*/
public function setCreateTime($createTime)
{
$this->createTime = $createTime;
}
/**
* @return string
*/
public function getCreateTime()
{
return $this->createTime;
}
/**
* @param string
*/
public function setDisplayName($displayName)
{
$this->displayName = $displayName;
}
/**
* @return string
*/
public function getDisplayName()
{
return $this->displayName;
}
/**
* @param int
*/
public function setEntryCount($entryCount)
{
$this->entryCount = $entryCount;
}
/**
* @return int
*/
public function getEntryCount()
{
return $this->entryCount;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param string
*/
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(AdaptiveMtFile::class, 'Google_Service_Translate_AdaptiveMtFile');

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\Translate;
class AdaptiveMtSentence extends \Google\Model
{
/**
* @var string
*/
public $createTime;
/**
* @var string
*/
public $name;
/**
* @var string
*/
public $sourceSentence;
/**
* @var string
*/
public $targetSentence;
/**
* @var string
*/
public $updateTime;
/**
* @param string
*/
public function setCreateTime($createTime)
{
$this->createTime = $createTime;
}
/**
* @return string
*/
public function getCreateTime()
{
return $this->createTime;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param string
*/
public function setSourceSentence($sourceSentence)
{
$this->sourceSentence = $sourceSentence;
}
/**
* @return string
*/
public function getSourceSentence()
{
return $this->sourceSentence;
}
/**
* @param string
*/
public function setTargetSentence($targetSentence)
{
$this->targetSentence = $targetSentence;
}
/**
* @return string
*/
public function getTargetSentence()
{
return $this->targetSentence;
}
/**
* @param string
*/
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(AdaptiveMtSentence::class, 'Google_Service_Translate_AdaptiveMtSentence');

View File

@@ -0,0 +1,95 @@
<?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\Translate;
class AdaptiveMtTranslateRequest extends \Google\Collection
{
protected $collection_key = 'content';
/**
* @var string[]
*/
public $content;
/**
* @var string
*/
public $dataset;
protected $glossaryConfigType = GlossaryConfig::class;
protected $glossaryConfigDataType = '';
protected $referenceSentenceConfigType = ReferenceSentenceConfig::class;
protected $referenceSentenceConfigDataType = '';
/**
* @param string[]
*/
public function setContent($content)
{
$this->content = $content;
}
/**
* @return string[]
*/
public function getContent()
{
return $this->content;
}
/**
* @param string
*/
public function setDataset($dataset)
{
$this->dataset = $dataset;
}
/**
* @return string
*/
public function getDataset()
{
return $this->dataset;
}
/**
* @param GlossaryConfig
*/
public function setGlossaryConfig(GlossaryConfig $glossaryConfig)
{
$this->glossaryConfig = $glossaryConfig;
}
/**
* @return GlossaryConfig
*/
public function getGlossaryConfig()
{
return $this->glossaryConfig;
}
/**
* @param ReferenceSentenceConfig
*/
public function setReferenceSentenceConfig(ReferenceSentenceConfig $referenceSentenceConfig)
{
$this->referenceSentenceConfig = $referenceSentenceConfig;
}
/**
* @return ReferenceSentenceConfig
*/
public function getReferenceSentenceConfig()
{
return $this->referenceSentenceConfig;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(AdaptiveMtTranslateRequest::class, 'Google_Service_Translate_AdaptiveMtTranslateRequest');

View File

@@ -0,0 +1,77 @@
<?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\Translate;
class AdaptiveMtTranslateResponse extends \Google\Collection
{
protected $collection_key = 'translations';
protected $glossaryTranslationsType = AdaptiveMtTranslation::class;
protected $glossaryTranslationsDataType = 'array';
/**
* @var string
*/
public $languageCode;
protected $translationsType = AdaptiveMtTranslation::class;
protected $translationsDataType = 'array';
/**
* @param AdaptiveMtTranslation[]
*/
public function setGlossaryTranslations($glossaryTranslations)
{
$this->glossaryTranslations = $glossaryTranslations;
}
/**
* @return AdaptiveMtTranslation[]
*/
public function getGlossaryTranslations()
{
return $this->glossaryTranslations;
}
/**
* @param string
*/
public function setLanguageCode($languageCode)
{
$this->languageCode = $languageCode;
}
/**
* @return string
*/
public function getLanguageCode()
{
return $this->languageCode;
}
/**
* @param AdaptiveMtTranslation[]
*/
public function setTranslations($translations)
{
$this->translations = $translations;
}
/**
* @return AdaptiveMtTranslation[]
*/
public function getTranslations()
{
return $this->translations;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(AdaptiveMtTranslateResponse::class, 'Google_Service_Translate_AdaptiveMtTranslateResponse');

View File

@@ -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\Translate;
class AdaptiveMtTranslation extends \Google\Model
{
/**
* @var string
*/
public $translatedText;
/**
* @param string
*/
public function setTranslatedText($translatedText)
{
$this->translatedText = $translatedText;
}
/**
* @return string
*/
public function getTranslatedText()
{
return $this->translatedText;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(AdaptiveMtTranslation::class, 'Google_Service_Translate_AdaptiveMtTranslation');

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\Translate;
class BatchDocumentInputConfig extends \Google\Model
{
protected $gcsSourceType = GcsSource::class;
protected $gcsSourceDataType = '';
/**
* @param GcsSource
*/
public function setGcsSource(GcsSource $gcsSource)
{
$this->gcsSource = $gcsSource;
}
/**
* @return GcsSource
*/
public function getGcsSource()
{
return $this->gcsSource;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(BatchDocumentInputConfig::class, 'Google_Service_Translate_BatchDocumentInputConfig');

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\Translate;
class BatchDocumentOutputConfig extends \Google\Model
{
protected $gcsDestinationType = GcsDestination::class;
protected $gcsDestinationDataType = '';
/**
* @param GcsDestination
*/
public function setGcsDestination(GcsDestination $gcsDestination)
{
$this->gcsDestination = $gcsDestination;
}
/**
* @return GcsDestination
*/
public function getGcsDestination()
{
return $this->gcsDestination;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(BatchDocumentOutputConfig::class, 'Google_Service_Translate_BatchDocumentOutputConfig');

View File

@@ -0,0 +1,201 @@
<?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\Translate;
class BatchTranslateDocumentRequest extends \Google\Collection
{
protected $collection_key = 'targetLanguageCodes';
/**
* @var string
*/
public $customizedAttribution;
/**
* @var bool
*/
public $enableRotationCorrection;
/**
* @var bool
*/
public $enableShadowRemovalNativePdf;
/**
* @var string[]
*/
public $formatConversions;
protected $glossariesType = TranslateTextGlossaryConfig::class;
protected $glossariesDataType = 'map';
protected $inputConfigsType = BatchDocumentInputConfig::class;
protected $inputConfigsDataType = 'array';
/**
* @var string[]
*/
public $models;
protected $outputConfigType = BatchDocumentOutputConfig::class;
protected $outputConfigDataType = '';
/**
* @var string
*/
public $sourceLanguageCode;
/**
* @var string[]
*/
public $targetLanguageCodes;
/**
* @param string
*/
public function setCustomizedAttribution($customizedAttribution)
{
$this->customizedAttribution = $customizedAttribution;
}
/**
* @return string
*/
public function getCustomizedAttribution()
{
return $this->customizedAttribution;
}
/**
* @param bool
*/
public function setEnableRotationCorrection($enableRotationCorrection)
{
$this->enableRotationCorrection = $enableRotationCorrection;
}
/**
* @return bool
*/
public function getEnableRotationCorrection()
{
return $this->enableRotationCorrection;
}
/**
* @param bool
*/
public function setEnableShadowRemovalNativePdf($enableShadowRemovalNativePdf)
{
$this->enableShadowRemovalNativePdf = $enableShadowRemovalNativePdf;
}
/**
* @return bool
*/
public function getEnableShadowRemovalNativePdf()
{
return $this->enableShadowRemovalNativePdf;
}
/**
* @param string[]
*/
public function setFormatConversions($formatConversions)
{
$this->formatConversions = $formatConversions;
}
/**
* @return string[]
*/
public function getFormatConversions()
{
return $this->formatConversions;
}
/**
* @param TranslateTextGlossaryConfig[]
*/
public function setGlossaries($glossaries)
{
$this->glossaries = $glossaries;
}
/**
* @return TranslateTextGlossaryConfig[]
*/
public function getGlossaries()
{
return $this->glossaries;
}
/**
* @param BatchDocumentInputConfig[]
*/
public function setInputConfigs($inputConfigs)
{
$this->inputConfigs = $inputConfigs;
}
/**
* @return BatchDocumentInputConfig[]
*/
public function getInputConfigs()
{
return $this->inputConfigs;
}
/**
* @param string[]
*/
public function setModels($models)
{
$this->models = $models;
}
/**
* @return string[]
*/
public function getModels()
{
return $this->models;
}
/**
* @param BatchDocumentOutputConfig
*/
public function setOutputConfig(BatchDocumentOutputConfig $outputConfig)
{
$this->outputConfig = $outputConfig;
}
/**
* @return BatchDocumentOutputConfig
*/
public function getOutputConfig()
{
return $this->outputConfig;
}
/**
* @param string
*/
public function setSourceLanguageCode($sourceLanguageCode)
{
$this->sourceLanguageCode = $sourceLanguageCode;
}
/**
* @return string
*/
public function getSourceLanguageCode()
{
return $this->sourceLanguageCode;
}
/**
* @param string[]
*/
public function setTargetLanguageCodes($targetLanguageCodes)
{
$this->targetLanguageCodes = $targetLanguageCodes;
}
/**
* @return string[]
*/
public function getTargetLanguageCodes()
{
return $this->targetLanguageCodes;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(BatchTranslateDocumentRequest::class, 'Google_Service_Translate_BatchTranslateDocumentRequest');

View File

@@ -0,0 +1,147 @@
<?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\Translate;
class BatchTranslateTextRequest extends \Google\Collection
{
protected $collection_key = 'targetLanguageCodes';
protected $glossariesType = TranslateTextGlossaryConfig::class;
protected $glossariesDataType = 'map';
protected $inputConfigsType = InputConfig::class;
protected $inputConfigsDataType = 'array';
/**
* @var string[]
*/
public $labels;
/**
* @var string[]
*/
public $models;
protected $outputConfigType = OutputConfig::class;
protected $outputConfigDataType = '';
/**
* @var string
*/
public $sourceLanguageCode;
/**
* @var string[]
*/
public $targetLanguageCodes;
/**
* @param TranslateTextGlossaryConfig[]
*/
public function setGlossaries($glossaries)
{
$this->glossaries = $glossaries;
}
/**
* @return TranslateTextGlossaryConfig[]
*/
public function getGlossaries()
{
return $this->glossaries;
}
/**
* @param InputConfig[]
*/
public function setInputConfigs($inputConfigs)
{
$this->inputConfigs = $inputConfigs;
}
/**
* @return InputConfig[]
*/
public function getInputConfigs()
{
return $this->inputConfigs;
}
/**
* @param string[]
*/
public function setLabels($labels)
{
$this->labels = $labels;
}
/**
* @return string[]
*/
public function getLabels()
{
return $this->labels;
}
/**
* @param string[]
*/
public function setModels($models)
{
$this->models = $models;
}
/**
* @return string[]
*/
public function getModels()
{
return $this->models;
}
/**
* @param OutputConfig
*/
public function setOutputConfig(OutputConfig $outputConfig)
{
$this->outputConfig = $outputConfig;
}
/**
* @return OutputConfig
*/
public function getOutputConfig()
{
return $this->outputConfig;
}
/**
* @param string
*/
public function setSourceLanguageCode($sourceLanguageCode)
{
$this->sourceLanguageCode = $sourceLanguageCode;
}
/**
* @return string
*/
public function getSourceLanguageCode()
{
return $this->sourceLanguageCode;
}
/**
* @param string[]
*/
public function setTargetLanguageCodes($targetLanguageCodes)
{
$this->targetLanguageCodes = $targetLanguageCodes;
}
/**
* @return string[]
*/
public function getTargetLanguageCodes()
{
return $this->targetLanguageCodes;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(BatchTranslateTextRequest::class, 'Google_Service_Translate_BatchTranslateTextRequest');

View File

@@ -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\Translate;
class CancelOperationRequest extends \Google\Model
{
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(CancelOperationRequest::class, 'Google_Service_Translate_CancelOperationRequest');

View File

@@ -0,0 +1,206 @@
<?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\Translate;
class Dataset extends \Google\Model
{
/**
* @var string
*/
public $createTime;
/**
* @var string
*/
public $displayName;
/**
* @var int
*/
public $exampleCount;
/**
* @var string
*/
public $name;
/**
* @var string
*/
public $sourceLanguageCode;
/**
* @var string
*/
public $targetLanguageCode;
/**
* @var int
*/
public $testExampleCount;
/**
* @var int
*/
public $trainExampleCount;
/**
* @var string
*/
public $updateTime;
/**
* @var int
*/
public $validateExampleCount;
/**
* @param string
*/
public function setCreateTime($createTime)
{
$this->createTime = $createTime;
}
/**
* @return string
*/
public function getCreateTime()
{
return $this->createTime;
}
/**
* @param string
*/
public function setDisplayName($displayName)
{
$this->displayName = $displayName;
}
/**
* @return string
*/
public function getDisplayName()
{
return $this->displayName;
}
/**
* @param int
*/
public function setExampleCount($exampleCount)
{
$this->exampleCount = $exampleCount;
}
/**
* @return int
*/
public function getExampleCount()
{
return $this->exampleCount;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param string
*/
public function setSourceLanguageCode($sourceLanguageCode)
{
$this->sourceLanguageCode = $sourceLanguageCode;
}
/**
* @return string
*/
public function getSourceLanguageCode()
{
return $this->sourceLanguageCode;
}
/**
* @param string
*/
public function setTargetLanguageCode($targetLanguageCode)
{
$this->targetLanguageCode = $targetLanguageCode;
}
/**
* @return string
*/
public function getTargetLanguageCode()
{
return $this->targetLanguageCode;
}
/**
* @param int
*/
public function setTestExampleCount($testExampleCount)
{
$this->testExampleCount = $testExampleCount;
}
/**
* @return int
*/
public function getTestExampleCount()
{
return $this->testExampleCount;
}
/**
* @param int
*/
public function setTrainExampleCount($trainExampleCount)
{
$this->trainExampleCount = $trainExampleCount;
}
/**
* @return int
*/
public function getTrainExampleCount()
{
return $this->trainExampleCount;
}
/**
* @param string
*/
public function setUpdateTime($updateTime)
{
$this->updateTime = $updateTime;
}
/**
* @return string
*/
public function getUpdateTime()
{
return $this->updateTime;
}
/**
* @param int
*/
public function setValidateExampleCount($validateExampleCount)
{
$this->validateExampleCount = $validateExampleCount;
}
/**
* @return int
*/
public function getValidateExampleCount()
{
return $this->validateExampleCount;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Dataset::class, 'Google_Service_Translate_Dataset');

View File

@@ -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\Translate;
class DatasetInputConfig extends \Google\Collection
{
protected $collection_key = 'inputFiles';
protected $inputFilesType = InputFile::class;
protected $inputFilesDataType = 'array';
/**
* @param InputFile[]
*/
public function setInputFiles($inputFiles)
{
$this->inputFiles = $inputFiles;
}
/**
* @return InputFile[]
*/
public function getInputFiles()
{
return $this->inputFiles;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(DatasetInputConfig::class, 'Google_Service_Translate_DatasetInputConfig');

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\Translate;
class DatasetOutputConfig extends \Google\Model
{
protected $gcsDestinationType = GcsOutputDestination::class;
protected $gcsDestinationDataType = '';
/**
* @param GcsOutputDestination
*/
public function setGcsDestination(GcsOutputDestination $gcsDestination)
{
$this->gcsDestination = $gcsDestination;
}
/**
* @return GcsOutputDestination
*/
public function getGcsDestination()
{
return $this->gcsDestination;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(DatasetOutputConfig::class, 'Google_Service_Translate_DatasetOutputConfig');

View File

@@ -0,0 +1,98 @@
<?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\Translate;
class DetectLanguageRequest extends \Google\Model
{
/**
* @var string
*/
public $content;
/**
* @var string[]
*/
public $labels;
/**
* @var string
*/
public $mimeType;
/**
* @var string
*/
public $model;
/**
* @param string
*/
public function setContent($content)
{
$this->content = $content;
}
/**
* @return string
*/
public function getContent()
{
return $this->content;
}
/**
* @param string[]
*/
public function setLabels($labels)
{
$this->labels = $labels;
}
/**
* @return string[]
*/
public function getLabels()
{
return $this->labels;
}
/**
* @param string
*/
public function setMimeType($mimeType)
{
$this->mimeType = $mimeType;
}
/**
* @return string
*/
public function getMimeType()
{
return $this->mimeType;
}
/**
* @param string
*/
public function setModel($model)
{
$this->model = $model;
}
/**
* @return string
*/
public function getModel()
{
return $this->model;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(DetectLanguageRequest::class, 'Google_Service_Translate_DetectLanguageRequest');

View File

@@ -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\Translate;
class DetectLanguageResponse extends \Google\Collection
{
protected $collection_key = 'languages';
protected $languagesType = DetectedLanguage::class;
protected $languagesDataType = 'array';
/**
* @param DetectedLanguage[]
*/
public function setLanguages($languages)
{
$this->languages = $languages;
}
/**
* @return DetectedLanguage[]
*/
public function getLanguages()
{
return $this->languages;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(DetectLanguageResponse::class, 'Google_Service_Translate_DetectLanguageResponse');

View File

@@ -0,0 +1,62 @@
<?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\Translate;
class DetectedLanguage extends \Google\Model
{
/**
* @var float
*/
public $confidence;
/**
* @var string
*/
public $languageCode;
/**
* @param float
*/
public function setConfidence($confidence)
{
$this->confidence = $confidence;
}
/**
* @return float
*/
public function getConfidence()
{
return $this->confidence;
}
/**
* @param string
*/
public function setLanguageCode($languageCode)
{
$this->languageCode = $languageCode;
}
/**
* @return string
*/
public function getLanguageCode()
{
return $this->languageCode;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(DetectedLanguage::class, 'Google_Service_Translate_DetectedLanguage');

View File

@@ -0,0 +1,78 @@
<?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\Translate;
class DocumentInputConfig extends \Google\Model
{
/**
* @var string
*/
public $content;
protected $gcsSourceType = GcsSource::class;
protected $gcsSourceDataType = '';
/**
* @var string
*/
public $mimeType;
/**
* @param string
*/
public function setContent($content)
{
$this->content = $content;
}
/**
* @return string
*/
public function getContent()
{
return $this->content;
}
/**
* @param GcsSource
*/
public function setGcsSource(GcsSource $gcsSource)
{
$this->gcsSource = $gcsSource;
}
/**
* @return GcsSource
*/
public function getGcsSource()
{
return $this->gcsSource;
}
/**
* @param string
*/
public function setMimeType($mimeType)
{
$this->mimeType = $mimeType;
}
/**
* @return string
*/
public function getMimeType()
{
return $this->mimeType;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(DocumentInputConfig::class, 'Google_Service_Translate_DocumentInputConfig');

View File

@@ -0,0 +1,60 @@
<?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\Translate;
class DocumentOutputConfig extends \Google\Model
{
protected $gcsDestinationType = GcsDestination::class;
protected $gcsDestinationDataType = '';
/**
* @var string
*/
public $mimeType;
/**
* @param GcsDestination
*/
public function setGcsDestination(GcsDestination $gcsDestination)
{
$this->gcsDestination = $gcsDestination;
}
/**
* @return GcsDestination
*/
public function getGcsDestination()
{
return $this->gcsDestination;
}
/**
* @param string
*/
public function setMimeType($mimeType)
{
$this->mimeType = $mimeType;
}
/**
* @return string
*/
public function getMimeType()
{
return $this->mimeType;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(DocumentOutputConfig::class, 'Google_Service_Translate_DocumentOutputConfig');

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\Translate;
class DocumentTranslation extends \Google\Collection
{
protected $collection_key = 'byteStreamOutputs';
/**
* @var string[]
*/
public $byteStreamOutputs;
/**
* @var string
*/
public $detectedLanguageCode;
/**
* @var string
*/
public $mimeType;
/**
* @param string[]
*/
public function setByteStreamOutputs($byteStreamOutputs)
{
$this->byteStreamOutputs = $byteStreamOutputs;
}
/**
* @return string[]
*/
public function getByteStreamOutputs()
{
return $this->byteStreamOutputs;
}
/**
* @param string
*/
public function setDetectedLanguageCode($detectedLanguageCode)
{
$this->detectedLanguageCode = $detectedLanguageCode;
}
/**
* @return string
*/
public function getDetectedLanguageCode()
{
return $this->detectedLanguageCode;
}
/**
* @param string
*/
public function setMimeType($mimeType)
{
$this->mimeType = $mimeType;
}
/**
* @return string
*/
public function getMimeType()
{
return $this->mimeType;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(DocumentTranslation::class, 'Google_Service_Translate_DocumentTranslation');

View File

@@ -0,0 +1,98 @@
<?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\Translate;
class Example extends \Google\Model
{
/**
* @var string
*/
public $name;
/**
* @var string
*/
public $sourceText;
/**
* @var string
*/
public $targetText;
/**
* @var string
*/
public $usage;
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param string
*/
public function setSourceText($sourceText)
{
$this->sourceText = $sourceText;
}
/**
* @return string
*/
public function getSourceText()
{
return $this->sourceText;
}
/**
* @param string
*/
public function setTargetText($targetText)
{
$this->targetText = $targetText;
}
/**
* @return string
*/
public function getTargetText()
{
return $this->targetText;
}
/**
* @param string
*/
public function setUsage($usage)
{
$this->usage = $usage;
}
/**
* @return string
*/
public function getUsage()
{
return $this->usage;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Example::class, 'Google_Service_Translate_Example');

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\Translate;
class ExportDataRequest extends \Google\Model
{
protected $outputConfigType = DatasetOutputConfig::class;
protected $outputConfigDataType = '';
/**
* @param DatasetOutputConfig
*/
public function setOutputConfig(DatasetOutputConfig $outputConfig)
{
$this->outputConfig = $outputConfig;
}
/**
* @return DatasetOutputConfig
*/
public function getOutputConfig()
{
return $this->outputConfig;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ExportDataRequest::class, 'Google_Service_Translate_ExportDataRequest');

View File

@@ -0,0 +1,80 @@
<?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\Translate;
class FileInputSource extends \Google\Model
{
/**
* @var string
*/
public $content;
/**
* @var string
*/
public $displayName;
/**
* @var string
*/
public $mimeType;
/**
* @param string
*/
public function setContent($content)
{
$this->content = $content;
}
/**
* @return string
*/
public function getContent()
{
return $this->content;
}
/**
* @param string
*/
public function setDisplayName($displayName)
{
$this->displayName = $displayName;
}
/**
* @return string
*/
public function getDisplayName()
{
return $this->displayName;
}
/**
* @param string
*/
public function setMimeType($mimeType)
{
$this->mimeType = $mimeType;
}
/**
* @return string
*/
public function getMimeType()
{
return $this->mimeType;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(FileInputSource::class, 'Google_Service_Translate_FileInputSource');

View File

@@ -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\Translate;
class GcsDestination extends \Google\Model
{
/**
* @var string
*/
public $outputUriPrefix;
/**
* @param string
*/
public function setOutputUriPrefix($outputUriPrefix)
{
$this->outputUriPrefix = $outputUriPrefix;
}
/**
* @return string
*/
public function getOutputUriPrefix()
{
return $this->outputUriPrefix;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GcsDestination::class, 'Google_Service_Translate_GcsDestination');

View File

@@ -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\Translate;
class GcsInputSource extends \Google\Model
{
/**
* @var string
*/
public $inputUri;
/**
* @param string
*/
public function setInputUri($inputUri)
{
$this->inputUri = $inputUri;
}
/**
* @return string
*/
public function getInputUri()
{
return $this->inputUri;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GcsInputSource::class, 'Google_Service_Translate_GcsInputSource');

View File

@@ -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\Translate;
class GcsOutputDestination extends \Google\Model
{
/**
* @var string
*/
public $outputUriPrefix;
/**
* @param string
*/
public function setOutputUriPrefix($outputUriPrefix)
{
$this->outputUriPrefix = $outputUriPrefix;
}
/**
* @return string
*/
public function getOutputUriPrefix()
{
return $this->outputUriPrefix;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GcsOutputDestination::class, 'Google_Service_Translate_GcsOutputDestination');

View File

@@ -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\Translate;
class GcsSource extends \Google\Model
{
/**
* @var string
*/
public $inputUri;
/**
* @param string
*/
public function setInputUri($inputUri)
{
$this->inputUri = $inputUri;
}
/**
* @return string
*/
public function getInputUri()
{
return $this->inputUri;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GcsSource::class, 'Google_Service_Translate_GcsSource');

View File

@@ -0,0 +1,164 @@
<?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\Translate;
class Glossary extends \Google\Model
{
/**
* @var string
*/
public $displayName;
/**
* @var string
*/
public $endTime;
/**
* @var int
*/
public $entryCount;
protected $inputConfigType = GlossaryInputConfig::class;
protected $inputConfigDataType = '';
protected $languageCodesSetType = LanguageCodesSet::class;
protected $languageCodesSetDataType = '';
protected $languagePairType = LanguageCodePair::class;
protected $languagePairDataType = '';
/**
* @var string
*/
public $name;
/**
* @var string
*/
public $submitTime;
/**
* @param string
*/
public function setDisplayName($displayName)
{
$this->displayName = $displayName;
}
/**
* @return string
*/
public function getDisplayName()
{
return $this->displayName;
}
/**
* @param string
*/
public function setEndTime($endTime)
{
$this->endTime = $endTime;
}
/**
* @return string
*/
public function getEndTime()
{
return $this->endTime;
}
/**
* @param int
*/
public function setEntryCount($entryCount)
{
$this->entryCount = $entryCount;
}
/**
* @return int
*/
public function getEntryCount()
{
return $this->entryCount;
}
/**
* @param GlossaryInputConfig
*/
public function setInputConfig(GlossaryInputConfig $inputConfig)
{
$this->inputConfig = $inputConfig;
}
/**
* @return GlossaryInputConfig
*/
public function getInputConfig()
{
return $this->inputConfig;
}
/**
* @param LanguageCodesSet
*/
public function setLanguageCodesSet(LanguageCodesSet $languageCodesSet)
{
$this->languageCodesSet = $languageCodesSet;
}
/**
* @return LanguageCodesSet
*/
public function getLanguageCodesSet()
{
return $this->languageCodesSet;
}
/**
* @param LanguageCodePair
*/
public function setLanguagePair(LanguageCodePair $languagePair)
{
$this->languagePair = $languagePair;
}
/**
* @return LanguageCodePair
*/
public function getLanguagePair()
{
return $this->languagePair;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param string
*/
public function setSubmitTime($submitTime)
{
$this->submitTime = $submitTime;
}
/**
* @return string
*/
public function getSubmitTime()
{
return $this->submitTime;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Glossary::class, 'Google_Service_Translate_Glossary');

View File

@@ -0,0 +1,62 @@
<?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\Translate;
class GlossaryConfig extends \Google\Model
{
/**
* @var string
*/
public $glossary;
/**
* @var bool
*/
public $ignoreCase;
/**
* @param string
*/
public function setGlossary($glossary)
{
$this->glossary = $glossary;
}
/**
* @return string
*/
public function getGlossary()
{
return $this->glossary;
}
/**
* @param bool
*/
public function setIgnoreCase($ignoreCase)
{
$this->ignoreCase = $ignoreCase;
}
/**
* @return bool
*/
public function getIgnoreCase()
{
return $this->ignoreCase;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GlossaryConfig::class, 'Google_Service_Translate_GlossaryConfig');

View File

@@ -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\Translate;
class GlossaryEntry extends \Google\Model
{
/**
* @var string
*/
public $description;
/**
* @var string
*/
public $name;
protected $termsPairType = GlossaryTermsPair::class;
protected $termsPairDataType = '';
protected $termsSetType = GlossaryTermsSet::class;
protected $termsSetDataType = '';
/**
* @param string
*/
public function setDescription($description)
{
$this->description = $description;
}
/**
* @return string
*/
public function getDescription()
{
return $this->description;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param GlossaryTermsPair
*/
public function setTermsPair(GlossaryTermsPair $termsPair)
{
$this->termsPair = $termsPair;
}
/**
* @return GlossaryTermsPair
*/
public function getTermsPair()
{
return $this->termsPair;
}
/**
* @param GlossaryTermsSet
*/
public function setTermsSet(GlossaryTermsSet $termsSet)
{
$this->termsSet = $termsSet;
}
/**
* @return GlossaryTermsSet
*/
public function getTermsSet()
{
return $this->termsSet;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GlossaryEntry::class, 'Google_Service_Translate_GlossaryEntry');

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\Translate;
class GlossaryInputConfig extends \Google\Model
{
protected $gcsSourceType = GcsSource::class;
protected $gcsSourceDataType = '';
/**
* @param GcsSource
*/
public function setGcsSource(GcsSource $gcsSource)
{
$this->gcsSource = $gcsSource;
}
/**
* @return GcsSource
*/
public function getGcsSource()
{
return $this->gcsSource;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GlossaryInputConfig::class, 'Google_Service_Translate_GlossaryInputConfig');

View File

@@ -0,0 +1,62 @@
<?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\Translate;
class GlossaryTerm extends \Google\Model
{
/**
* @var string
*/
public $languageCode;
/**
* @var string
*/
public $text;
/**
* @param string
*/
public function setLanguageCode($languageCode)
{
$this->languageCode = $languageCode;
}
/**
* @return string
*/
public function getLanguageCode()
{
return $this->languageCode;
}
/**
* @param string
*/
public function setText($text)
{
$this->text = $text;
}
/**
* @return string
*/
public function getText()
{
return $this->text;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GlossaryTerm::class, 'Google_Service_Translate_GlossaryTerm');

View File

@@ -0,0 +1,58 @@
<?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\Translate;
class GlossaryTermsPair extends \Google\Model
{
protected $sourceTermType = GlossaryTerm::class;
protected $sourceTermDataType = '';
protected $targetTermType = GlossaryTerm::class;
protected $targetTermDataType = '';
/**
* @param GlossaryTerm
*/
public function setSourceTerm(GlossaryTerm $sourceTerm)
{
$this->sourceTerm = $sourceTerm;
}
/**
* @return GlossaryTerm
*/
public function getSourceTerm()
{
return $this->sourceTerm;
}
/**
* @param GlossaryTerm
*/
public function setTargetTerm(GlossaryTerm $targetTerm)
{
$this->targetTerm = $targetTerm;
}
/**
* @return GlossaryTerm
*/
public function getTargetTerm()
{
return $this->targetTerm;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GlossaryTermsPair::class, 'Google_Service_Translate_GlossaryTermsPair');

View File

@@ -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\Translate;
class GlossaryTermsSet extends \Google\Collection
{
protected $collection_key = 'terms';
protected $termsType = GlossaryTerm::class;
protected $termsDataType = 'array';
/**
* @param GlossaryTerm[]
*/
public function setTerms($terms)
{
$this->terms = $terms;
}
/**
* @return GlossaryTerm[]
*/
public function getTerms()
{
return $this->terms;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GlossaryTermsSet::class, 'Google_Service_Translate_GlossaryTermsSet');

View File

@@ -0,0 +1,58 @@
<?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\Translate;
class ImportAdaptiveMtFileRequest extends \Google\Model
{
protected $fileInputSourceType = FileInputSource::class;
protected $fileInputSourceDataType = '';
protected $gcsInputSourceType = GcsInputSource::class;
protected $gcsInputSourceDataType = '';
/**
* @param FileInputSource
*/
public function setFileInputSource(FileInputSource $fileInputSource)
{
$this->fileInputSource = $fileInputSource;
}
/**
* @return FileInputSource
*/
public function getFileInputSource()
{
return $this->fileInputSource;
}
/**
* @param GcsInputSource
*/
public function setGcsInputSource(GcsInputSource $gcsInputSource)
{
$this->gcsInputSource = $gcsInputSource;
}
/**
* @return GcsInputSource
*/
public function getGcsInputSource()
{
return $this->gcsInputSource;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ImportAdaptiveMtFileRequest::class, 'Google_Service_Translate_ImportAdaptiveMtFileRequest');

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\Translate;
class ImportAdaptiveMtFileResponse extends \Google\Model
{
protected $adaptiveMtFileType = AdaptiveMtFile::class;
protected $adaptiveMtFileDataType = '';
/**
* @param AdaptiveMtFile
*/
public function setAdaptiveMtFile(AdaptiveMtFile $adaptiveMtFile)
{
$this->adaptiveMtFile = $adaptiveMtFile;
}
/**
* @return AdaptiveMtFile
*/
public function getAdaptiveMtFile()
{
return $this->adaptiveMtFile;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ImportAdaptiveMtFileResponse::class, 'Google_Service_Translate_ImportAdaptiveMtFileResponse');

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\Translate;
class ImportDataRequest extends \Google\Model
{
protected $inputConfigType = DatasetInputConfig::class;
protected $inputConfigDataType = '';
/**
* @param DatasetInputConfig
*/
public function setInputConfig(DatasetInputConfig $inputConfig)
{
$this->inputConfig = $inputConfig;
}
/**
* @return DatasetInputConfig
*/
public function getInputConfig()
{
return $this->inputConfig;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ImportDataRequest::class, 'Google_Service_Translate_ImportDataRequest');

View File

@@ -0,0 +1,60 @@
<?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\Translate;
class InputConfig extends \Google\Model
{
protected $gcsSourceType = GcsSource::class;
protected $gcsSourceDataType = '';
/**
* @var string
*/
public $mimeType;
/**
* @param GcsSource
*/
public function setGcsSource(GcsSource $gcsSource)
{
$this->gcsSource = $gcsSource;
}
/**
* @return GcsSource
*/
public function getGcsSource()
{
return $this->gcsSource;
}
/**
* @param string
*/
public function setMimeType($mimeType)
{
$this->mimeType = $mimeType;
}
/**
* @return string
*/
public function getMimeType()
{
return $this->mimeType;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(InputConfig::class, 'Google_Service_Translate_InputConfig');

View File

@@ -0,0 +1,60 @@
<?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\Translate;
class InputFile extends \Google\Model
{
protected $gcsSourceType = GcsInputSource::class;
protected $gcsSourceDataType = '';
/**
* @var string
*/
public $usage;
/**
* @param GcsInputSource
*/
public function setGcsSource(GcsInputSource $gcsSource)
{
$this->gcsSource = $gcsSource;
}
/**
* @return GcsInputSource
*/
public function getGcsSource()
{
return $this->gcsSource;
}
/**
* @param string
*/
public function setUsage($usage)
{
$this->usage = $usage;
}
/**
* @return string
*/
public function getUsage()
{
return $this->usage;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(InputFile::class, 'Google_Service_Translate_InputFile');

View File

@@ -0,0 +1,62 @@
<?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\Translate;
class LanguageCodePair extends \Google\Model
{
/**
* @var string
*/
public $sourceLanguageCode;
/**
* @var string
*/
public $targetLanguageCode;
/**
* @param string
*/
public function setSourceLanguageCode($sourceLanguageCode)
{
$this->sourceLanguageCode = $sourceLanguageCode;
}
/**
* @return string
*/
public function getSourceLanguageCode()
{
return $this->sourceLanguageCode;
}
/**
* @param string
*/
public function setTargetLanguageCode($targetLanguageCode)
{
$this->targetLanguageCode = $targetLanguageCode;
}
/**
* @return string
*/
public function getTargetLanguageCode()
{
return $this->targetLanguageCode;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(LanguageCodePair::class, 'Google_Service_Translate_LanguageCodePair');

View File

@@ -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\Translate;
class LanguageCodesSet extends \Google\Collection
{
protected $collection_key = 'languageCodes';
/**
* @var string[]
*/
public $languageCodes;
/**
* @param string[]
*/
public function setLanguageCodes($languageCodes)
{
$this->languageCodes = $languageCodes;
}
/**
* @return string[]
*/
public function getLanguageCodes()
{
return $this->languageCodes;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(LanguageCodesSet::class, 'Google_Service_Translate_LanguageCodesSet');

View File

@@ -0,0 +1,61 @@
<?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\Translate;
class ListAdaptiveMtDatasetsResponse extends \Google\Collection
{
protected $collection_key = 'adaptiveMtDatasets';
protected $adaptiveMtDatasetsType = AdaptiveMtDataset::class;
protected $adaptiveMtDatasetsDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param AdaptiveMtDataset[]
*/
public function setAdaptiveMtDatasets($adaptiveMtDatasets)
{
$this->adaptiveMtDatasets = $adaptiveMtDatasets;
}
/**
* @return AdaptiveMtDataset[]
*/
public function getAdaptiveMtDatasets()
{
return $this->adaptiveMtDatasets;
}
/**
* @param string
*/
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(ListAdaptiveMtDatasetsResponse::class, 'Google_Service_Translate_ListAdaptiveMtDatasetsResponse');

View File

@@ -0,0 +1,61 @@
<?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\Translate;
class ListAdaptiveMtFilesResponse extends \Google\Collection
{
protected $collection_key = 'adaptiveMtFiles';
protected $adaptiveMtFilesType = AdaptiveMtFile::class;
protected $adaptiveMtFilesDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param AdaptiveMtFile[]
*/
public function setAdaptiveMtFiles($adaptiveMtFiles)
{
$this->adaptiveMtFiles = $adaptiveMtFiles;
}
/**
* @return AdaptiveMtFile[]
*/
public function getAdaptiveMtFiles()
{
return $this->adaptiveMtFiles;
}
/**
* @param string
*/
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(ListAdaptiveMtFilesResponse::class, 'Google_Service_Translate_ListAdaptiveMtFilesResponse');

View File

@@ -0,0 +1,61 @@
<?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\Translate;
class ListAdaptiveMtSentencesResponse extends \Google\Collection
{
protected $collection_key = 'adaptiveMtSentences';
protected $adaptiveMtSentencesType = AdaptiveMtSentence::class;
protected $adaptiveMtSentencesDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param AdaptiveMtSentence[]
*/
public function setAdaptiveMtSentences($adaptiveMtSentences)
{
$this->adaptiveMtSentences = $adaptiveMtSentences;
}
/**
* @return AdaptiveMtSentence[]
*/
public function getAdaptiveMtSentences()
{
return $this->adaptiveMtSentences;
}
/**
* @param string
*/
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(ListAdaptiveMtSentencesResponse::class, 'Google_Service_Translate_ListAdaptiveMtSentencesResponse');

View File

@@ -0,0 +1,61 @@
<?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\Translate;
class ListDatasetsResponse extends \Google\Collection
{
protected $collection_key = 'datasets';
protected $datasetsType = Dataset::class;
protected $datasetsDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param Dataset[]
*/
public function setDatasets($datasets)
{
$this->datasets = $datasets;
}
/**
* @return Dataset[]
*/
public function getDatasets()
{
return $this->datasets;
}
/**
* @param string
*/
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(ListDatasetsResponse::class, 'Google_Service_Translate_ListDatasetsResponse');

View File

@@ -0,0 +1,61 @@
<?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\Translate;
class ListExamplesResponse extends \Google\Collection
{
protected $collection_key = 'examples';
protected $examplesType = Example::class;
protected $examplesDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param Example[]
*/
public function setExamples($examples)
{
$this->examples = $examples;
}
/**
* @return Example[]
*/
public function getExamples()
{
return $this->examples;
}
/**
* @param string
*/
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(ListExamplesResponse::class, 'Google_Service_Translate_ListExamplesResponse');

View File

@@ -0,0 +1,61 @@
<?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\Translate;
class ListGlossariesResponse extends \Google\Collection
{
protected $collection_key = 'glossaries';
protected $glossariesType = Glossary::class;
protected $glossariesDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param Glossary[]
*/
public function setGlossaries($glossaries)
{
$this->glossaries = $glossaries;
}
/**
* @return Glossary[]
*/
public function getGlossaries()
{
return $this->glossaries;
}
/**
* @param string
*/
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(ListGlossariesResponse::class, 'Google_Service_Translate_ListGlossariesResponse');

View File

@@ -0,0 +1,61 @@
<?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\Translate;
class ListGlossaryEntriesResponse extends \Google\Collection
{
protected $collection_key = 'glossaryEntries';
protected $glossaryEntriesType = GlossaryEntry::class;
protected $glossaryEntriesDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param GlossaryEntry[]
*/
public function setGlossaryEntries($glossaryEntries)
{
$this->glossaryEntries = $glossaryEntries;
}
/**
* @return GlossaryEntry[]
*/
public function getGlossaryEntries()
{
return $this->glossaryEntries;
}
/**
* @param string
*/
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(ListGlossaryEntriesResponse::class, 'Google_Service_Translate_ListGlossaryEntriesResponse');

View File

@@ -0,0 +1,61 @@
<?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\Translate;
class ListLocationsResponse extends \Google\Collection
{
protected $collection_key = 'locations';
protected $locationsType = Location::class;
protected $locationsDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param Location[]
*/
public function setLocations($locations)
{
$this->locations = $locations;
}
/**
* @return Location[]
*/
public function getLocations()
{
return $this->locations;
}
/**
* @param string
*/
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(ListLocationsResponse::class, 'Google_Service_Translate_ListLocationsResponse');

View File

@@ -0,0 +1,61 @@
<?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\Translate;
class ListModelsResponse extends \Google\Collection
{
protected $collection_key = 'models';
protected $modelsType = Model::class;
protected $modelsDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param Model[]
*/
public function setModels($models)
{
$this->models = $models;
}
/**
* @return Model[]
*/
public function getModels()
{
return $this->models;
}
/**
* @param string
*/
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(ListModelsResponse::class, 'Google_Service_Translate_ListModelsResponse');

View File

@@ -0,0 +1,61 @@
<?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\Translate;
class ListOperationsResponse extends \Google\Collection
{
protected $collection_key = 'operations';
/**
* @var string
*/
public $nextPageToken;
protected $operationsType = Operation::class;
protected $operationsDataType = 'array';
/**
* @param string
*/
public function setNextPageToken($nextPageToken)
{
$this->nextPageToken = $nextPageToken;
}
/**
* @return string
*/
public function getNextPageToken()
{
return $this->nextPageToken;
}
/**
* @param Operation[]
*/
public function setOperations($operations)
{
$this->operations = $operations;
}
/**
* @return Operation[]
*/
public function getOperations()
{
return $this->operations;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListOperationsResponse::class, 'Google_Service_Translate_ListOperationsResponse');

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\Translate;
class Location extends \Google\Model
{
/**
* @var string
*/
public $displayName;
/**
* @var string[]
*/
public $labels;
/**
* @var string
*/
public $locationId;
/**
* @var array[]
*/
public $metadata;
/**
* @var string
*/
public $name;
/**
* @param string
*/
public function setDisplayName($displayName)
{
$this->displayName = $displayName;
}
/**
* @return string
*/
public function getDisplayName()
{
return $this->displayName;
}
/**
* @param string[]
*/
public function setLabels($labels)
{
$this->labels = $labels;
}
/**
* @return string[]
*/
public function getLabels()
{
return $this->labels;
}
/**
* @param string
*/
public function setLocationId($locationId)
{
$this->locationId = $locationId;
}
/**
* @return string
*/
public function getLocationId()
{
return $this->locationId;
}
/**
* @param array[]
*/
public function setMetadata($metadata)
{
$this->metadata = $metadata;
}
/**
* @return array[]
*/
public function getMetadata()
{
return $this->metadata;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Location::class, 'Google_Service_Translate_Location');

View File

@@ -0,0 +1,206 @@
<?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\Translate;
class Model extends \Google\Model
{
/**
* @var string
*/
public $createTime;
/**
* @var string
*/
public $dataset;
/**
* @var string
*/
public $displayName;
/**
* @var string
*/
public $name;
/**
* @var string
*/
public $sourceLanguageCode;
/**
* @var string
*/
public $targetLanguageCode;
/**
* @var int
*/
public $testExampleCount;
/**
* @var int
*/
public $trainExampleCount;
/**
* @var string
*/
public $updateTime;
/**
* @var int
*/
public $validateExampleCount;
/**
* @param string
*/
public function setCreateTime($createTime)
{
$this->createTime = $createTime;
}
/**
* @return string
*/
public function getCreateTime()
{
return $this->createTime;
}
/**
* @param string
*/
public function setDataset($dataset)
{
$this->dataset = $dataset;
}
/**
* @return string
*/
public function getDataset()
{
return $this->dataset;
}
/**
* @param string
*/
public function setDisplayName($displayName)
{
$this->displayName = $displayName;
}
/**
* @return string
*/
public function getDisplayName()
{
return $this->displayName;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param string
*/
public function setSourceLanguageCode($sourceLanguageCode)
{
$this->sourceLanguageCode = $sourceLanguageCode;
}
/**
* @return string
*/
public function getSourceLanguageCode()
{
return $this->sourceLanguageCode;
}
/**
* @param string
*/
public function setTargetLanguageCode($targetLanguageCode)
{
$this->targetLanguageCode = $targetLanguageCode;
}
/**
* @return string
*/
public function getTargetLanguageCode()
{
return $this->targetLanguageCode;
}
/**
* @param int
*/
public function setTestExampleCount($testExampleCount)
{
$this->testExampleCount = $testExampleCount;
}
/**
* @return int
*/
public function getTestExampleCount()
{
return $this->testExampleCount;
}
/**
* @param int
*/
public function setTrainExampleCount($trainExampleCount)
{
$this->trainExampleCount = $trainExampleCount;
}
/**
* @return int
*/
public function getTrainExampleCount()
{
return $this->trainExampleCount;
}
/**
* @param string
*/
public function setUpdateTime($updateTime)
{
$this->updateTime = $updateTime;
}
/**
* @return string
*/
public function getUpdateTime()
{
return $this->updateTime;
}
/**
* @param int
*/
public function setValidateExampleCount($validateExampleCount)
{
$this->validateExampleCount = $validateExampleCount;
}
/**
* @return int
*/
public function getValidateExampleCount()
{
return $this->validateExampleCount;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Model::class, 'Google_Service_Translate_Model');

View File

@@ -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\Translate;
class Operation extends \Google\Model
{
/**
* @var bool
*/
public $done;
protected $errorType = Status::class;
protected $errorDataType = '';
/**
* @var array[]
*/
public $metadata;
/**
* @var string
*/
public $name;
/**
* @var array[]
*/
public $response;
/**
* @param bool
*/
public function setDone($done)
{
$this->done = $done;
}
/**
* @return bool
*/
public function getDone()
{
return $this->done;
}
/**
* @param Status
*/
public function setError(Status $error)
{
$this->error = $error;
}
/**
* @return Status
*/
public function getError()
{
return $this->error;
}
/**
* @param array[]
*/
public function setMetadata($metadata)
{
$this->metadata = $metadata;
}
/**
* @return array[]
*/
public function getMetadata()
{
return $this->metadata;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param array[]
*/
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_Translate_Operation');

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\Translate;
class OutputConfig extends \Google\Model
{
protected $gcsDestinationType = GcsDestination::class;
protected $gcsDestinationDataType = '';
/**
* @param GcsDestination
*/
public function setGcsDestination(GcsDestination $gcsDestination)
{
$this->gcsDestination = $gcsDestination;
}
/**
* @return GcsDestination
*/
public function getGcsDestination()
{
return $this->gcsDestination;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(OutputConfig::class, 'Google_Service_Translate_OutputConfig');

View File

@@ -0,0 +1,79 @@
<?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\Translate;
class ReferenceSentenceConfig extends \Google\Collection
{
protected $collection_key = 'referenceSentencePairLists';
protected $referenceSentencePairListsType = ReferenceSentencePairList::class;
protected $referenceSentencePairListsDataType = 'array';
/**
* @var string
*/
public $sourceLanguageCode;
/**
* @var string
*/
public $targetLanguageCode;
/**
* @param ReferenceSentencePairList[]
*/
public function setReferenceSentencePairLists($referenceSentencePairLists)
{
$this->referenceSentencePairLists = $referenceSentencePairLists;
}
/**
* @return ReferenceSentencePairList[]
*/
public function getReferenceSentencePairLists()
{
return $this->referenceSentencePairLists;
}
/**
* @param string
*/
public function setSourceLanguageCode($sourceLanguageCode)
{
$this->sourceLanguageCode = $sourceLanguageCode;
}
/**
* @return string
*/
public function getSourceLanguageCode()
{
return $this->sourceLanguageCode;
}
/**
* @param string
*/
public function setTargetLanguageCode($targetLanguageCode)
{
$this->targetLanguageCode = $targetLanguageCode;
}
/**
* @return string
*/
public function getTargetLanguageCode()
{
return $this->targetLanguageCode;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ReferenceSentenceConfig::class, 'Google_Service_Translate_ReferenceSentenceConfig');

View File

@@ -0,0 +1,62 @@
<?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\Translate;
class ReferenceSentencePair extends \Google\Model
{
/**
* @var string
*/
public $sourceSentence;
/**
* @var string
*/
public $targetSentence;
/**
* @param string
*/
public function setSourceSentence($sourceSentence)
{
$this->sourceSentence = $sourceSentence;
}
/**
* @return string
*/
public function getSourceSentence()
{
return $this->sourceSentence;
}
/**
* @param string
*/
public function setTargetSentence($targetSentence)
{
$this->targetSentence = $targetSentence;
}
/**
* @return string
*/
public function getTargetSentence()
{
return $this->targetSentence;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ReferenceSentencePair::class, 'Google_Service_Translate_ReferenceSentencePair');

View File

@@ -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\Translate;
class ReferenceSentencePairList extends \Google\Collection
{
protected $collection_key = 'referenceSentencePairs';
protected $referenceSentencePairsType = ReferenceSentencePair::class;
protected $referenceSentencePairsDataType = 'array';
/**
* @param ReferenceSentencePair[]
*/
public function setReferenceSentencePairs($referenceSentencePairs)
{
$this->referenceSentencePairs = $referenceSentencePairs;
}
/**
* @return ReferenceSentencePair[]
*/
public function getReferenceSentencePairs()
{
return $this->referenceSentencePairs;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ReferenceSentencePairList::class, 'Google_Service_Translate_ReferenceSentencePairList');

View File

@@ -0,0 +1,136 @@
<?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\Translate\Resource;
use Google\Service\Translate\DetectLanguageRequest;
use Google\Service\Translate\DetectLanguageResponse;
use Google\Service\Translate\RomanizeTextRequest;
use Google\Service\Translate\RomanizeTextResponse;
use Google\Service\Translate\SupportedLanguages;
use Google\Service\Translate\TranslateTextRequest;
use Google\Service\Translate\TranslateTextResponse;
/**
* The "projects" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $projects = $translateService->projects;
* </code>
*/
class Projects extends \Google\Service\Resource
{
/**
* Detects the language of text within a request. (projects.detectLanguage)
*
* @param string $parent Required. Project or location to make a call. Must
* refer to a caller's project. Format: `projects/{project-number-or-
* id}/locations/{location-id}` or `projects/{project-number-or-id}`. For global
* calls, use `projects/{project-number-or-id}/locations/global` or
* `projects/{project-number-or-id}`. Only models within the same region (has
* same location-id) can be used. Otherwise an INVALID_ARGUMENT (400) error is
* returned.
* @param DetectLanguageRequest $postBody
* @param array $optParams Optional parameters.
* @return DetectLanguageResponse
* @throws \Google\Service\Exception
*/
public function detectLanguage($parent, DetectLanguageRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('detectLanguage', [$params], DetectLanguageResponse::class);
}
/**
* Returns a list of supported languages for translation.
* (projects.getSupportedLanguages)
*
* @param string $parent Required. Project or location to make a call. Must
* refer to a caller's project. Format: `projects/{project-number-or-id}` or
* `projects/{project-number-or-id}/locations/{location-id}`. For global calls,
* use `projects/{project-number-or-id}/locations/global` or `projects/{project-
* number-or-id}`. Non-global location is required for AutoML models. Only
* models within the same region (have same location-id) can be used, otherwise
* an INVALID_ARGUMENT (400) error is returned.
* @param array $optParams Optional parameters.
*
* @opt_param string displayLanguageCode Optional. The language to use to return
* localized, human readable names of supported languages. If missing, then
* display names are not returned in a response.
* @opt_param string model Optional. Get supported languages of this model. The
* format depends on model type: - AutoML Translation models:
* `projects/{project-number-or-id}/locations/{location-id}/models/{model-id}` -
* General (built-in) models: `projects/{project-number-or-
* id}/locations/{location-id}/models/general/nmt`, Returns languages supported
* by the specified model. If missing, we get supported languages of Google
* general NMT model.
* @return SupportedLanguages
* @throws \Google\Service\Exception
*/
public function getSupportedLanguages($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('getSupportedLanguages', [$params], SupportedLanguages::class);
}
/**
* Romanize input text written in non-Latin scripts to Latin text.
* (projects.romanizeText)
*
* @param string $parent Required. Project or location to make a call. Must
* refer to a caller's project. Format: `projects/{project-number-or-
* id}/locations/{location-id}` or `projects/{project-number-or-id}`. For global
* calls, use `projects/{project-number-or-id}/locations/global` or
* `projects/{project-number-or-id}`.
* @param RomanizeTextRequest $postBody
* @param array $optParams Optional parameters.
* @return RomanizeTextResponse
* @throws \Google\Service\Exception
*/
public function romanizeText($parent, RomanizeTextRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('romanizeText', [$params], RomanizeTextResponse::class);
}
/**
* Translates input text and returns translated text. (projects.translateText)
*
* @param string $parent Required. Project or location to make a call. Must
* refer to a caller's project. Format: `projects/{project-number-or-id}` or
* `projects/{project-number-or-id}/locations/{location-id}`. For global calls,
* use `projects/{project-number-or-id}/locations/global` or `projects/{project-
* number-or-id}`. Non-global location is required for requests using AutoML
* models or custom glossaries. Models and glossaries must be within the same
* region (have same location-id), otherwise an INVALID_ARGUMENT (400) error is
* returned.
* @param TranslateTextRequest $postBody
* @param array $optParams Optional parameters.
* @return TranslateTextResponse
* @throws \Google\Service\Exception
*/
public function translateText($parent, TranslateTextRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('translateText', [$params], TranslateTextResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Projects::class, 'Google_Service_Translate_Resource_Projects');

View File

@@ -0,0 +1,269 @@
<?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\Translate\Resource;
use Google\Service\Translate\AdaptiveMtTranslateRequest;
use Google\Service\Translate\AdaptiveMtTranslateResponse;
use Google\Service\Translate\BatchTranslateDocumentRequest;
use Google\Service\Translate\BatchTranslateTextRequest;
use Google\Service\Translate\DetectLanguageRequest;
use Google\Service\Translate\DetectLanguageResponse;
use Google\Service\Translate\ListLocationsResponse;
use Google\Service\Translate\Location;
use Google\Service\Translate\Operation;
use Google\Service\Translate\RomanizeTextRequest;
use Google\Service\Translate\RomanizeTextResponse;
use Google\Service\Translate\SupportedLanguages;
use Google\Service\Translate\TranslateDocumentRequest;
use Google\Service\Translate\TranslateDocumentResponse;
use Google\Service\Translate\TranslateTextRequest;
use Google\Service\Translate\TranslateTextResponse;
/**
* The "locations" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $locations = $translateService->projects_locations;
* </code>
*/
class ProjectsLocations extends \Google\Service\Resource
{
/**
* Translate text using Adaptive MT. (locations.adaptiveMtTranslate)
*
* @param string $parent Required. Location to make a regional call. Format:
* `projects/{project-number-or-id}/locations/{location-id}`.
* @param AdaptiveMtTranslateRequest $postBody
* @param array $optParams Optional parameters.
* @return AdaptiveMtTranslateResponse
* @throws \Google\Service\Exception
*/
public function adaptiveMtTranslate($parent, AdaptiveMtTranslateRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('adaptiveMtTranslate', [$params], AdaptiveMtTranslateResponse::class);
}
/**
* Translates a large volume of document in asynchronous batch mode. This
* function provides real-time output as the inputs are being processed. If
* caller cancels a request, the partial results (for an input file, it's all or
* nothing) may still be available on the specified output location. This call
* returns immediately and you can use google.longrunning.Operation.name to poll
* the status of the call. (locations.batchTranslateDocument)
*
* @param string $parent Required. Location to make a regional call. Format:
* `projects/{project-number-or-id}/locations/{location-id}`. The `global`
* location is not supported for batch translation. Only AutoML Translation
* models or glossaries within the same region (have the same location-id) can
* be used, otherwise an INVALID_ARGUMENT (400) error is returned.
* @param BatchTranslateDocumentRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function batchTranslateDocument($parent, BatchTranslateDocumentRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('batchTranslateDocument', [$params], Operation::class);
}
/**
* Translates a large volume of text in asynchronous batch mode. This function
* provides real-time output as the inputs are being processed. If caller
* cancels a request, the partial results (for an input file, it's all or
* nothing) may still be available on the specified output location. This call
* returns immediately and you can use google.longrunning.Operation.name to poll
* the status of the call. (locations.batchTranslateText)
*
* @param string $parent Required. Location to make a call. Must refer to a
* caller's project. Format: `projects/{project-number-or-
* id}/locations/{location-id}`. The `global` location is not supported for
* batch translation. Only AutoML Translation models or glossaries within the
* same region (have the same location-id) can be used, otherwise an
* INVALID_ARGUMENT (400) error is returned.
* @param BatchTranslateTextRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function batchTranslateText($parent, BatchTranslateTextRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('batchTranslateText', [$params], Operation::class);
}
/**
* Detects the language of text within a request. (locations.detectLanguage)
*
* @param string $parent Required. Project or location to make a call. Must
* refer to a caller's project. Format: `projects/{project-number-or-
* id}/locations/{location-id}` or `projects/{project-number-or-id}`. For global
* calls, use `projects/{project-number-or-id}/locations/global` or
* `projects/{project-number-or-id}`. Only models within the same region (has
* same location-id) can be used. Otherwise an INVALID_ARGUMENT (400) error is
* returned.
* @param DetectLanguageRequest $postBody
* @param array $optParams Optional parameters.
* @return DetectLanguageResponse
* @throws \Google\Service\Exception
*/
public function detectLanguage($parent, DetectLanguageRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('detectLanguage', [$params], DetectLanguageResponse::class);
}
/**
* Gets information about a location. (locations.get)
*
* @param string $name Resource name for the location.
* @param array $optParams Optional parameters.
* @return Location
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Location::class);
}
/**
* Returns a list of supported languages for translation.
* (locations.getSupportedLanguages)
*
* @param string $parent Required. Project or location to make a call. Must
* refer to a caller's project. Format: `projects/{project-number-or-id}` or
* `projects/{project-number-or-id}/locations/{location-id}`. For global calls,
* use `projects/{project-number-or-id}/locations/global` or `projects/{project-
* number-or-id}`. Non-global location is required for AutoML models. Only
* models within the same region (have same location-id) can be used, otherwise
* an INVALID_ARGUMENT (400) error is returned.
* @param array $optParams Optional parameters.
*
* @opt_param string displayLanguageCode Optional. The language to use to return
* localized, human readable names of supported languages. If missing, then
* display names are not returned in a response.
* @opt_param string model Optional. Get supported languages of this model. The
* format depends on model type: - AutoML Translation models:
* `projects/{project-number-or-id}/locations/{location-id}/models/{model-id}` -
* General (built-in) models: `projects/{project-number-or-
* id}/locations/{location-id}/models/general/nmt`, Returns languages supported
* by the specified model. If missing, we get supported languages of Google
* general NMT model.
* @return SupportedLanguages
* @throws \Google\Service\Exception
*/
public function getSupportedLanguages($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('getSupportedLanguages', [$params], SupportedLanguages::class);
}
/**
* Lists information about the supported locations for this service.
* (locations.listProjectsLocations)
*
* @param string $name The resource that owns the locations collection, if
* applicable.
* @param array $optParams Optional parameters.
*
* @opt_param string filter A filter to narrow down results to a preferred
* subset. The filtering language accepts strings like `"displayName=tokyo"`,
* and is documented in more detail in [AIP-160](https://google.aip.dev/160).
* @opt_param int pageSize The maximum number of results to return. If not set,
* the service selects a default.
* @opt_param string pageToken A page token received from the `next_page_token`
* field in the response. Send that page token to receive the subsequent page.
* @return ListLocationsResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocations($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListLocationsResponse::class);
}
/**
* Romanize input text written in non-Latin scripts to Latin text.
* (locations.romanizeText)
*
* @param string $parent Required. Project or location to make a call. Must
* refer to a caller's project. Format: `projects/{project-number-or-
* id}/locations/{location-id}` or `projects/{project-number-or-id}`. For global
* calls, use `projects/{project-number-or-id}/locations/global` or
* `projects/{project-number-or-id}`.
* @param RomanizeTextRequest $postBody
* @param array $optParams Optional parameters.
* @return RomanizeTextResponse
* @throws \Google\Service\Exception
*/
public function romanizeText($parent, RomanizeTextRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('romanizeText', [$params], RomanizeTextResponse::class);
}
/**
* Translates documents in synchronous mode. (locations.translateDocument)
*
* @param string $parent Required. Location to make a regional call. Format:
* `projects/{project-number-or-id}/locations/{location-id}`. For global calls,
* use `projects/{project-number-or-id}/locations/global` or `projects/{project-
* number-or-id}`. Non-global location is required for requests using AutoML
* models or custom glossaries. Models and glossaries must be within the same
* region (have the same location-id), otherwise an INVALID_ARGUMENT (400) error
* is returned.
* @param TranslateDocumentRequest $postBody
* @param array $optParams Optional parameters.
* @return TranslateDocumentResponse
* @throws \Google\Service\Exception
*/
public function translateDocument($parent, TranslateDocumentRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('translateDocument', [$params], TranslateDocumentResponse::class);
}
/**
* Translates input text and returns translated text. (locations.translateText)
*
* @param string $parent Required. Project or location to make a call. Must
* refer to a caller's project. Format: `projects/{project-number-or-id}` or
* `projects/{project-number-or-id}/locations/{location-id}`. For global calls,
* use `projects/{project-number-or-id}/locations/global` or `projects/{project-
* number-or-id}`. Non-global location is required for requests using AutoML
* models or custom glossaries. Models and glossaries must be within the same
* region (have same location-id), otherwise an INVALID_ARGUMENT (400) error is
* returned.
* @param TranslateTextRequest $postBody
* @param array $optParams Optional parameters.
* @return TranslateTextResponse
* @throws \Google\Service\Exception
*/
public function translateText($parent, TranslateTextRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('translateText', [$params], TranslateTextResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocations::class, 'Google_Service_Translate_Resource_ProjectsLocations');

View File

@@ -0,0 +1,134 @@
<?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\Translate\Resource;
use Google\Service\Translate\AdaptiveMtDataset;
use Google\Service\Translate\ImportAdaptiveMtFileRequest;
use Google\Service\Translate\ImportAdaptiveMtFileResponse;
use Google\Service\Translate\ListAdaptiveMtDatasetsResponse;
use Google\Service\Translate\TranslateEmpty;
/**
* The "adaptiveMtDatasets" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $adaptiveMtDatasets = $translateService->projects_locations_adaptiveMtDatasets;
* </code>
*/
class ProjectsLocationsAdaptiveMtDatasets extends \Google\Service\Resource
{
/**
* Creates an Adaptive MT dataset. (adaptiveMtDatasets.create)
*
* @param string $parent Required. Name of the parent project. In form of
* `projects/{project-number-or-id}/locations/{location-id}`
* @param AdaptiveMtDataset $postBody
* @param array $optParams Optional parameters.
* @return AdaptiveMtDataset
* @throws \Google\Service\Exception
*/
public function create($parent, AdaptiveMtDataset $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], AdaptiveMtDataset::class);
}
/**
* Deletes an Adaptive MT dataset, including all its entries and associated
* metadata. (adaptiveMtDatasets.delete)
*
* @param string $name Required. Name of the dataset. In the form of
* `projects/{project-number-or-id}/locations/{location-
* id}/adaptiveMtDatasets/{adaptive-mt-dataset-id}`
* @param array $optParams Optional parameters.
* @return TranslateEmpty
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], TranslateEmpty::class);
}
/**
* Gets the Adaptive MT dataset. (adaptiveMtDatasets.get)
*
* @param string $name Required. Name of the dataset. In the form of
* `projects/{project-number-or-id}/locations/{location-
* id}/adaptiveMtDatasets/{adaptive-mt-dataset-id}`
* @param array $optParams Optional parameters.
* @return AdaptiveMtDataset
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], AdaptiveMtDataset::class);
}
/**
* Imports an AdaptiveMtFile and adds all of its sentences into the
* AdaptiveMtDataset. (adaptiveMtDatasets.importAdaptiveMtFile)
*
* @param string $parent Required. The resource name of the file, in form of
* `projects/{project-number-or-
* id}/locations/{location_id}/adaptiveMtDatasets/{dataset}`
* @param ImportAdaptiveMtFileRequest $postBody
* @param array $optParams Optional parameters.
* @return ImportAdaptiveMtFileResponse
* @throws \Google\Service\Exception
*/
public function importAdaptiveMtFile($parent, ImportAdaptiveMtFileRequest $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('importAdaptiveMtFile', [$params], ImportAdaptiveMtFileResponse::class);
}
/**
* Lists all Adaptive MT datasets for which the caller has read permission.
* (adaptiveMtDatasets.listProjectsLocationsAdaptiveMtDatasets)
*
* @param string $parent Required. The resource name of the project from which
* to list the Adaptive MT datasets. `projects/{project-number-or-
* id}/locations/{location-id}`
* @param array $optParams Optional parameters.
*
* @opt_param string filter Optional. An expression for filtering the results of
* the request. Filter is not supported yet.
* @opt_param int pageSize Optional. Requested page size. The server may return
* fewer results than requested. If unspecified, the server picks an appropriate
* default.
* @opt_param string pageToken Optional. A token identifying a page of results
* the server should return. Typically, this is the value of
* ListAdaptiveMtDatasetsResponse.next_page_token returned from the previous
* call to `ListAdaptiveMtDatasets` method. The first page is returned if
* `page_token`is empty or missing.
* @return ListAdaptiveMtDatasetsResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsAdaptiveMtDatasets($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListAdaptiveMtDatasetsResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsAdaptiveMtDatasets::class, 'Google_Service_Translate_Resource_ProjectsLocationsAdaptiveMtDatasets');

View File

@@ -0,0 +1,93 @@
<?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\Translate\Resource;
use Google\Service\Translate\AdaptiveMtFile;
use Google\Service\Translate\ListAdaptiveMtFilesResponse;
use Google\Service\Translate\TranslateEmpty;
/**
* The "adaptiveMtFiles" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $adaptiveMtFiles = $translateService->projects_locations_adaptiveMtDatasets_adaptiveMtFiles;
* </code>
*/
class ProjectsLocationsAdaptiveMtDatasetsAdaptiveMtFiles extends \Google\Service\Resource
{
/**
* Deletes an AdaptiveMtFile along with its sentences. (adaptiveMtFiles.delete)
*
* @param string $name Required. The resource name of the file to delete, in
* form of `projects/{project-number-or-id}/locations/{location_id}/adaptiveMtDa
* tasets/{dataset}/adaptiveMtFiles/{file}`
* @param array $optParams Optional parameters.
* @return TranslateEmpty
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], TranslateEmpty::class);
}
/**
* Gets and AdaptiveMtFile (adaptiveMtFiles.get)
*
* @param string $name Required. The resource name of the file, in form of
* `projects/{project-number-or-id}/locations/{location_id}/adaptiveMtDatasets/{
* dataset}/adaptiveMtFiles/{file}`
* @param array $optParams Optional parameters.
* @return AdaptiveMtFile
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], AdaptiveMtFile::class);
}
/**
* Lists all AdaptiveMtFiles associated to an AdaptiveMtDataset.
* (adaptiveMtFiles.listProjectsLocationsAdaptiveMtDatasetsAdaptiveMtFiles)
*
* @param string $parent Required. The resource name of the project from which
* to list the Adaptive MT files.
* `projects/{project}/locations/{location}/adaptiveMtDatasets/{dataset}`
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize Optional.
* @opt_param string pageToken Optional. A token identifying a page of results
* the server should return. Typically, this is the value of
* ListAdaptiveMtFilesResponse.next_page_token returned from the previous call
* to `ListAdaptiveMtFiles` method. The first page is returned if `page_token`is
* empty or missing.
* @return ListAdaptiveMtFilesResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsAdaptiveMtDatasetsAdaptiveMtFiles($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListAdaptiveMtFilesResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsAdaptiveMtDatasetsAdaptiveMtFiles::class, 'Google_Service_Translate_Resource_ProjectsLocationsAdaptiveMtDatasetsAdaptiveMtFiles');

View File

@@ -0,0 +1,62 @@
<?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\Translate\Resource;
use Google\Service\Translate\ListAdaptiveMtSentencesResponse;
/**
* The "adaptiveMtSentences" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $adaptiveMtSentences = $translateService->projects_locations_adaptiveMtDatasets_adaptiveMtFiles_adaptiveMtSentences;
* </code>
*/
class ProjectsLocationsAdaptiveMtDatasetsAdaptiveMtFilesAdaptiveMtSentences extends \Google\Service\Resource
{
/**
* Lists all AdaptiveMtSentences under a given file/dataset. (adaptiveMtSentence
* s.listProjectsLocationsAdaptiveMtDatasetsAdaptiveMtFilesAdaptiveMtSentences)
*
* @param string $parent Required. The resource name of the project from which
* to list the Adaptive MT files. The following format lists all sentences under
* a file. `projects/{project}/locations/{location}/adaptiveMtDatasets/{dataset}
* /adaptiveMtFiles/{file}` The following format lists all sentences within a
* dataset.
* `projects/{project}/locations/{location}/adaptiveMtDatasets/{dataset}`
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize
* @opt_param string pageToken A token identifying a page of results the server
* should return. Typically, this is the value of
* ListAdaptiveMtSentencesRequest.next_page_token returned from the previous
* call to `ListTranslationMemories` method. The first page is returned if
* `page_token` is empty or missing.
* @return ListAdaptiveMtSentencesResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsAdaptiveMtDatasetsAdaptiveMtFilesAdaptiveMtSentences($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListAdaptiveMtSentencesResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsAdaptiveMtDatasetsAdaptiveMtFilesAdaptiveMtSentences::class, 'Google_Service_Translate_Resource_ProjectsLocationsAdaptiveMtDatasetsAdaptiveMtFilesAdaptiveMtSentences');

View File

@@ -0,0 +1,62 @@
<?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\Translate\Resource;
use Google\Service\Translate\ListAdaptiveMtSentencesResponse;
/**
* The "adaptiveMtSentences" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $adaptiveMtSentences = $translateService->projects_locations_adaptiveMtDatasets_adaptiveMtSentences;
* </code>
*/
class ProjectsLocationsAdaptiveMtDatasetsAdaptiveMtSentences extends \Google\Service\Resource
{
/**
* Lists all AdaptiveMtSentences under a given file/dataset. (adaptiveMtSentence
* s.listProjectsLocationsAdaptiveMtDatasetsAdaptiveMtSentences)
*
* @param string $parent Required. The resource name of the project from which
* to list the Adaptive MT files. The following format lists all sentences under
* a file. `projects/{project}/locations/{location}/adaptiveMtDatasets/{dataset}
* /adaptiveMtFiles/{file}` The following format lists all sentences within a
* dataset.
* `projects/{project}/locations/{location}/adaptiveMtDatasets/{dataset}`
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize
* @opt_param string pageToken A token identifying a page of results the server
* should return. Typically, this is the value of
* ListAdaptiveMtSentencesRequest.next_page_token returned from the previous
* call to `ListTranslationMemories` method. The first page is returned if
* `page_token` is empty or missing.
* @return ListAdaptiveMtSentencesResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsAdaptiveMtDatasetsAdaptiveMtSentences($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListAdaptiveMtSentencesResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsAdaptiveMtDatasetsAdaptiveMtSentences::class, 'Google_Service_Translate_Resource_ProjectsLocationsAdaptiveMtDatasetsAdaptiveMtSentences');

View File

@@ -0,0 +1,137 @@
<?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\Translate\Resource;
use Google\Service\Translate\Dataset;
use Google\Service\Translate\ExportDataRequest;
use Google\Service\Translate\ImportDataRequest;
use Google\Service\Translate\ListDatasetsResponse;
use Google\Service\Translate\Operation;
/**
* The "datasets" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $datasets = $translateService->projects_locations_datasets;
* </code>
*/
class ProjectsLocationsDatasets extends \Google\Service\Resource
{
/**
* Creates a Dataset. (datasets.create)
*
* @param string $parent Required. The project name.
* @param Dataset $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function create($parent, Dataset $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Operation::class);
}
/**
* Deletes a dataset and all of its contents. (datasets.delete)
*
* @param string $name Required. The name of the dataset to delete.
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], Operation::class);
}
/**
* Exports dataset's data to the provided output location. (datasets.exportData)
*
* @param string $dataset Required. Name of the dataset. In form of
* `projects/{project-number-or-id}/locations/{location-id}/datasets/{dataset-
* id}`
* @param ExportDataRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function exportData($dataset, ExportDataRequest $postBody, $optParams = [])
{
$params = ['dataset' => $dataset, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('exportData', [$params], Operation::class);
}
/**
* Gets a Dataset. (datasets.get)
*
* @param string $name Required. The resource name of the dataset to retrieve.
* @param array $optParams Optional parameters.
* @return Dataset
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Dataset::class);
}
/**
* Import sentence pairs into translation Dataset. (datasets.importData)
*
* @param string $dataset Required. Name of the dataset. In form of
* `projects/{project-number-or-id}/locations/{location-id}/datasets/{dataset-
* id}`
* @param ImportDataRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function importData($dataset, ImportDataRequest $postBody, $optParams = [])
{
$params = ['dataset' => $dataset, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('importData', [$params], Operation::class);
}
/**
* Lists datasets. (datasets.listProjectsLocationsDatasets)
*
* @param string $parent Required. Name of the parent project. In form of
* `projects/{project-number-or-id}/locations/{location-id}`
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize Optional. Requested page size. The server can return
* fewer results than requested.
* @opt_param string pageToken Optional. A token identifying a page of results
* for the server to return. Typically obtained from next_page_token field in
* the response of a ListDatasets call.
* @return ListDatasetsResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsDatasets($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListDatasetsResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsDatasets::class, 'Google_Service_Translate_Resource_ProjectsLocationsDatasets');

View File

@@ -0,0 +1,60 @@
<?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\Translate\Resource;
use Google\Service\Translate\ListExamplesResponse;
/**
* The "examples" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $examples = $translateService->projects_locations_datasets_examples;
* </code>
*/
class ProjectsLocationsDatasetsExamples extends \Google\Service\Resource
{
/**
* Lists sentence pairs in the dataset.
* (examples.listProjectsLocationsDatasetsExamples)
*
* @param string $parent Required. Name of the parent dataset. In form of
* `projects/{project-number-or-id}/locations/{location-id}/datasets/{dataset-
* id}`
* @param array $optParams Optional parameters.
*
* @opt_param string filter Optional. An expression for filtering the examples
* that will be returned. Example filter: * `usage=TRAIN`
* @opt_param int pageSize Optional. Requested page size. The server can return
* fewer results than requested.
* @opt_param string pageToken Optional. A token identifying a page of results
* for the server to return. Typically obtained from next_page_token field in
* the response of a ListExamples call.
* @return ListExamplesResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsDatasetsExamples($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListExamplesResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsDatasetsExamples::class, 'Google_Service_Translate_Resource_ProjectsLocationsDatasetsExamples');

View File

@@ -0,0 +1,145 @@
<?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\Translate\Resource;
use Google\Service\Translate\Glossary;
use Google\Service\Translate\ListGlossariesResponse;
use Google\Service\Translate\Operation;
/**
* The "glossaries" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $glossaries = $translateService->projects_locations_glossaries;
* </code>
*/
class ProjectsLocationsGlossaries extends \Google\Service\Resource
{
/**
* Creates a glossary and returns the long-running operation. Returns NOT_FOUND,
* if the project doesn't exist. (glossaries.create)
*
* @param string $parent Required. The project name.
* @param Glossary $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function create($parent, Glossary $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Operation::class);
}
/**
* Deletes a glossary, or cancels glossary construction if the glossary isn't
* created yet. Returns NOT_FOUND, if the glossary doesn't exist.
* (glossaries.delete)
*
* @param string $name Required. The name of the glossary to delete.
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], Operation::class);
}
/**
* Gets a glossary. Returns NOT_FOUND, if the glossary doesn't exist.
* (glossaries.get)
*
* @param string $name Required. The name of the glossary to retrieve.
* @param array $optParams Optional parameters.
* @return Glossary
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Glossary::class);
}
/**
* Lists glossaries in a project. Returns NOT_FOUND, if the project doesn't
* exist. (glossaries.listProjectsLocationsGlossaries)
*
* @param string $parent Required. The name of the project from which to list
* all of the glossaries.
* @param array $optParams Optional parameters.
*
* @opt_param string filter Optional. Filter specifying constraints of a list
* operation. Specify the constraint by the format of "key=value", where key
* must be "src" or "tgt", and the value must be a valid language code. For
* multiple restrictions, concatenate them by "AND" (uppercase only), such as:
* "src=en-US AND tgt=zh-CN". Notice that the exact match is used here, which
* means using 'en-US' and 'en' can lead to different results, which depends on
* the language code you used when you create the glossary. For the
* unidirectional glossaries, the "src" and "tgt" add restrictions on the source
* and target language code separately. For the equivalent term set glossaries,
* the "src" and/or "tgt" add restrictions on the term set. For example:
* "src=en-US AND tgt=zh-CN" will only pick the unidirectional glossaries which
* exactly match the source language code as "en-US" and the target language
* code "zh-CN", but all equivalent term set glossaries which contain "en-US"
* and "zh-CN" in their language set will be picked. If missing, no filtering is
* performed.
* @opt_param int pageSize Optional. Requested page size. The server may return
* fewer glossaries than requested. If unspecified, the server picks an
* appropriate default.
* @opt_param string pageToken Optional. A token identifying a page of results
* the server should return. Typically, this is the value of
* [ListGlossariesResponse.next_page_token] returned from the previous call to
* `ListGlossaries` method. The first page is returned if `page_token`is empty
* or missing.
* @return ListGlossariesResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsGlossaries($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListGlossariesResponse::class);
}
/**
* Updates a glossary. A LRO is used since the update can be async if the
* glossary's entry file is updated. (glossaries.patch)
*
* @param string $name Required. The resource name of the glossary. Glossary
* names have the form `projects/{project-number-or-id}/locations/{location-
* id}/glossaries/{glossary-id}`.
* @param Glossary $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string updateMask The list of fields to be updated. Currently only
* `display_name` and 'input_config'
* @return Operation
* @throws \Google\Service\Exception
*/
public function patch($name, Glossary $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], Operation::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsGlossaries::class, 'Google_Service_Translate_Resource_ProjectsLocationsGlossaries');

View File

@@ -0,0 +1,122 @@
<?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\Translate\Resource;
use Google\Service\Translate\GlossaryEntry;
use Google\Service\Translate\ListGlossaryEntriesResponse;
use Google\Service\Translate\TranslateEmpty;
/**
* The "glossaryEntries" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $glossaryEntries = $translateService->projects_locations_glossaries_glossaryEntries;
* </code>
*/
class ProjectsLocationsGlossariesGlossaryEntries extends \Google\Service\Resource
{
/**
* Creates a glossary entry. (glossaryEntries.create)
*
* @param string $parent Required. The resource name of the glossary to create
* the entry under.
* @param GlossaryEntry $postBody
* @param array $optParams Optional parameters.
* @return GlossaryEntry
* @throws \Google\Service\Exception
*/
public function create($parent, GlossaryEntry $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], GlossaryEntry::class);
}
/**
* Deletes a single entry from the glossary (glossaryEntries.delete)
*
* @param string $name Required. The resource name of the glossary entry to
* delete
* @param array $optParams Optional parameters.
* @return TranslateEmpty
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], TranslateEmpty::class);
}
/**
* Gets a single glossary entry by the given id. (glossaryEntries.get)
*
* @param string $name Required. The resource name of the glossary entry to get
* @param array $optParams Optional parameters.
* @return GlossaryEntry
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], GlossaryEntry::class);
}
/**
* List the entries for the glossary.
* (glossaryEntries.listProjectsLocationsGlossariesGlossaryEntries)
*
* @param string $parent Required. The parent glossary resource name for listing
* the glossary's entries.
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize Optional. Requested page size. The server may return
* fewer glossary entries than requested. If unspecified, the server picks an
* appropriate default.
* @opt_param string pageToken Optional. A token identifying a page of results
* the server should return. Typically, this is the value of
* [ListGlossaryEntriesResponse.next_page_token] returned from the previous
* call. The first page is returned if `page_token`is empty or missing.
* @return ListGlossaryEntriesResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsGlossariesGlossaryEntries($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListGlossaryEntriesResponse::class);
}
/**
* Updates a glossary entry. (glossaryEntries.patch)
*
* @param string $name Identifier. The resource name of the entry. Format:
* `projects/locations/glossaries/glossaryEntries`
* @param GlossaryEntry $postBody
* @param array $optParams Optional parameters.
* @return GlossaryEntry
* @throws \Google\Service\Exception
*/
public function patch($name, GlossaryEntry $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], GlossaryEntry::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsGlossariesGlossaryEntries::class, 'Google_Service_Translate_Resource_ProjectsLocationsGlossariesGlossaryEntries');

View File

@@ -0,0 +1,104 @@
<?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\Translate\Resource;
use Google\Service\Translate\ListModelsResponse;
use Google\Service\Translate\Model;
use Google\Service\Translate\Operation;
/**
* The "models" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $models = $translateService->projects_locations_models;
* </code>
*/
class ProjectsLocationsModels extends \Google\Service\Resource
{
/**
* Creates a Model. (models.create)
*
* @param string $parent Required. The project name, in form of
* `projects/{project}/locations/{location}`
* @param Model $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function create($parent, Model $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Operation::class);
}
/**
* Deletes a model. (models.delete)
*
* @param string $name Required. The name of the model to delete.
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], Operation::class);
}
/**
* Gets a model. (models.get)
*
* @param string $name Required. The resource name of the model to retrieve.
* @param array $optParams Optional parameters.
* @return Model
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Model::class);
}
/**
* Lists models. (models.listProjectsLocationsModels)
*
* @param string $parent Required. Name of the parent project. In form of
* `projects/{project-number-or-id}/locations/{location-id}`
* @param array $optParams Optional parameters.
*
* @opt_param string filter Optional. An expression for filtering the models
* that will be returned. Supported filter: `dataset_id=${dataset_id}`
* @opt_param int pageSize Optional. Requested page size. The server can return
* fewer results than requested.
* @opt_param string pageToken Optional. A token identifying a page of results
* for the server to return. Typically obtained from next_page_token field in
* the response of a ListModels call.
* @return ListModelsResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsModels($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListModelsResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsModels::class, 'Google_Service_Translate_Resource_ProjectsLocationsModels');

View File

@@ -0,0 +1,138 @@
<?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\Translate\Resource;
use Google\Service\Translate\CancelOperationRequest;
use Google\Service\Translate\ListOperationsResponse;
use Google\Service\Translate\Operation;
use Google\Service\Translate\TranslateEmpty;
use Google\Service\Translate\WaitOperationRequest;
/**
* The "operations" collection of methods.
* Typical usage is:
* <code>
* $translateService = new Google\Service\Translate(...);
* $operations = $translateService->projects_locations_operations;
* </code>
*/
class ProjectsLocationsOperations extends \Google\Service\Resource
{
/**
* Starts asynchronous cancellation on a long-running operation. The server
* makes a best effort to cancel the operation, but success is not guaranteed.
* If the server doesn't support this method, it returns
* `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or
* other methods to check whether the cancellation succeeded or whether the
* operation completed despite cancellation. On successful cancellation, the
* operation is not deleted; instead, it becomes an operation with an
* Operation.error value with a google.rpc.Status.code of 1, corresponding to
* `Code.CANCELLED`. (operations.cancel)
*
* @param string $name The name of the operation resource to be cancelled.
* @param CancelOperationRequest $postBody
* @param array $optParams Optional parameters.
* @return TranslateEmpty
* @throws \Google\Service\Exception
*/
public function cancel($name, CancelOperationRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('cancel', [$params], TranslateEmpty::class);
}
/**
* Deletes a long-running operation. This method indicates that the client is no
* longer interested in the operation result. It does not cancel the operation.
* If the server doesn't support this method, it returns
* `google.rpc.Code.UNIMPLEMENTED`. (operations.delete)
*
* @param string $name The name of the operation resource to be deleted.
* @param array $optParams Optional parameters.
* @return TranslateEmpty
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], TranslateEmpty::class);
}
/**
* Gets the latest state of a long-running operation. Clients can use this
* method to poll the operation result at intervals as recommended by the API
* service. (operations.get)
*
* @param string $name The name of the operation resource.
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Operation::class);
}
/**
* Lists operations that match the specified filter in the request. If the
* server doesn't support this method, it returns `UNIMPLEMENTED`.
* (operations.listProjectsLocationsOperations)
*
* @param string $name The name of the operation's parent resource.
* @param array $optParams Optional parameters.
*
* @opt_param string filter The standard list filter.
* @opt_param int pageSize The standard list page size.
* @opt_param string pageToken The standard list page token.
* @return ListOperationsResponse
* @throws \Google\Service\Exception
*/
public function listProjectsLocationsOperations($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListOperationsResponse::class);
}
/**
* Waits until the specified long-running operation is done or reaches at most a
* specified timeout, returning the latest state. If the operation is already
* done, the latest state is immediately returned. If the timeout specified is
* greater than the default HTTP/RPC timeout, the HTTP/RPC timeout is used. If
* the server does not support this method, it returns
* `google.rpc.Code.UNIMPLEMENTED`. Note that this method is on a best-effort
* basis. It may return the latest state before the specified timeout (including
* immediately), meaning even an immediate response is no guarantee that the
* operation is done. (operations.wait)
*
* @param string $name The name of the operation resource to wait on.
* @param WaitOperationRequest $postBody
* @param array $optParams Optional parameters.
* @return Operation
* @throws \Google\Service\Exception
*/
public function wait($name, WaitOperationRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('wait', [$params], Operation::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ProjectsLocationsOperations::class, 'Google_Service_Translate_Resource_ProjectsLocationsOperations');

View File

@@ -0,0 +1,62 @@
<?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\Translate;
class Romanization extends \Google\Model
{
/**
* @var string
*/
public $detectedLanguageCode;
/**
* @var string
*/
public $romanizedText;
/**
* @param string
*/
public function setDetectedLanguageCode($detectedLanguageCode)
{
$this->detectedLanguageCode = $detectedLanguageCode;
}
/**
* @return string
*/
public function getDetectedLanguageCode()
{
return $this->detectedLanguageCode;
}
/**
* @param string
*/
public function setRomanizedText($romanizedText)
{
$this->romanizedText = $romanizedText;
}
/**
* @return string
*/
public function getRomanizedText()
{
return $this->romanizedText;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Romanization::class, 'Google_Service_Translate_Romanization');

View File

@@ -0,0 +1,63 @@
<?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\Translate;
class RomanizeTextRequest extends \Google\Collection
{
protected $collection_key = 'contents';
/**
* @var string[]
*/
public $contents;
/**
* @var string
*/
public $sourceLanguageCode;
/**
* @param string[]
*/
public function setContents($contents)
{
$this->contents = $contents;
}
/**
* @return string[]
*/
public function getContents()
{
return $this->contents;
}
/**
* @param string
*/
public function setSourceLanguageCode($sourceLanguageCode)
{
$this->sourceLanguageCode = $sourceLanguageCode;
}
/**
* @return string
*/
public function getSourceLanguageCode()
{
return $this->sourceLanguageCode;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(RomanizeTextRequest::class, 'Google_Service_Translate_RomanizeTextRequest');

View File

@@ -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\Translate;
class RomanizeTextResponse extends \Google\Collection
{
protected $collection_key = 'romanizations';
protected $romanizationsType = Romanization::class;
protected $romanizationsDataType = 'array';
/**
* @param Romanization[]
*/
public function setRomanizations($romanizations)
{
$this->romanizations = $romanizations;
}
/**
* @return Romanization[]
*/
public function getRomanizations()
{
return $this->romanizations;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(RomanizeTextResponse::class, 'Google_Service_Translate_RomanizeTextResponse');

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\Translate;
class Status extends \Google\Collection
{
protected $collection_key = 'details';
/**
* @var int
*/
public $code;
/**
* @var array[]
*/
public $details;
/**
* @var string
*/
public $message;
/**
* @param int
*/
public function setCode($code)
{
$this->code = $code;
}
/**
* @return int
*/
public function getCode()
{
return $this->code;
}
/**
* @param array[]
*/
public function setDetails($details)
{
$this->details = $details;
}
/**
* @return array[]
*/
public function getDetails()
{
return $this->details;
}
/**
* @param string
*/
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_Translate_Status');

View File

@@ -0,0 +1,98 @@
<?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\Translate;
class SupportedLanguage extends \Google\Model
{
/**
* @var string
*/
public $displayName;
/**
* @var string
*/
public $languageCode;
/**
* @var bool
*/
public $supportSource;
/**
* @var bool
*/
public $supportTarget;
/**
* @param string
*/
public function setDisplayName($displayName)
{
$this->displayName = $displayName;
}
/**
* @return string
*/
public function getDisplayName()
{
return $this->displayName;
}
/**
* @param string
*/
public function setLanguageCode($languageCode)
{
$this->languageCode = $languageCode;
}
/**
* @return string
*/
public function getLanguageCode()
{
return $this->languageCode;
}
/**
* @param bool
*/
public function setSupportSource($supportSource)
{
$this->supportSource = $supportSource;
}
/**
* @return bool
*/
public function getSupportSource()
{
return $this->supportSource;
}
/**
* @param bool
*/
public function setSupportTarget($supportTarget)
{
$this->supportTarget = $supportTarget;
}
/**
* @return bool
*/
public function getSupportTarget()
{
return $this->supportTarget;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(SupportedLanguage::class, 'Google_Service_Translate_SupportedLanguage');

View File

@@ -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\Translate;
class SupportedLanguages extends \Google\Collection
{
protected $collection_key = 'languages';
protected $languagesType = SupportedLanguage::class;
protected $languagesDataType = 'array';
/**
* @param SupportedLanguage[]
*/
public function setLanguages($languages)
{
$this->languages = $languages;
}
/**
* @return SupportedLanguage[]
*/
public function getLanguages()
{
return $this->languages;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(SupportedLanguages::class, 'Google_Service_Translate_SupportedLanguages');

View File

@@ -0,0 +1,218 @@
<?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\Translate;
class TranslateDocumentRequest extends \Google\Model
{
/**
* @var string
*/
public $customizedAttribution;
protected $documentInputConfigType = DocumentInputConfig::class;
protected $documentInputConfigDataType = '';
protected $documentOutputConfigType = DocumentOutputConfig::class;
protected $documentOutputConfigDataType = '';
/**
* @var bool
*/
public $enableRotationCorrection;
/**
* @var bool
*/
public $enableShadowRemovalNativePdf;
protected $glossaryConfigType = TranslateTextGlossaryConfig::class;
protected $glossaryConfigDataType = '';
/**
* @var bool
*/
public $isTranslateNativePdfOnly;
/**
* @var string[]
*/
public $labels;
/**
* @var string
*/
public $model;
/**
* @var string
*/
public $sourceLanguageCode;
/**
* @var string
*/
public $targetLanguageCode;
/**
* @param string
*/
public function setCustomizedAttribution($customizedAttribution)
{
$this->customizedAttribution = $customizedAttribution;
}
/**
* @return string
*/
public function getCustomizedAttribution()
{
return $this->customizedAttribution;
}
/**
* @param DocumentInputConfig
*/
public function setDocumentInputConfig(DocumentInputConfig $documentInputConfig)
{
$this->documentInputConfig = $documentInputConfig;
}
/**
* @return DocumentInputConfig
*/
public function getDocumentInputConfig()
{
return $this->documentInputConfig;
}
/**
* @param DocumentOutputConfig
*/
public function setDocumentOutputConfig(DocumentOutputConfig $documentOutputConfig)
{
$this->documentOutputConfig = $documentOutputConfig;
}
/**
* @return DocumentOutputConfig
*/
public function getDocumentOutputConfig()
{
return $this->documentOutputConfig;
}
/**
* @param bool
*/
public function setEnableRotationCorrection($enableRotationCorrection)
{
$this->enableRotationCorrection = $enableRotationCorrection;
}
/**
* @return bool
*/
public function getEnableRotationCorrection()
{
return $this->enableRotationCorrection;
}
/**
* @param bool
*/
public function setEnableShadowRemovalNativePdf($enableShadowRemovalNativePdf)
{
$this->enableShadowRemovalNativePdf = $enableShadowRemovalNativePdf;
}
/**
* @return bool
*/
public function getEnableShadowRemovalNativePdf()
{
return $this->enableShadowRemovalNativePdf;
}
/**
* @param TranslateTextGlossaryConfig
*/
public function setGlossaryConfig(TranslateTextGlossaryConfig $glossaryConfig)
{
$this->glossaryConfig = $glossaryConfig;
}
/**
* @return TranslateTextGlossaryConfig
*/
public function getGlossaryConfig()
{
return $this->glossaryConfig;
}
/**
* @param bool
*/
public function setIsTranslateNativePdfOnly($isTranslateNativePdfOnly)
{
$this->isTranslateNativePdfOnly = $isTranslateNativePdfOnly;
}
/**
* @return bool
*/
public function getIsTranslateNativePdfOnly()
{
return $this->isTranslateNativePdfOnly;
}
/**
* @param string[]
*/
public function setLabels($labels)
{
$this->labels = $labels;
}
/**
* @return string[]
*/
public function getLabels()
{
return $this->labels;
}
/**
* @param string
*/
public function setModel($model)
{
$this->model = $model;
}
/**
* @return string
*/
public function getModel()
{
return $this->model;
}
/**
* @param string
*/
public function setSourceLanguageCode($sourceLanguageCode)
{
$this->sourceLanguageCode = $sourceLanguageCode;
}
/**
* @return string
*/
public function getSourceLanguageCode()
{
return $this->sourceLanguageCode;
}
/**
* @param string
*/
public function setTargetLanguageCode($targetLanguageCode)
{
$this->targetLanguageCode = $targetLanguageCode;
}
/**
* @return string
*/
public function getTargetLanguageCode()
{
return $this->targetLanguageCode;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(TranslateDocumentRequest::class, 'Google_Service_Translate_TranslateDocumentRequest');

View File

@@ -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\Translate;
class TranslateDocumentResponse extends \Google\Model
{
protected $documentTranslationType = DocumentTranslation::class;
protected $documentTranslationDataType = '';
protected $glossaryConfigType = TranslateTextGlossaryConfig::class;
protected $glossaryConfigDataType = '';
protected $glossaryDocumentTranslationType = DocumentTranslation::class;
protected $glossaryDocumentTranslationDataType = '';
/**
* @var string
*/
public $model;
/**
* @param DocumentTranslation
*/
public function setDocumentTranslation(DocumentTranslation $documentTranslation)
{
$this->documentTranslation = $documentTranslation;
}
/**
* @return DocumentTranslation
*/
public function getDocumentTranslation()
{
return $this->documentTranslation;
}
/**
* @param TranslateTextGlossaryConfig
*/
public function setGlossaryConfig(TranslateTextGlossaryConfig $glossaryConfig)
{
$this->glossaryConfig = $glossaryConfig;
}
/**
* @return TranslateTextGlossaryConfig
*/
public function getGlossaryConfig()
{
return $this->glossaryConfig;
}
/**
* @param DocumentTranslation
*/
public function setGlossaryDocumentTranslation(DocumentTranslation $glossaryDocumentTranslation)
{
$this->glossaryDocumentTranslation = $glossaryDocumentTranslation;
}
/**
* @return DocumentTranslation
*/
public function getGlossaryDocumentTranslation()
{
return $this->glossaryDocumentTranslation;
}
/**
* @param string
*/
public function setModel($model)
{
$this->model = $model;
}
/**
* @return string
*/
public function getModel()
{
return $this->model;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(TranslateDocumentResponse::class, 'Google_Service_Translate_TranslateDocumentResponse');

View File

@@ -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\Translate;
class TranslateEmpty extends \Google\Model
{
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(TranslateEmpty::class, 'Google_Service_Translate_TranslateEmpty');

View File

@@ -0,0 +1,62 @@
<?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\Translate;
class TranslateTextGlossaryConfig extends \Google\Model
{
/**
* @var string
*/
public $glossary;
/**
* @var bool
*/
public $ignoreCase;
/**
* @param string
*/
public function setGlossary($glossary)
{
$this->glossary = $glossary;
}
/**
* @return string
*/
public function getGlossary()
{
return $this->glossary;
}
/**
* @param bool
*/
public function setIgnoreCase($ignoreCase)
{
$this->ignoreCase = $ignoreCase;
}
/**
* @return bool
*/
public function getIgnoreCase()
{
return $this->ignoreCase;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(TranslateTextGlossaryConfig::class, 'Google_Service_Translate_TranslateTextGlossaryConfig');

View File

@@ -0,0 +1,167 @@
<?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\Translate;
class TranslateTextRequest extends \Google\Collection
{
protected $collection_key = 'contents';
/**
* @var string[]
*/
public $contents;
protected $glossaryConfigType = TranslateTextGlossaryConfig::class;
protected $glossaryConfigDataType = '';
/**
* @var string[]
*/
public $labels;
/**
* @var string
*/
public $mimeType;
/**
* @var string
*/
public $model;
/**
* @var string
*/
public $sourceLanguageCode;
/**
* @var string
*/
public $targetLanguageCode;
protected $transliterationConfigType = TransliterationConfig::class;
protected $transliterationConfigDataType = '';
/**
* @param string[]
*/
public function setContents($contents)
{
$this->contents = $contents;
}
/**
* @return string[]
*/
public function getContents()
{
return $this->contents;
}
/**
* @param TranslateTextGlossaryConfig
*/
public function setGlossaryConfig(TranslateTextGlossaryConfig $glossaryConfig)
{
$this->glossaryConfig = $glossaryConfig;
}
/**
* @return TranslateTextGlossaryConfig
*/
public function getGlossaryConfig()
{
return $this->glossaryConfig;
}
/**
* @param string[]
*/
public function setLabels($labels)
{
$this->labels = $labels;
}
/**
* @return string[]
*/
public function getLabels()
{
return $this->labels;
}
/**
* @param string
*/
public function setMimeType($mimeType)
{
$this->mimeType = $mimeType;
}
/**
* @return string
*/
public function getMimeType()
{
return $this->mimeType;
}
/**
* @param string
*/
public function setModel($model)
{
$this->model = $model;
}
/**
* @return string
*/
public function getModel()
{
return $this->model;
}
/**
* @param string
*/
public function setSourceLanguageCode($sourceLanguageCode)
{
$this->sourceLanguageCode = $sourceLanguageCode;
}
/**
* @return string
*/
public function getSourceLanguageCode()
{
return $this->sourceLanguageCode;
}
/**
* @param string
*/
public function setTargetLanguageCode($targetLanguageCode)
{
$this->targetLanguageCode = $targetLanguageCode;
}
/**
* @return string
*/
public function getTargetLanguageCode()
{
return $this->targetLanguageCode;
}
/**
* @param TransliterationConfig
*/
public function setTransliterationConfig(TransliterationConfig $transliterationConfig)
{
$this->transliterationConfig = $transliterationConfig;
}
/**
* @return TransliterationConfig
*/
public function getTransliterationConfig()
{
return $this->transliterationConfig;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(TranslateTextRequest::class, 'Google_Service_Translate_TranslateTextRequest');

View File

@@ -0,0 +1,59 @@
<?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\Translate;
class TranslateTextResponse extends \Google\Collection
{
protected $collection_key = 'translations';
protected $glossaryTranslationsType = Translation::class;
protected $glossaryTranslationsDataType = 'array';
protected $translationsType = Translation::class;
protected $translationsDataType = 'array';
/**
* @param Translation[]
*/
public function setGlossaryTranslations($glossaryTranslations)
{
$this->glossaryTranslations = $glossaryTranslations;
}
/**
* @return Translation[]
*/
public function getGlossaryTranslations()
{
return $this->glossaryTranslations;
}
/**
* @param Translation[]
*/
public function setTranslations($translations)
{
$this->translations = $translations;
}
/**
* @return Translation[]
*/
public function getTranslations()
{
return $this->translations;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(TranslateTextResponse::class, 'Google_Service_Translate_TranslateTextResponse');

View File

@@ -0,0 +1,96 @@
<?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\Translate;
class Translation extends \Google\Model
{
/**
* @var string
*/
public $detectedLanguageCode;
protected $glossaryConfigType = TranslateTextGlossaryConfig::class;
protected $glossaryConfigDataType = '';
/**
* @var string
*/
public $model;
/**
* @var string
*/
public $translatedText;
/**
* @param string
*/
public function setDetectedLanguageCode($detectedLanguageCode)
{
$this->detectedLanguageCode = $detectedLanguageCode;
}
/**
* @return string
*/
public function getDetectedLanguageCode()
{
return $this->detectedLanguageCode;
}
/**
* @param TranslateTextGlossaryConfig
*/
public function setGlossaryConfig(TranslateTextGlossaryConfig $glossaryConfig)
{
$this->glossaryConfig = $glossaryConfig;
}
/**
* @return TranslateTextGlossaryConfig
*/
public function getGlossaryConfig()
{
return $this->glossaryConfig;
}
/**
* @param string
*/
public function setModel($model)
{
$this->model = $model;
}
/**
* @return string
*/
public function getModel()
{
return $this->model;
}
/**
* @param string
*/
public function setTranslatedText($translatedText)
{
$this->translatedText = $translatedText;
}
/**
* @return string
*/
public function getTranslatedText()
{
return $this->translatedText;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Translation::class, 'Google_Service_Translate_Translation');

View File

@@ -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\Translate;
class TransliterationConfig extends \Google\Model
{
/**
* @var bool
*/
public $enableTransliteration;
/**
* @param bool
*/
public function setEnableTransliteration($enableTransliteration)
{
$this->enableTransliteration = $enableTransliteration;
}
/**
* @return bool
*/
public function getEnableTransliteration()
{
return $this->enableTransliteration;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(TransliterationConfig::class, 'Google_Service_Translate_TransliterationConfig');

View File

@@ -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\Translate;
class WaitOperationRequest extends \Google\Model
{
/**
* @var string
*/
public $timeout;
/**
* @param string
*/
public function setTimeout($timeout)
{
$this->timeout = $timeout;
}
/**
* @return string
*/
public function getTimeout()
{
return $this->timeout;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(WaitOperationRequest::class, 'Google_Service_Translate_WaitOperationRequest');