Viewing file: Dataset.php (12.44 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/cloud/translate/v3/automl_translation.proto
namespace Google\Cloud\Translate\V3;
use Google\Protobuf\Internal\GPBType; use Google\Protobuf\Internal\RepeatedField; use Google\Protobuf\Internal\GPBUtil;
/** * A dataset that hosts the examples (sentence pairs) used for translation * models. * * Generated from protobuf message <code>google.cloud.translation.v3.Dataset</code> */ class Dataset extends \Google\Protobuf\Internal\Message { /** * The resource name of the dataset, in form of * `projects/{project-number-or-id}/locations/{location_id}/datasets/{dataset_id}` * * Generated from protobuf field <code>string name = 1;</code> */ private $name = ''; /** * The name of the dataset to show in the interface. The name can be * up to 32 characters long and can consist only of ASCII Latin letters A-Z * and a-z, underscores (_), and ASCII digits 0-9. * * Generated from protobuf field <code>string display_name = 2;</code> */ private $display_name = ''; /** * The BCP-47 language code of the source language. * * Generated from protobuf field <code>string source_language_code = 3;</code> */ private $source_language_code = ''; /** * The BCP-47 language code of the target language. * * Generated from protobuf field <code>string target_language_code = 4;</code> */ private $target_language_code = ''; /** * Output only. The number of examples in the dataset. * * Generated from protobuf field <code>int32 example_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> */ private $example_count = 0; /** * Output only. Number of training examples (sentence pairs). * * Generated from protobuf field <code>int32 train_example_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> */ private $train_example_count = 0; /** * Output only. Number of validation examples (sentence pairs). * * Generated from protobuf field <code>int32 validate_example_count = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> */ private $validate_example_count = 0; /** * Output only. Number of test examples (sentence pairs). * * Generated from protobuf field <code>int32 test_example_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> */ private $test_example_count = 0; /** * Output only. Timestamp when this dataset was created. * * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> */ private $create_time = null; /** * Output only. Timestamp when this dataset was last updated. * * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> */ private $update_time = null;
/** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type string $name * The resource name of the dataset, in form of * `projects/{project-number-or-id}/locations/{location_id}/datasets/{dataset_id}` * @type string $display_name * The name of the dataset to show in the interface. The name can be * up to 32 characters long and can consist only of ASCII Latin letters A-Z * and a-z, underscores (_), and ASCII digits 0-9. * @type string $source_language_code * The BCP-47 language code of the source language. * @type string $target_language_code * The BCP-47 language code of the target language. * @type int $example_count * Output only. The number of examples in the dataset. * @type int $train_example_count * Output only. Number of training examples (sentence pairs). * @type int $validate_example_count * Output only. Number of validation examples (sentence pairs). * @type int $test_example_count * Output only. Number of test examples (sentence pairs). * @type \Google\Protobuf\Timestamp $create_time * Output only. Timestamp when this dataset was created. * @type \Google\Protobuf\Timestamp $update_time * Output only. Timestamp when this dataset was last updated. * } */ public function __construct($data = NULL) { \GPBMetadata\Google\Cloud\Translate\V3\AutomlTranslation::initOnce(); parent::__construct($data); }
/** * The resource name of the dataset, in form of * `projects/{project-number-or-id}/locations/{location_id}/datasets/{dataset_id}` * * Generated from protobuf field <code>string name = 1;</code> * @return string */ public function getName() { return $this->name; }
/** * The resource name of the dataset, in form of * `projects/{project-number-or-id}/locations/{location_id}/datasets/{dataset_id}` * * Generated from protobuf field <code>string name = 1;</code> * @param string $var * @return $this */ public function setName($var) { GPBUtil::checkString($var, True); $this->name = $var;
return $this; }
/** * The name of the dataset to show in the interface. The name can be * up to 32 characters long and can consist only of ASCII Latin letters A-Z * and a-z, underscores (_), and ASCII digits 0-9. * * Generated from protobuf field <code>string display_name = 2;</code> * @return string */ public function getDisplayName() { return $this->display_name; }
/** * The name of the dataset to show in the interface. The name can be * up to 32 characters long and can consist only of ASCII Latin letters A-Z * and a-z, underscores (_), and ASCII digits 0-9. * * Generated from protobuf field <code>string display_name = 2;</code> * @param string $var * @return $this */ public function setDisplayName($var) { GPBUtil::checkString($var, True); $this->display_name = $var;
return $this; }
/** * The BCP-47 language code of the source language. * * Generated from protobuf field <code>string source_language_code = 3;</code> * @return string */ public function getSourceLanguageCode() { return $this->source_language_code; }
/** * The BCP-47 language code of the source language. * * Generated from protobuf field <code>string source_language_code = 3;</code> * @param string $var * @return $this */ public function setSourceLanguageCode($var) { GPBUtil::checkString($var, True); $this->source_language_code = $var;
return $this; }
/** * The BCP-47 language code of the target language. * * Generated from protobuf field <code>string target_language_code = 4;</code> * @return string */ public function getTargetLanguageCode() { return $this->target_language_code; }
/** * The BCP-47 language code of the target language. * * Generated from protobuf field <code>string target_language_code = 4;</code> * @param string $var * @return $this */ public function setTargetLanguageCode($var) { GPBUtil::checkString($var, True); $this->target_language_code = $var;
return $this; }
/** * Output only. The number of examples in the dataset. * * Generated from protobuf field <code>int32 example_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @return int */ public function getExampleCount() { return $this->example_count; }
/** * Output only. The number of examples in the dataset. * * Generated from protobuf field <code>int32 example_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @param int $var * @return $this */ public function setExampleCount($var) { GPBUtil::checkInt32($var); $this->example_count = $var;
return $this; }
/** * Output only. Number of training examples (sentence pairs). * * Generated from protobuf field <code>int32 train_example_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @return int */ public function getTrainExampleCount() { return $this->train_example_count; }
/** * Output only. Number of training examples (sentence pairs). * * Generated from protobuf field <code>int32 train_example_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @param int $var * @return $this */ public function setTrainExampleCount($var) { GPBUtil::checkInt32($var); $this->train_example_count = $var;
return $this; }
/** * Output only. Number of validation examples (sentence pairs). * * Generated from protobuf field <code>int32 validate_example_count = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @return int */ public function getValidateExampleCount() { return $this->validate_example_count; }
/** * Output only. Number of validation examples (sentence pairs). * * Generated from protobuf field <code>int32 validate_example_count = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @param int $var * @return $this */ public function setValidateExampleCount($var) { GPBUtil::checkInt32($var); $this->validate_example_count = $var;
return $this; }
/** * Output only. Number of test examples (sentence pairs). * * Generated from protobuf field <code>int32 test_example_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @return int */ public function getTestExampleCount() { return $this->test_example_count; }
/** * Output only. Number of test examples (sentence pairs). * * Generated from protobuf field <code>int32 test_example_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @param int $var * @return $this */ public function setTestExampleCount($var) { GPBUtil::checkInt32($var); $this->test_example_count = $var;
return $this; }
/** * Output only. Timestamp when this dataset was created. * * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @return \Google\Protobuf\Timestamp|null */ public function getCreateTime() { return $this->create_time; }
public function hasCreateTime() { return isset($this->create_time); }
public function clearCreateTime() { unset($this->create_time); }
/** * Output only. Timestamp when this dataset was created. * * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @param \Google\Protobuf\Timestamp $var * @return $this */ public function setCreateTime($var) { GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); $this->create_time = $var;
return $this; }
/** * Output only. Timestamp when this dataset was last updated. * * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @return \Google\Protobuf\Timestamp|null */ public function getUpdateTime() { return $this->update_time; }
public function hasUpdateTime() { return isset($this->update_time); }
public function clearUpdateTime() { unset($this->update_time); }
/** * Output only. Timestamp when this dataset was last updated. * * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> * @param \Google\Protobuf\Timestamp $var * @return $this */ public function setUpdateTime($var) { GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); $this->update_time = $var;
return $this; }
}
|