diff options
author | Bo Yang <teboring@google.com> | 2016-09-19 13:45:07 -0700 |
---|---|---|
committer | Bo Yang <teboring@google.com> | 2016-09-19 17:42:40 -0700 |
commit | 98835fb8f8a8f144f2a1eac0b833ff83f4a05f54 (patch) | |
tree | 49504df5c2020eb085c1826548c10a3cbd188e12 /php/tests/test.pb.php | |
parent | b5bbdb0967109fbae7bfc423ef3cd6dc776359b6 (diff) | |
download | protobuf-98835fb8f8a8f144f2a1eac0b833ff83f4a05f54.tar.gz protobuf-98835fb8f8a8f144f2a1eac0b833ff83f4a05f54.tar.bz2 protobuf-98835fb8f8a8f144f2a1eac0b833ff83f4a05f54.zip |
Integrate internal changes
Diffstat (limited to 'php/tests/test.pb.php')
-rw-r--r-- | php/tests/test.pb.php | 1385 |
1 files changed, 1385 insertions, 0 deletions
diff --git a/php/tests/test.pb.php b/php/tests/test.pb.php new file mode 100644 index 00000000..ed316b6e --- /dev/null +++ b/php/tests/test.pb.php @@ -0,0 +1,1385 @@ +<?php +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: test.proto + +namespace Foo; + +require_once('test_include.pb.php'); +use Google\Protobuf\Internal\DescriptorPool; +use Google\Protobuf\Internal\GPBType; +use Google\Protobuf\Internal\RepeatedField; +use Google\Protobuf\Internal\GPBUtil; + +class TestMessage extends \Google\Protobuf\Internal\Message +{ + private $optional_int32 = 0; + private $optional_int64 = 0; + private $optional_uint32 = 0; + private $optional_uint64 = 0; + private $optional_sint32 = 0; + private $optional_sint64 = 0; + private $optional_fixed32 = 0; + private $optional_fixed64 = 0; + private $optional_sfixed32 = 0; + private $optional_sfixed64 = 0; + private $optional_float = 0.0; + private $optional_double = 0.0; + private $optional_bool = false; + private $optional_string = ''; + private $optional_bytes = ''; + private $optional_enum = 0; + private $optional_message = null; + private $optional_included_message = null; + private $recursive = null; + private $repeated_int32; + private $repeated_int64; + private $repeated_uint32; + private $repeated_uint64; + private $repeated_sint32; + private $repeated_sint64; + private $repeated_fixed32; + private $repeated_fixed64; + private $repeated_sfixed32; + private $repeated_sfixed64; + private $repeated_float; + private $repeated_double; + private $repeated_bool; + private $repeated_string; + private $repeated_bytes; + private $repeated_enum; + private $repeated_message; + private $repeated_recursive; + private $map_int32_int32; + private $map_int64_int64; + private $map_uint32_uint32; + private $map_uint64_uint64; + private $map_sint32_sint32; + private $map_sint64_sint64; + private $map_fixed32_fixed32; + private $map_fixed64_fixed64; + private $map_sfixed32_sfixed32; + private $map_sfixed64_sfixed64; + private $map_int32_float; + private $map_int32_double; + private $map_bool_bool; + private $map_string_string; + private $map_int32_bytes; + private $map_int32_enum; + private $map_int32_message; + private $map_recursive; + protected $my_oneof; + + public function getOptionalInt32() + { + return $this->optional_int32; + } + + public function setOptionalInt32($var) + { + GPBUtil::checkInt32($var); + $this->optional_int32 = $var; + } + + public function getOptionalInt64() + { + return $this->optional_int64; + } + + public function setOptionalInt64($var) + { + GPBUtil::checkInt64($var); + $this->optional_int64 = $var; + } + + public function getOptionalUint32() + { + return $this->optional_uint32; + } + + public function setOptionalUint32($var) + { + GPBUtil::checkUint32($var); + $this->optional_uint32 = $var; + } + + public function getOptionalUint64() + { + return $this->optional_uint64; + } + + public function setOptionalUint64($var) + { + GPBUtil::checkUint64($var); + $this->optional_uint64 = $var; + } + + public function getOptionalSint32() + { + return $this->optional_sint32; + } + + public function setOptionalSint32($var) + { + GPBUtil::checkInt32($var); + $this->optional_sint32 = $var; + } + + public function getOptionalSint64() + { + return $this->optional_sint64; + } + + public function setOptionalSint64($var) + { + GPBUtil::checkInt64($var); + $this->optional_sint64 = $var; + } + + public function getOptionalFixed32() + { + return $this->optional_fixed32; + } + + public function setOptionalFixed32($var) + { + GPBUtil::checkUint32($var); + $this->optional_fixed32 = $var; + } + + public function getOptionalFixed64() + { + return $this->optional_fixed64; + } + + public function setOptionalFixed64($var) + { + GPBUtil::checkUint64($var); + $this->optional_fixed64 = $var; + } + + public function getOptionalSfixed32() + { + return $this->optional_sfixed32; + } + + public function setOptionalSfixed32($var) + { + GPBUtil::checkInt32($var); + $this->optional_sfixed32 = $var; + } + + public function getOptionalSfixed64() + { + return $this->optional_sfixed64; + } + + public function setOptionalSfixed64($var) + { + GPBUtil::checkInt64($var); + $this->optional_sfixed64 = $var; + } + + public function getOptionalFloat() + { + return $this->optional_float; + } + + public function setOptionalFloat($var) + { + GPBUtil::checkFloat($var); + $this->optional_float = $var; + } + + public function getOptionalDouble() + { + return $this->optional_double; + } + + public function setOptionalDouble($var) + { + GPBUtil::checkDouble($var); + $this->optional_double = $var; + } + + public function getOptionalBool() + { + return $this->optional_bool; + } + + public function setOptionalBool($var) + { + GPBUtil::checkBool($var); + $this->optional_bool = $var; + } + + public function getOptionalString() + { + return $this->optional_string; + } + + public function setOptionalString($var) + { + GPBUtil::checkString($var, True); + $this->optional_string = $var; + } + + public function getOptionalBytes() + { + return $this->optional_bytes; + } + + public function setOptionalBytes($var) + { + GPBUtil::checkString($var, False); + $this->optional_bytes = $var; + } + + public function getOptionalEnum() + { + return $this->optional_enum; + } + + public function setOptionalEnum($var) + { + GPBUtil::checkEnum($var, \Foo\TestEnum::class); + $this->optional_enum = $var; + } + + public function getOptionalMessage() + { + return $this->optional_message; + } + + public function setOptionalMessage(&$var) + { + GPBUtil::checkMessage($var, \Foo\TestMessage_Sub::class); + $this->optional_message = $var; + } + + public function getOptionalIncludedMessage() + { + return $this->optional_included_message; + } + + public function setOptionalIncludedMessage(&$var) + { + GPBUtil::checkMessage($var, \Bar\TestInclude::class); + $this->optional_included_message = $var; + } + + public function getRecursive() + { + return $this->recursive; + } + + public function setRecursive(&$var) + { + GPBUtil::checkMessage($var, \Foo\TestMessage::class); + $this->recursive = $var; + } + + public function getRepeatedInt32() + { + return $this->repeated_int32; + } + + public function setRepeatedInt32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::INT32); + $this->repeated_int32 = $var; + } + + public function getRepeatedInt64() + { + return $this->repeated_int64; + } + + public function setRepeatedInt64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::INT64); + $this->repeated_int64 = $var; + } + + public function getRepeatedUint32() + { + return $this->repeated_uint32; + } + + public function setRepeatedUint32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::UINT32); + $this->repeated_uint32 = $var; + } + + public function getRepeatedUint64() + { + return $this->repeated_uint64; + } + + public function setRepeatedUint64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::UINT64); + $this->repeated_uint64 = $var; + } + + public function getRepeatedSint32() + { + return $this->repeated_sint32; + } + + public function setRepeatedSint32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SINT32); + $this->repeated_sint32 = $var; + } + + public function getRepeatedSint64() + { + return $this->repeated_sint64; + } + + public function setRepeatedSint64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SINT64); + $this->repeated_sint64 = $var; + } + + public function getRepeatedFixed32() + { + return $this->repeated_fixed32; + } + + public function setRepeatedFixed32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::FIXED32); + $this->repeated_fixed32 = $var; + } + + public function getRepeatedFixed64() + { + return $this->repeated_fixed64; + } + + public function setRepeatedFixed64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::FIXED64); + $this->repeated_fixed64 = $var; + } + + public function getRepeatedSfixed32() + { + return $this->repeated_sfixed32; + } + + public function setRepeatedSfixed32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SFIXED32); + $this->repeated_sfixed32 = $var; + } + + public function getRepeatedSfixed64() + { + return $this->repeated_sfixed64; + } + + public function setRepeatedSfixed64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SFIXED64); + $this->repeated_sfixed64 = $var; + } + + public function getRepeatedFloat() + { + return $this->repeated_float; + } + + public function setRepeatedFloat(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::FLOAT); + $this->repeated_float = $var; + } + + public function getRepeatedDouble() + { + return $this->repeated_double; + } + + public function setRepeatedDouble(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::DOUBLE); + $this->repeated_double = $var; + } + + public function getRepeatedBool() + { + return $this->repeated_bool; + } + + public function setRepeatedBool(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::BOOL); + $this->repeated_bool = $var; + } + + public function getRepeatedString() + { + return $this->repeated_string; + } + + public function setRepeatedString(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::STRING); + $this->repeated_string = $var; + } + + public function getRepeatedBytes() + { + return $this->repeated_bytes; + } + + public function setRepeatedBytes(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::BYTES); + $this->repeated_bytes = $var; + } + + public function getRepeatedEnum() + { + return $this->repeated_enum; + } + + public function setRepeatedEnum(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::ENUM, Foo\TestEnum::class); + $this->repeated_enum = $var; + } + + public function getRepeatedMessage() + { + return $this->repeated_message; + } + + public function setRepeatedMessage(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::MESSAGE, \Foo\TestMessage_Sub::class); + $this->repeated_message = $var; + } + + public function getRepeatedRecursive() + { + return $this->repeated_recursive; + } + + public function setRepeatedRecursive(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::MESSAGE, \Foo\TestMessage::class); + $this->repeated_recursive = $var; + } + + public function getOneofInt32() + { + return $this->readOneof(51); + } + + public function setOneofInt32($var) + { + GPBUtil::checkInt32($var); + $this->writeOneof(51, $var); + } + + public function getOneofInt64() + { + return $this->readOneof(52); + } + + public function setOneofInt64($var) + { + GPBUtil::checkInt64($var); + $this->writeOneof(52, $var); + } + + public function getOneofUint32() + { + return $this->readOneof(53); + } + + public function setOneofUint32($var) + { + GPBUtil::checkUint32($var); + $this->writeOneof(53, $var); + } + + public function getOneofUint64() + { + return $this->readOneof(54); + } + + public function setOneofUint64($var) + { + GPBUtil::checkUint64($var); + $this->writeOneof(54, $var); + } + + public function getOneofSint32() + { + return $this->readOneof(55); + } + + public function setOneofSint32($var) + { + GPBUtil::checkUint32($var); + $this->writeOneof(55, $var); + } + + public function getOneofSint64() + { + return $this->readOneof(56); + } + + public function setOneofSint64($var) + { + GPBUtil::checkUint64($var); + $this->writeOneof(56, $var); + } + + public function getOneofFixed32() + { + return $this->readOneof(57); + } + + public function setOneofFixed32($var) + { + GPBUtil::checkUint32($var); + $this->writeOneof(57, $var); + } + + public function getOneofFixed64() + { + return $this->readOneof(58); + } + + public function setOneofFixed64($var) + { + GPBUtil::checkUint64($var); + $this->writeOneof(58, $var); + } + + public function getOneofSfixed32() + { + return $this->readOneof(59); + } + + public function setOneofSfixed32($var) + { + GPBUtil::checkUint32($var); + $this->writeOneof(59, $var); + } + + public function getOneofSfixed64() + { + return $this->readOneof(60); + } + + public function setOneofSfixed64($var) + { + GPBUtil::checkUint64($var); + $this->writeOneof(60, $var); + } + + public function getOneofDouble() + { + return $this->readOneof(61); + } + + public function setOneofDouble($var) + { + GPBUtil::checkDouble($var); + $this->writeOneof(61, $var); + } + + public function getOneofFloat() + { + return $this->readOneof(62); + } + + public function setOneofFloat($var) + { + GPBUtil::checkFloat($var); + $this->writeOneof(62, $var); + } + + public function getOneofBool() + { + return $this->readOneof(63); + } + + public function setOneofBool($var) + { + GPBUtil::checkBool($var); + $this->writeOneof(63, $var); + } + + public function getOneofString() + { + return $this->readOneof(64); + } + + public function setOneofString($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(64, $var); + } + + public function getOneofBytes() + { + return $this->readOneof(65); + } + + public function setOneofBytes($var) + { + GPBUtil::checkString($var, False); + $this->writeOneof(65, $var); + } + + public function getOneofEnum() + { + return $this->readOneof(66); + } + + public function setOneofEnum($var) + { + GPBUtil::checkEnum($var, \Foo\TestEnum::class); + $this->writeOneof(66, $var); + } + + public function getOneofMessage() + { + return $this->readOneof(67); + } + + public function setOneofMessage(&$var) + { + GPBUtil::checkMessage($var, \Foo\TestMessage_Sub::class); + $this->writeOneof(67, $var); + } + + public function getMapInt32Int32() + { + return $this->map_int32_int32; + } + + public function setMapInt32Int32(&$var) + { + $this->map_int32_int32 = $var; + } + + public function getMapInt64Int64() + { + return $this->map_int64_int64; + } + + public function setMapInt64Int64(&$var) + { + $this->map_int64_int64 = $var; + } + + public function getMapUint32Uint32() + { + return $this->map_uint32_uint32; + } + + public function setMapUint32Uint32(&$var) + { + $this->map_uint32_uint32 = $var; + } + + public function getMapUint64Uint64() + { + return $this->map_uint64_uint64; + } + + public function setMapUint64Uint64(&$var) + { + $this->map_uint64_uint64 = $var; + } + + public function getMapSint32Sint32() + { + return $this->map_sint32_sint32; + } + + public function setMapSint32Sint32(&$var) + { + $this->map_sint32_sint32 = $var; + } + + public function getMapSint64Sint64() + { + return $this->map_sint64_sint64; + } + + public function setMapSint64Sint64(&$var) + { + $this->map_sint64_sint64 = $var; + } + + public function getMapFixed32Fixed32() + { + return $this->map_fixed32_fixed32; + } + + public function setMapFixed32Fixed32(&$var) + { + $this->map_fixed32_fixed32 = $var; + } + + public function getMapFixed64Fixed64() + { + return $this->map_fixed64_fixed64; + } + + public function setMapFixed64Fixed64(&$var) + { + $this->map_fixed64_fixed64 = $var; + } + + public function getMapSfixed32Sfixed32() + { + return $this->map_sfixed32_sfixed32; + } + + public function setMapSfixed32Sfixed32(&$var) + { + $this->map_sfixed32_sfixed32 = $var; + } + + public function getMapSfixed64Sfixed64() + { + return $this->map_sfixed64_sfixed64; + } + + public function setMapSfixed64Sfixed64(&$var) + { + $this->map_sfixed64_sfixed64 = $var; + } + + public function getMapInt32Float() + { + return $this->map_int32_float; + } + + public function setMapInt32Float(&$var) + { + $this->map_int32_float = $var; + } + + public function getMapInt32Double() + { + return $this->map_int32_double; + } + + public function setMapInt32Double(&$var) + { + $this->map_int32_double = $var; + } + + public function getMapBoolBool() + { + return $this->map_bool_bool; + } + + public function setMapBoolBool(&$var) + { + $this->map_bool_bool = $var; + } + + public function getMapStringString() + { + return $this->map_string_string; + } + + public function setMapStringString(&$var) + { + $this->map_string_string = $var; + } + + public function getMapInt32Bytes() + { + return $this->map_int32_bytes; + } + + public function setMapInt32Bytes(&$var) + { + $this->map_int32_bytes = $var; + } + + public function getMapInt32Enum() + { + return $this->map_int32_enum; + } + + public function setMapInt32Enum(&$var) + { + $this->map_int32_enum = $var; + } + + public function getMapInt32Message() + { + return $this->map_int32_message; + } + + public function setMapInt32Message(&$var) + { + $this->map_int32_message = $var; + } + + public function getMapRecursive() + { + return $this->map_recursive; + } + + public function setMapRecursive(&$var) + { + $this->map_recursive = $var; + } + + public function getMyOneof() + { + return $this->my_oneof; + } + +} + +class TestMessage_Sub extends \Google\Protobuf\Internal\Message +{ + private $a = 0; + + public function getA() + { + return $this->a; + } + + public function setA($var) + { + GPBUtil::checkInt32($var); + $this->a = $var; + } + +} + +class TestPackedMessage extends \Google\Protobuf\Internal\Message +{ + private $repeated_int32; + private $repeated_int64; + private $repeated_uint32; + private $repeated_uint64; + private $repeated_sint32; + private $repeated_sint64; + private $repeated_fixed32; + private $repeated_fixed64; + private $repeated_sfixed32; + private $repeated_sfixed64; + private $repeated_float; + private $repeated_double; + private $repeated_bool; + private $repeated_enum; + + public function getRepeatedInt32() + { + return $this->repeated_int32; + } + + public function setRepeatedInt32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::INT32); + $this->repeated_int32 = $var; + } + + public function getRepeatedInt64() + { + return $this->repeated_int64; + } + + public function setRepeatedInt64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::INT64); + $this->repeated_int64 = $var; + } + + public function getRepeatedUint32() + { + return $this->repeated_uint32; + } + + public function setRepeatedUint32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::UINT32); + $this->repeated_uint32 = $var; + } + + public function getRepeatedUint64() + { + return $this->repeated_uint64; + } + + public function setRepeatedUint64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::UINT64); + $this->repeated_uint64 = $var; + } + + public function getRepeatedSint32() + { + return $this->repeated_sint32; + } + + public function setRepeatedSint32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SINT32); + $this->repeated_sint32 = $var; + } + + public function getRepeatedSint64() + { + return $this->repeated_sint64; + } + + public function setRepeatedSint64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SINT64); + $this->repeated_sint64 = $var; + } + + public function getRepeatedFixed32() + { + return $this->repeated_fixed32; + } + + public function setRepeatedFixed32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::FIXED32); + $this->repeated_fixed32 = $var; + } + + public function getRepeatedFixed64() + { + return $this->repeated_fixed64; + } + + public function setRepeatedFixed64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::FIXED64); + $this->repeated_fixed64 = $var; + } + + public function getRepeatedSfixed32() + { + return $this->repeated_sfixed32; + } + + public function setRepeatedSfixed32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SFIXED32); + $this->repeated_sfixed32 = $var; + } + + public function getRepeatedSfixed64() + { + return $this->repeated_sfixed64; + } + + public function setRepeatedSfixed64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SFIXED64); + $this->repeated_sfixed64 = $var; + } + + public function getRepeatedFloat() + { + return $this->repeated_float; + } + + public function setRepeatedFloat(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::FLOAT); + $this->repeated_float = $var; + } + + public function getRepeatedDouble() + { + return $this->repeated_double; + } + + public function setRepeatedDouble(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::DOUBLE); + $this->repeated_double = $var; + } + + public function getRepeatedBool() + { + return $this->repeated_bool; + } + + public function setRepeatedBool(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::BOOL); + $this->repeated_bool = $var; + } + + public function getRepeatedEnum() + { + return $this->repeated_enum; + } + + public function setRepeatedEnum(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::ENUM, Foo\TestEnum::class); + $this->repeated_enum = $var; + } + +} + +class TestUnpackedMessage extends \Google\Protobuf\Internal\Message +{ + private $repeated_int32; + private $repeated_int64; + private $repeated_uint32; + private $repeated_uint64; + private $repeated_sint32; + private $repeated_sint64; + private $repeated_fixed32; + private $repeated_fixed64; + private $repeated_sfixed32; + private $repeated_sfixed64; + private $repeated_float; + private $repeated_double; + private $repeated_bool; + private $repeated_enum; + + public function getRepeatedInt32() + { + return $this->repeated_int32; + } + + public function setRepeatedInt32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::INT32); + $this->repeated_int32 = $var; + } + + public function getRepeatedInt64() + { + return $this->repeated_int64; + } + + public function setRepeatedInt64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::INT64); + $this->repeated_int64 = $var; + } + + public function getRepeatedUint32() + { + return $this->repeated_uint32; + } + + public function setRepeatedUint32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::UINT32); + $this->repeated_uint32 = $var; + } + + public function getRepeatedUint64() + { + return $this->repeated_uint64; + } + + public function setRepeatedUint64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::UINT64); + $this->repeated_uint64 = $var; + } + + public function getRepeatedSint32() + { + return $this->repeated_sint32; + } + + public function setRepeatedSint32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SINT32); + $this->repeated_sint32 = $var; + } + + public function getRepeatedSint64() + { + return $this->repeated_sint64; + } + + public function setRepeatedSint64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SINT64); + $this->repeated_sint64 = $var; + } + + public function getRepeatedFixed32() + { + return $this->repeated_fixed32; + } + + public function setRepeatedFixed32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::FIXED32); + $this->repeated_fixed32 = $var; + } + + public function getRepeatedFixed64() + { + return $this->repeated_fixed64; + } + + public function setRepeatedFixed64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::FIXED64); + $this->repeated_fixed64 = $var; + } + + public function getRepeatedSfixed32() + { + return $this->repeated_sfixed32; + } + + public function setRepeatedSfixed32(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SFIXED32); + $this->repeated_sfixed32 = $var; + } + + public function getRepeatedSfixed64() + { + return $this->repeated_sfixed64; + } + + public function setRepeatedSfixed64(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::SFIXED64); + $this->repeated_sfixed64 = $var; + } + + public function getRepeatedFloat() + { + return $this->repeated_float; + } + + public function setRepeatedFloat(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::FLOAT); + $this->repeated_float = $var; + } + + public function getRepeatedDouble() + { + return $this->repeated_double; + } + + public function setRepeatedDouble(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::DOUBLE); + $this->repeated_double = $var; + } + + public function getRepeatedBool() + { + return $this->repeated_bool; + } + + public function setRepeatedBool(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::BOOL); + $this->repeated_bool = $var; + } + + public function getRepeatedEnum() + { + return $this->repeated_enum; + } + + public function setRepeatedEnum(&$var) + { + GPBUtil::checkRepeatedField($var, GPBType::ENUM, Foo\TestEnum::class); + $this->repeated_enum = $var; + } + +} + +class TestEnum +{ + const ZERO = 0; + const ONE = 1; +} + +$pool = DescriptorPool::getGeneratedPool(); + +$pool->internalAddGeneratedFile(hex2bin( + "0a83250a0a746573742e70726f746f1203666f6f1a12746573745f696e63" . + "6c7564652e70726f746f22be1d0a0b546573744d65737361676512160a0e" . + "6f7074696f6e616c5f696e74333218012001280512160a0e6f7074696f6e" . + "616c5f696e74363418022001280312170a0f6f7074696f6e616c5f75696e" . + "74333218032001280d12170a0f6f7074696f6e616c5f75696e7436341804" . + "2001280412170a0f6f7074696f6e616c5f73696e74333218052001281112" . + "170a0f6f7074696f6e616c5f73696e74363418062001281212180a106f70" . + "74696f6e616c5f6669786564333218072001280712180a106f7074696f6e" . + "616c5f6669786564363418082001280612190a116f7074696f6e616c5f73" . + "6669786564333218092001280f12190a116f7074696f6e616c5f73666978" . + "65643634180a2001281012160a0e6f7074696f6e616c5f666c6f6174180b" . + "2001280212170a0f6f7074696f6e616c5f646f75626c65180c2001280112" . + "150a0d6f7074696f6e616c5f626f6f6c180d2001280812170a0f6f707469" . + "6f6e616c5f737472696e67180e2001280912160a0e6f7074696f6e616c5f" . + "6279746573180f2001280c12240a0d6f7074696f6e616c5f656e756d1810" . + "2001280e320d2e666f6f2e54657374456e756d122e0a106f7074696f6e61" . + "6c5f6d65737361676518112001280b32142e666f6f2e546573744d657373" . + "6167652e53756212330a196f7074696f6e616c5f696e636c756465645f6d" . + "65737361676518122001280b32102e6261722e54657374496e636c756465" . + "12230a0972656375727369766518132001280b32102e666f6f2e54657374" . + "4d65737361676512160a0e72657065617465645f696e743332181f200328" . + "0512160a0e72657065617465645f696e74363418202003280312170a0f72" . + "657065617465645f75696e74333218212003280d12170a0f726570656174" . + "65645f75696e74363418222003280412170a0f72657065617465645f7369" . + "6e74333218232003281112170a0f72657065617465645f73696e74363418" . + "242003281212180a1072657065617465645f666978656433321825200328" . + "0712180a1072657065617465645f6669786564363418262003280612190a" . + "1172657065617465645f736669786564333218272003280f12190a117265" . + "7065617465645f736669786564363418282003281012160a0e7265706561" . + "7465645f666c6f617418292003280212170a0f72657065617465645f646f" . + "75626c65182a2003280112150a0d72657065617465645f626f6f6c182b20" . + "03280812170a0f72657065617465645f737472696e67182c200328091216" . + "0a0e72657065617465645f6279746573182d2003280c12240a0d72657065" . + "617465645f656e756d182e2003280e320d2e666f6f2e54657374456e756d" . + "122e0a1072657065617465645f6d657373616765182f2003280b32142e66" . + "6f6f2e546573744d6573736167652e537562122c0a127265706561746564" . + "5f72656375727369766518302003280b32102e666f6f2e546573744d6573" . + "7361676512150a0b6f6e656f665f696e743332183320012805480012150a" . + "0b6f6e656f665f696e743634183420012803480012160a0c6f6e656f665f" . + "75696e74333218352001280d480012160a0c6f6e656f665f75696e743634" . + "183620012804480012160a0c6f6e656f665f73696e74333218372001280d" . + "480012160a0c6f6e656f665f73696e743634183820012804480012170a0d" . + "6f6e656f665f6669786564333218392001280d480012170a0d6f6e656f66" . + "5f66697865643634183a20012804480012180a0e6f6e656f665f73666978" . + "65643332183b2001280d480012180a0e6f6e656f665f7366697865643634" . + "183c20012804480012160a0c6f6e656f665f646f75626c65183d20012801" . + "480012150a0b6f6e656f665f666c6f6174183e20012802480012140a0a6f" . + "6e656f665f626f6f6c183f20012808480012160a0c6f6e656f665f737472" . + "696e67184020012809480012150a0b6f6e656f665f627974657318412001" . + "280c480012230a0a6f6e656f665f656e756d18422001280e320d2e666f6f" . + "2e54657374456e756d4800122d0a0d6f6e656f665f6d6573736167651843" . + "2001280b32142e666f6f2e546573744d6573736167652e5375624800123c" . + "0a0f6d61705f696e7433325f696e74333218472003280b32232e666f6f2e" . + "546573744d6573736167652e4d6170496e743332496e743332456e747279" . + "123c0a0f6d61705f696e7436345f696e74363418482003280b32232e666f" . + "6f2e546573744d6573736167652e4d6170496e743634496e743634456e74" . + "727912400a116d61705f75696e7433325f75696e74333218492003280b32" . + "252e666f6f2e546573744d6573736167652e4d617055696e74333255696e" . + "743332456e74727912400a116d61705f75696e7436345f75696e74363418" . + "4a2003280b32252e666f6f2e546573744d6573736167652e4d617055696e" . + "74363455696e743634456e74727912400a116d61705f73696e7433325f73" . + "696e743332184b2003280b32252e666f6f2e546573744d6573736167652e" . + "4d617053696e74333253696e743332456e74727912400a116d61705f7369" . + "6e7436345f73696e743634184c2003280b32252e666f6f2e546573744d65" . + "73736167652e4d617053696e74363453696e743634456e74727912440a13" . + "6d61705f666978656433325f66697865643332184d2003280b32272e666f" . + "6f2e546573744d6573736167652e4d617046697865643332466978656433" . + "32456e74727912440a136d61705f666978656436345f6669786564363418" . + "4e2003280b32272e666f6f2e546573744d6573736167652e4d6170466978" . + "6564363446697865643634456e74727912480a156d61705f736669786564" . + "33325f7366697865643332184f2003280b32292e666f6f2e546573744d65" . + "73736167652e4d617053666978656433325366697865643332456e747279" . + "12480a156d61705f73666978656436345f73666978656436341850200328" . + "0b32292e666f6f2e546573744d6573736167652e4d617053666978656436" . + "345366697865643634456e747279123c0a0f6d61705f696e7433325f666c" . + "6f617418512003280b32232e666f6f2e546573744d6573736167652e4d61" . + "70496e743332466c6f6174456e747279123e0a106d61705f696e7433325f" . + "646f75626c6518522003280b32242e666f6f2e546573744d657373616765" . + "2e4d6170496e743332446f75626c65456e74727912380a0d6d61705f626f" . + "6f6c5f626f6f6c18532003280b32212e666f6f2e546573744d6573736167" . + "652e4d6170426f6f6c426f6f6c456e74727912400a116d61705f73747269" . + "6e675f737472696e6718542003280b32252e666f6f2e546573744d657373" . + "6167652e4d6170537472696e67537472696e67456e747279123c0a0f6d61" . + "705f696e7433325f627974657318552003280b32232e666f6f2e54657374" . + "4d6573736167652e4d6170496e7433324279746573456e747279123a0a0e" . + "6d61705f696e7433325f656e756d18562003280b32222e666f6f2e546573" . + "744d6573736167652e4d6170496e743332456e756d456e74727912400a11" . + "6d61705f696e7433325f6d65737361676518572003280b32252e666f6f2e" . + "546573744d6573736167652e4d6170496e7433324d657373616765456e74" . + "727912390a0d6d61705f72656375727369766518582003280b32222e666f" . + "6f2e546573744d6573736167652e4d6170526563757273697665456e7472" . + "791a340a124d6170496e743332496e743332456e747279120b0a036b6579" . + "180120012805120d0a0576616c75651802200128053a0238011a340a124d" . + "6170496e743634496e743634456e747279120b0a036b6579180120012803" . + "120d0a0576616c75651802200128033a0238011a360a144d617055696e74" . + "333255696e743332456e747279120b0a036b657918012001280d120d0a05" . + "76616c756518022001280d3a0238011a360a144d617055696e7436345569" . + "6e743634456e747279120b0a036b6579180120012804120d0a0576616c75" . + "651802200128043a0238011a360a144d617053696e74333253696e743332" . + "456e747279120b0a036b6579180120012811120d0a0576616c7565180220" . + "0128113a0238011a360a144d617053696e74363453696e743634456e7472" . + "79120b0a036b6579180120012812120d0a0576616c75651802200128123a" . + "0238011a380a164d61704669786564333246697865643332456e74727912" . + "0b0a036b6579180120012807120d0a0576616c75651802200128073a0238" . + "011a380a164d61704669786564363446697865643634456e747279120b0a" . + "036b6579180120012806120d0a0576616c75651802200128063a0238011a" . + "3a0a184d617053666978656433325366697865643332456e747279120b0a" . + "036b657918012001280f120d0a0576616c756518022001280f3a0238011a" . + "3a0a184d617053666978656436345366697865643634456e747279120b0a" . + "036b6579180120012810120d0a0576616c75651802200128103a0238011a" . + "340a124d6170496e743332466c6f6174456e747279120b0a036b65791801" . + "20012805120d0a0576616c75651802200128023a0238011a350a134d6170" . + "496e743332446f75626c65456e747279120b0a036b657918012001280512" . + "0d0a0576616c75651802200128013a0238011a320a104d6170426f6f6c42" . + "6f6f6c456e747279120b0a036b6579180120012808120d0a0576616c7565" . + "1802200128083a0238011a360a144d6170537472696e67537472696e6745" . + "6e747279120b0a036b6579180120012809120d0a0576616c756518022001" . + "28093a0238011a340a124d6170496e7433324279746573456e747279120b" . + "0a036b6579180120012805120d0a0576616c756518022001280c3a023801" . + "1a420a114d6170496e743332456e756d456e747279120b0a036b65791801" . + "20012805121c0a0576616c756518022001280e320d2e666f6f2e54657374" . + "456e756d3a0238011a4c0a144d6170496e7433324d657373616765456e74" . + "7279120b0a036b657918012001280512230a0576616c756518022001280b" . + "32142e666f6f2e546573744d6573736167652e5375623a0238011a450a11" . + "4d6170526563757273697665456e747279120b0a036b6579180120012805" . + "121f0a0576616c756518022001280b32102e666f6f2e546573744d657373" . + "6167653a0238011a100a0353756212090a0161180120012805420a0a086d" . + "795f6f6e656f6622b7030a11546573745061636b65644d65737361676512" . + "1a0a0e72657065617465645f696e743332185a2003280542021001121a0a" . + "0e72657065617465645f696e743634185b2003280342021001121b0a0f72" . + "657065617465645f75696e743332185c2003280d42021001121b0a0f7265" . + "7065617465645f75696e743634185d2003280442021001121b0a0f726570" . + "65617465645f73696e743332185e2003281142021001121b0a0f72657065" . + "617465645f73696e743634185f2003281242021001121c0a107265706561" . + "7465645f6669786564333218602003280742021001121c0a107265706561" . + "7465645f6669786564363418612003280642021001121d0a117265706561" . + "7465645f736669786564333218622003280f42021001121d0a1172657065" . + "617465645f736669786564363418632003281042021001121a0a0e726570" . + "65617465645f666c6f617418642003280242021001121b0a0f7265706561" . + "7465645f646f75626c651865200328014202100112190a0d726570656174" . + "65645f626f6f6c1866200328084202100112280a0d72657065617465645f" . + "656e756d18672003280e320d2e666f6f2e54657374456e756d4202100122" . + "b9030a1354657374556e7061636b65644d657373616765121a0a0e726570" . + "65617465645f696e743332185a2003280542021000121a0a0e7265706561" . + "7465645f696e743634185b2003280342021000121b0a0f72657065617465" . + "645f75696e743332185c2003280d42021000121b0a0f7265706561746564" . + "5f75696e743634185d2003280442021000121b0a0f72657065617465645f" . + "73696e743332185e2003281142021000121b0a0f72657065617465645f73" . + "696e743634185f2003281242021000121c0a1072657065617465645f6669" . + "786564333218602003280742021000121c0a1072657065617465645f6669" . + "786564363418612003280642021000121d0a1172657065617465645f7366" . + "69786564333218622003280f42021000121d0a1172657065617465645f73" . + "6669786564363418632003281042021000121a0a0e72657065617465645f" . + "666c6f617418642003280242021000121b0a0f72657065617465645f646f" . + "75626c651865200328014202100012190a0d72657065617465645f626f6f" . + "6c1866200328084202100012280a0d72657065617465645f656e756d1867" . + "2003280e320d2e666f6f2e54657374456e756d420210002a1d0a08546573" . + "74456e756d12080a045a45524f100012070a034f4e451001620670726f74" . + "6f33" +)); + |