Make php generated code conform to PSR-4. (#2435)
1. Generate single file for each message. 2. Lazily initiate metadata.pull/2467/head
parent
631f4618a7
commit
46ae90dc5e
63 changed files with 6509 additions and 5231 deletions
@ -0,0 +1,27 @@ |
||||
{ |
||||
"name": "google/protobuf", |
||||
"type": "library", |
||||
"description": "proto library for PHP", |
||||
"keywords": ["proto"], |
||||
"homepage": "https://developers.google.com/protocol-buffers/", |
||||
"license": "BSD-3-Clause", |
||||
"require": { |
||||
"php": ">=5.5.0" |
||||
}, |
||||
"require-dev": { |
||||
"phpunit/phpunit": ">=4.8.0" |
||||
}, |
||||
"autoload": { |
||||
"psr-4": { |
||||
"Foo\\": "tests/generated/Foo", |
||||
"Bar\\": "tests/generated/Bar", |
||||
"Google\\Protobuf\\": "tests/generated/Google/Protobuf", |
||||
"Google\\Protobuf\\Internal\\": "src/Google/Protobuf/Internal", |
||||
"GPBMetadata\\": "tests/generated/GPBMetadata", |
||||
"GPBMetadata\\Google\\Protobuf\\Internal\\": "src/GPBMetadata/Google/Protobuf/Internal" |
||||
}, |
||||
"files": [ |
||||
"src/Google/Protobuf/descriptor.php" |
||||
] |
||||
} |
||||
} |
@ -0,0 +1,14 @@ |
||||
<?xml version="1.0" encoding="UTF-8"?> |
||||
<phpunit bootstrap="./vendor/autoload.php" |
||||
colors="true"> |
||||
<testsuites> |
||||
<testsuite name="protobuf-tests"> |
||||
<file>tests/php_implementation_test.php</file> |
||||
<file>tests/array_test.php</file> |
||||
<file>tests/encode_decode_test.php</file> |
||||
<file>tests/generated_class_test.php</file> |
||||
<file>tests/map_field_test.php</file> |
||||
<file>tests/well_known_test.php</file> |
||||
</testsuite> |
||||
</testsuites> |
||||
</phpunit> |
@ -0,0 +1,260 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace GPBMetadata\Google\Protobuf\Internal; |
||||
|
||||
class Descriptor |
||||
{ |
||||
public static $is_initialized = false; |
||||
|
||||
public static function initOnce() { |
||||
$pool = \Google\Protobuf\Internal\DescriptorPool::getGeneratedPool(); |
||||
|
||||
if (static::$is_initialized == true) { |
||||
return; |
||||
} |
||||
$pool->addMessage('google.protobuf.internal.FileDescriptorSet', \Google\Protobuf\Internal\FileDescriptorSet::class) |
||||
->repeated('file', \Google\Protobuf\Internal\GPBType::MESSAGE, 1, 'google.protobuf.internal.FileDescriptorProto') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.FileDescriptorProto', \Google\Protobuf\Internal\FileDescriptorProto::class) |
||||
->optional('name', \Google\Protobuf\Internal\GPBType::STRING, 1) |
||||
->optional('package', \Google\Protobuf\Internal\GPBType::STRING, 2) |
||||
->repeated('dependency', \Google\Protobuf\Internal\GPBType::STRING, 3) |
||||
->repeated('public_dependency', \Google\Protobuf\Internal\GPBType::INT32, 10) |
||||
->repeated('weak_dependency', \Google\Protobuf\Internal\GPBType::INT32, 11) |
||||
->repeated('message_type', \Google\Protobuf\Internal\GPBType::MESSAGE, 4, 'google.protobuf.internal.DescriptorProto') |
||||
->repeated('enum_type', \Google\Protobuf\Internal\GPBType::MESSAGE, 5, 'google.protobuf.internal.EnumDescriptorProto') |
||||
->repeated('service', \Google\Protobuf\Internal\GPBType::MESSAGE, 6, 'google.protobuf.internal.ServiceDescriptorProto') |
||||
->repeated('extension', \Google\Protobuf\Internal\GPBType::MESSAGE, 7, 'google.protobuf.internal.FieldDescriptorProto') |
||||
->optional('options', \Google\Protobuf\Internal\GPBType::MESSAGE, 8, 'google.protobuf.internal.FileOptions') |
||||
->optional('source_code_info', \Google\Protobuf\Internal\GPBType::MESSAGE, 9, 'google.protobuf.internal.SourceCodeInfo') |
||||
->optional('syntax', \Google\Protobuf\Internal\GPBType::STRING, 12) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.DescriptorProto', \Google\Protobuf\Internal\DescriptorProto::class) |
||||
->optional('name', \Google\Protobuf\Internal\GPBType::STRING, 1) |
||||
->repeated('field', \Google\Protobuf\Internal\GPBType::MESSAGE, 2, 'google.protobuf.internal.FieldDescriptorProto') |
||||
->repeated('extension', \Google\Protobuf\Internal\GPBType::MESSAGE, 6, 'google.protobuf.internal.FieldDescriptorProto') |
||||
->repeated('nested_type', \Google\Protobuf\Internal\GPBType::MESSAGE, 3, 'google.protobuf.internal.DescriptorProto') |
||||
->repeated('enum_type', \Google\Protobuf\Internal\GPBType::MESSAGE, 4, 'google.protobuf.internal.EnumDescriptorProto') |
||||
->repeated('extension_range', \Google\Protobuf\Internal\GPBType::MESSAGE, 5, 'google.protobuf.internal.DescriptorProto.ExtensionRange') |
||||
->repeated('oneof_decl', \Google\Protobuf\Internal\GPBType::MESSAGE, 8, 'google.protobuf.internal.OneofDescriptorProto') |
||||
->optional('options', \Google\Protobuf\Internal\GPBType::MESSAGE, 7, 'google.protobuf.internal.MessageOptions') |
||||
->repeated('reserved_range', \Google\Protobuf\Internal\GPBType::MESSAGE, 9, 'google.protobuf.internal.DescriptorProto.ReservedRange') |
||||
->repeated('reserved_name', \Google\Protobuf\Internal\GPBType::STRING, 10) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.DescriptorProto.ExtensionRange', \Google\Protobuf\Internal\DescriptorProto_ExtensionRange::class) |
||||
->optional('start', \Google\Protobuf\Internal\GPBType::INT32, 1) |
||||
->optional('end', \Google\Protobuf\Internal\GPBType::INT32, 2) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.DescriptorProto.ReservedRange', \Google\Protobuf\Internal\DescriptorProto_ReservedRange::class) |
||||
->optional('start', \Google\Protobuf\Internal\GPBType::INT32, 1) |
||||
->optional('end', \Google\Protobuf\Internal\GPBType::INT32, 2) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.FieldDescriptorProto', \Google\Protobuf\Internal\FieldDescriptorProto::class) |
||||
->optional('name', \Google\Protobuf\Internal\GPBType::STRING, 1) |
||||
->optional('number', \Google\Protobuf\Internal\GPBType::INT32, 3) |
||||
->optional('label', \Google\Protobuf\Internal\GPBType::ENUM, 4, 'google.protobuf.internal.FieldDescriptorProto.Label') |
||||
->optional('type', \Google\Protobuf\Internal\GPBType::ENUM, 5, 'google.protobuf.internal.FieldDescriptorProto.Type') |
||||
->optional('type_name', \Google\Protobuf\Internal\GPBType::STRING, 6) |
||||
->optional('extendee', \Google\Protobuf\Internal\GPBType::STRING, 2) |
||||
->optional('default_value', \Google\Protobuf\Internal\GPBType::STRING, 7) |
||||
->optional('oneof_index', \Google\Protobuf\Internal\GPBType::INT32, 9) |
||||
->optional('json_name', \Google\Protobuf\Internal\GPBType::STRING, 10) |
||||
->optional('options', \Google\Protobuf\Internal\GPBType::MESSAGE, 8, 'google.protobuf.internal.FieldOptions') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addEnum('google.protobuf.internal.FieldDescriptorProto.Type', \Google\Protobuf\Internal\Type::class) |
||||
->value("TYPE_DOUBLE", 1) |
||||
->value("TYPE_FLOAT", 2) |
||||
->value("TYPE_INT64", 3) |
||||
->value("TYPE_UINT64", 4) |
||||
->value("TYPE_INT32", 5) |
||||
->value("TYPE_FIXED64", 6) |
||||
->value("TYPE_FIXED32", 7) |
||||
->value("TYPE_BOOL", 8) |
||||
->value("TYPE_STRING", 9) |
||||
->value("TYPE_GROUP", 10) |
||||
->value("TYPE_MESSAGE", 11) |
||||
->value("TYPE_BYTES", 12) |
||||
->value("TYPE_UINT32", 13) |
||||
->value("TYPE_ENUM", 14) |
||||
->value("TYPE_SFIXED32", 15) |
||||
->value("TYPE_SFIXED64", 16) |
||||
->value("TYPE_SINT32", 17) |
||||
->value("TYPE_SINT64", 18) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addEnum('google.protobuf.internal.FieldDescriptorProto.Label', \Google\Protobuf\Internal\Label::class) |
||||
->value("LABEL_OPTIONAL", 1) |
||||
->value("LABEL_REQUIRED", 2) |
||||
->value("LABEL_REPEATED", 3) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.OneofDescriptorProto', \Google\Protobuf\Internal\OneofDescriptorProto::class) |
||||
->optional('name', \Google\Protobuf\Internal\GPBType::STRING, 1) |
||||
->optional('options', \Google\Protobuf\Internal\GPBType::MESSAGE, 2, 'google.protobuf.internal.OneofOptions') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.EnumDescriptorProto', \Google\Protobuf\Internal\EnumDescriptorProto::class) |
||||
->optional('name', \Google\Protobuf\Internal\GPBType::STRING, 1) |
||||
->repeated('value', \Google\Protobuf\Internal\GPBType::MESSAGE, 2, 'google.protobuf.internal.EnumValueDescriptorProto') |
||||
->optional('options', \Google\Protobuf\Internal\GPBType::MESSAGE, 3, 'google.protobuf.internal.EnumOptions') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.EnumValueDescriptorProto', \Google\Protobuf\Internal\EnumValueDescriptorProto::class) |
||||
->optional('name', \Google\Protobuf\Internal\GPBType::STRING, 1) |
||||
->optional('number', \Google\Protobuf\Internal\GPBType::INT32, 2) |
||||
->optional('options', \Google\Protobuf\Internal\GPBType::MESSAGE, 3, 'google.protobuf.internal.EnumValueOptions') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.ServiceDescriptorProto', \Google\Protobuf\Internal\ServiceDescriptorProto::class) |
||||
->optional('name', \Google\Protobuf\Internal\GPBType::STRING, 1) |
||||
->repeated('method', \Google\Protobuf\Internal\GPBType::MESSAGE, 2, 'google.protobuf.internal.MethodDescriptorProto') |
||||
->optional('options', \Google\Protobuf\Internal\GPBType::MESSAGE, 3, 'google.protobuf.internal.ServiceOptions') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.MethodDescriptorProto', \Google\Protobuf\Internal\MethodDescriptorProto::class) |
||||
->optional('name', \Google\Protobuf\Internal\GPBType::STRING, 1) |
||||
->optional('input_type', \Google\Protobuf\Internal\GPBType::STRING, 2) |
||||
->optional('output_type', \Google\Protobuf\Internal\GPBType::STRING, 3) |
||||
->optional('options', \Google\Protobuf\Internal\GPBType::MESSAGE, 4, 'google.protobuf.internal.MethodOptions') |
||||
->optional('client_streaming', \Google\Protobuf\Internal\GPBType::BOOL, 5) |
||||
->optional('server_streaming', \Google\Protobuf\Internal\GPBType::BOOL, 6) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.FileOptions', \Google\Protobuf\Internal\FileOptions::class) |
||||
->optional('java_package', \Google\Protobuf\Internal\GPBType::STRING, 1) |
||||
->optional('java_outer_classname', \Google\Protobuf\Internal\GPBType::STRING, 8) |
||||
->optional('java_multiple_files', \Google\Protobuf\Internal\GPBType::BOOL, 10) |
||||
->optional('java_generate_equals_and_hash', \Google\Protobuf\Internal\GPBType::BOOL, 20) |
||||
->optional('java_string_check_utf8', \Google\Protobuf\Internal\GPBType::BOOL, 27) |
||||
->optional('optimize_for', \Google\Protobuf\Internal\GPBType::ENUM, 9, 'google.protobuf.internal.FileOptions.OptimizeMode') |
||||
->optional('go_package', \Google\Protobuf\Internal\GPBType::STRING, 11) |
||||
->optional('cc_generic_services', \Google\Protobuf\Internal\GPBType::BOOL, 16) |
||||
->optional('java_generic_services', \Google\Protobuf\Internal\GPBType::BOOL, 17) |
||||
->optional('py_generic_services', \Google\Protobuf\Internal\GPBType::BOOL, 18) |
||||
->optional('deprecated', \Google\Protobuf\Internal\GPBType::BOOL, 23) |
||||
->optional('cc_enable_arenas', \Google\Protobuf\Internal\GPBType::BOOL, 31) |
||||
->optional('objc_class_prefix', \Google\Protobuf\Internal\GPBType::STRING, 36) |
||||
->optional('csharp_namespace', \Google\Protobuf\Internal\GPBType::STRING, 37) |
||||
->optional('swift_prefix', \Google\Protobuf\Internal\GPBType::STRING, 39) |
||||
->repeated('uninterpreted_option', \Google\Protobuf\Internal\GPBType::MESSAGE, 999, 'google.protobuf.internal.UninterpretedOption') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addEnum('google.protobuf.internal.FileOptions.OptimizeMode', \Google\Protobuf\Internal\OptimizeMode::class) |
||||
->value("SPEED", 1) |
||||
->value("CODE_SIZE", 2) |
||||
->value("LITE_RUNTIME", 3) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.MessageOptions', \Google\Protobuf\Internal\MessageOptions::class) |
||||
->optional('message_set_wire_format', \Google\Protobuf\Internal\GPBType::BOOL, 1) |
||||
->optional('no_standard_descriptor_accessor', \Google\Protobuf\Internal\GPBType::BOOL, 2) |
||||
->optional('deprecated', \Google\Protobuf\Internal\GPBType::BOOL, 3) |
||||
->optional('map_entry', \Google\Protobuf\Internal\GPBType::BOOL, 7) |
||||
->repeated('uninterpreted_option', \Google\Protobuf\Internal\GPBType::MESSAGE, 999, 'google.protobuf.internal.UninterpretedOption') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.FieldOptions', \Google\Protobuf\Internal\FieldOptions::class) |
||||
->optional('ctype', \Google\Protobuf\Internal\GPBType::ENUM, 1, 'google.protobuf.internal.FieldOptions.CType') |
||||
->optional('packed', \Google\Protobuf\Internal\GPBType::BOOL, 2) |
||||
->optional('jstype', \Google\Protobuf\Internal\GPBType::ENUM, 6, 'google.protobuf.internal.FieldOptions.JSType') |
||||
->optional('lazy', \Google\Protobuf\Internal\GPBType::BOOL, 5) |
||||
->optional('deprecated', \Google\Protobuf\Internal\GPBType::BOOL, 3) |
||||
->optional('weak', \Google\Protobuf\Internal\GPBType::BOOL, 10) |
||||
->repeated('uninterpreted_option', \Google\Protobuf\Internal\GPBType::MESSAGE, 999, 'google.protobuf.internal.UninterpretedOption') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addEnum('google.protobuf.internal.FieldOptions.CType', \Google\Protobuf\Internal\CType::class) |
||||
->value("STRING", 0) |
||||
->value("CORD", 1) |
||||
->value("STRING_PIECE", 2) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addEnum('google.protobuf.internal.FieldOptions.JSType', \Google\Protobuf\Internal\JSType::class) |
||||
->value("JS_NORMAL", 0) |
||||
->value("JS_STRING", 1) |
||||
->value("JS_NUMBER", 2) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.OneofOptions', \Google\Protobuf\Internal\OneofOptions::class) |
||||
->repeated('uninterpreted_option', \Google\Protobuf\Internal\GPBType::MESSAGE, 999, 'google.protobuf.internal.UninterpretedOption') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.EnumOptions', \Google\Protobuf\Internal\EnumOptions::class) |
||||
->optional('allow_alias', \Google\Protobuf\Internal\GPBType::BOOL, 2) |
||||
->optional('deprecated', \Google\Protobuf\Internal\GPBType::BOOL, 3) |
||||
->repeated('uninterpreted_option', \Google\Protobuf\Internal\GPBType::MESSAGE, 999, 'google.protobuf.internal.UninterpretedOption') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.EnumValueOptions', \Google\Protobuf\Internal\EnumValueOptions::class) |
||||
->optional('deprecated', \Google\Protobuf\Internal\GPBType::BOOL, 1) |
||||
->repeated('uninterpreted_option', \Google\Protobuf\Internal\GPBType::MESSAGE, 999, 'google.protobuf.internal.UninterpretedOption') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.ServiceOptions', \Google\Protobuf\Internal\ServiceOptions::class) |
||||
->optional('deprecated', \Google\Protobuf\Internal\GPBType::BOOL, 33) |
||||
->repeated('uninterpreted_option', \Google\Protobuf\Internal\GPBType::MESSAGE, 999, 'google.protobuf.internal.UninterpretedOption') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.MethodOptions', \Google\Protobuf\Internal\MethodOptions::class) |
||||
->optional('deprecated', \Google\Protobuf\Internal\GPBType::BOOL, 33) |
||||
->optional('idempotency_level', \Google\Protobuf\Internal\GPBType::ENUM, 34, 'google.protobuf.internal.MethodOptions.IdempotencyLevel') |
||||
->repeated('uninterpreted_option', \Google\Protobuf\Internal\GPBType::MESSAGE, 999, 'google.protobuf.internal.UninterpretedOption') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addEnum('google.protobuf.internal.MethodOptions.IdempotencyLevel', \Google\Protobuf\Internal\IdempotencyLevel::class) |
||||
->value("IDEMPOTENCY_UNKNOWN", 0) |
||||
->value("NO_SIDE_EFFECTS", 1) |
||||
->value("IDEMPOTENT", 2) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.UninterpretedOption', \Google\Protobuf\Internal\UninterpretedOption::class) |
||||
->repeated('name', \Google\Protobuf\Internal\GPBType::MESSAGE, 2, 'google.protobuf.internal.UninterpretedOption.NamePart') |
||||
->optional('identifier_value', \Google\Protobuf\Internal\GPBType::STRING, 3) |
||||
->optional('positive_int_value', \Google\Protobuf\Internal\GPBType::UINT64, 4) |
||||
->optional('negative_int_value', \Google\Protobuf\Internal\GPBType::INT64, 5) |
||||
->optional('double_value', \Google\Protobuf\Internal\GPBType::DOUBLE, 6) |
||||
->optional('string_value', \Google\Protobuf\Internal\GPBType::BYTES, 7) |
||||
->optional('aggregate_value', \Google\Protobuf\Internal\GPBType::STRING, 8) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.UninterpretedOption.NamePart', \Google\Protobuf\Internal\UninterpretedOption_NamePart::class) |
||||
->required('name_part', \Google\Protobuf\Internal\GPBType::STRING, 1) |
||||
->required('is_extension', \Google\Protobuf\Internal\GPBType::BOOL, 2) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.SourceCodeInfo', \Google\Protobuf\Internal\SourceCodeInfo::class) |
||||
->repeated('location', \Google\Protobuf\Internal\GPBType::MESSAGE, 1, 'google.protobuf.internal.SourceCodeInfo.Location') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.SourceCodeInfo.Location', \Google\Protobuf\Internal\SourceCodeInfo_Location::class) |
||||
->repeated('path', \Google\Protobuf\Internal\GPBType::INT32, 1) |
||||
->repeated('span', \Google\Protobuf\Internal\GPBType::INT32, 2) |
||||
->optional('leading_comments', \Google\Protobuf\Internal\GPBType::STRING, 3) |
||||
->optional('trailing_comments', \Google\Protobuf\Internal\GPBType::STRING, 4) |
||||
->repeated('leading_detached_comments', \Google\Protobuf\Internal\GPBType::STRING, 6) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.GeneratedCodeInfo', \Google\Protobuf\Internal\GeneratedCodeInfo::class) |
||||
->repeated('annotation', \Google\Protobuf\Internal\GPBType::MESSAGE, 1, 'google.protobuf.internal.GeneratedCodeInfo.Annotation') |
||||
->finalizeToPool(); |
||||
|
||||
$pool->addMessage('google.protobuf.internal.GeneratedCodeInfo.Annotation', \Google\Protobuf\Internal\GeneratedCodeInfo_Annotation::class) |
||||
->repeated('path', \Google\Protobuf\Internal\GPBType::INT32, 1) |
||||
->optional('source_file', \Google\Protobuf\Internal\GPBType::STRING, 2) |
||||
->optional('begin', \Google\Protobuf\Internal\GPBType::INT32, 3) |
||||
->optional('end', \Google\Protobuf\Internal\GPBType::INT32, 4) |
||||
->finalizeToPool(); |
||||
|
||||
$pool->finish(); |
||||
static::$is_initialized = true; |
||||
} |
||||
} |
||||
|
@ -0,0 +1,325 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* Describes a message type. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.DescriptorProto</code> |
||||
*/ |
||||
class DescriptorProto extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
private $name = ''; |
||||
private $has_name = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.FieldDescriptorProto field = 2;</code> |
||||
*/ |
||||
private $field; |
||||
private $has_field = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.FieldDescriptorProto extension = 6;</code> |
||||
*/ |
||||
private $extension; |
||||
private $has_extension = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.DescriptorProto nested_type = 3;</code> |
||||
*/ |
||||
private $nested_type; |
||||
private $has_nested_type = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.EnumDescriptorProto enum_type = 4;</code> |
||||
*/ |
||||
private $enum_type; |
||||
private $has_enum_type = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;</code> |
||||
*/ |
||||
private $extension_range; |
||||
private $has_extension_range = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;</code> |
||||
*/ |
||||
private $oneof_decl; |
||||
private $has_oneof_decl = false; |
||||
/** |
||||
* <code>optional .google.protobuf.MessageOptions options = 7;</code> |
||||
*/ |
||||
private $options = null; |
||||
private $has_options = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;</code> |
||||
*/ |
||||
private $reserved_range; |
||||
private $has_reserved_range = false; |
||||
/** |
||||
* <pre> |
||||
* Reserved field names, which may not be used by fields in the same message. |
||||
* A given name may only be reserved once. |
||||
* </pre> |
||||
* |
||||
* <code>repeated string reserved_name = 10;</code> |
||||
*/ |
||||
private $reserved_name; |
||||
private $has_reserved_name = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function getName() |
||||
{ |
||||
return $this->name; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function setName($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->name = $var; |
||||
$this->has_name = true; |
||||
} |
||||
|
||||
public function hasName() |
||||
{ |
||||
return $this->has_name; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.FieldDescriptorProto field = 2;</code> |
||||
*/ |
||||
public function getField() |
||||
{ |
||||
return $this->field; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.FieldDescriptorProto field = 2;</code> |
||||
*/ |
||||
public function setField(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\FieldDescriptorProto::class); |
||||
$this->field = $var; |
||||
$this->has_field = true; |
||||
} |
||||
|
||||
public function hasField() |
||||
{ |
||||
return $this->has_field; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.FieldDescriptorProto extension = 6;</code> |
||||
*/ |
||||
public function getExtension() |
||||
{ |
||||
return $this->extension; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.FieldDescriptorProto extension = 6;</code> |
||||
*/ |
||||
public function setExtension(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\FieldDescriptorProto::class); |
||||
$this->extension = $var; |
||||
$this->has_extension = true; |
||||
} |
||||
|
||||
public function hasExtension() |
||||
{ |
||||
return $this->has_extension; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.DescriptorProto nested_type = 3;</code> |
||||
*/ |
||||
public function getNestedType() |
||||
{ |
||||
return $this->nested_type; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.DescriptorProto nested_type = 3;</code> |
||||
*/ |
||||
public function setNestedType(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\DescriptorProto::class); |
||||
$this->nested_type = $var; |
||||
$this->has_nested_type = true; |
||||
} |
||||
|
||||
public function hasNestedType() |
||||
{ |
||||
return $this->has_nested_type; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.EnumDescriptorProto enum_type = 4;</code> |
||||
*/ |
||||
public function getEnumType() |
||||
{ |
||||
return $this->enum_type; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.EnumDescriptorProto enum_type = 4;</code> |
||||
*/ |
||||
public function setEnumType(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\EnumDescriptorProto::class); |
||||
$this->enum_type = $var; |
||||
$this->has_enum_type = true; |
||||
} |
||||
|
||||
public function hasEnumType() |
||||
{ |
||||
return $this->has_enum_type; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;</code> |
||||
*/ |
||||
public function getExtensionRange() |
||||
{ |
||||
return $this->extension_range; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;</code> |
||||
*/ |
||||
public function setExtensionRange(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\DescriptorProto_ExtensionRange::class); |
||||
$this->extension_range = $var; |
||||
$this->has_extension_range = true; |
||||
} |
||||
|
||||
public function hasExtensionRange() |
||||
{ |
||||
return $this->has_extension_range; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;</code> |
||||
*/ |
||||
public function getOneofDecl() |
||||
{ |
||||
return $this->oneof_decl; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;</code> |
||||
*/ |
||||
public function setOneofDecl(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\OneofDescriptorProto::class); |
||||
$this->oneof_decl = $var; |
||||
$this->has_oneof_decl = true; |
||||
} |
||||
|
||||
public function hasOneofDecl() |
||||
{ |
||||
return $this->has_oneof_decl; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.MessageOptions options = 7;</code> |
||||
*/ |
||||
public function getOptions() |
||||
{ |
||||
return $this->options; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.MessageOptions options = 7;</code> |
||||
*/ |
||||
public function setOptions(&$var) |
||||
{ |
||||
GPBUtil::checkMessage($var, \Google\Protobuf\Internal\MessageOptions::class); |
||||
$this->options = $var; |
||||
$this->has_options = true; |
||||
} |
||||
|
||||
public function hasOptions() |
||||
{ |
||||
return $this->has_options; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;</code> |
||||
*/ |
||||
public function getReservedRange() |
||||
{ |
||||
return $this->reserved_range; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;</code> |
||||
*/ |
||||
public function setReservedRange(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\DescriptorProto_ReservedRange::class); |
||||
$this->reserved_range = $var; |
||||
$this->has_reserved_range = true; |
||||
} |
||||
|
||||
public function hasReservedRange() |
||||
{ |
||||
return $this->has_reserved_range; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Reserved field names, which may not be used by fields in the same message. |
||||
* A given name may only be reserved once. |
||||
* </pre> |
||||
* |
||||
* <code>repeated string reserved_name = 10;</code> |
||||
*/ |
||||
public function getReservedName() |
||||
{ |
||||
return $this->reserved_name; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Reserved field names, which may not be used by fields in the same message. |
||||
* A given name may only be reserved once. |
||||
* </pre> |
||||
* |
||||
* <code>repeated string reserved_name = 10;</code> |
||||
*/ |
||||
public function setReservedName(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); |
||||
$this->reserved_name = $var; |
||||
$this->has_reserved_name = true; |
||||
} |
||||
|
||||
public function hasReservedName() |
||||
{ |
||||
return $this->has_reserved_name; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,82 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>google.protobuf.DescriptorProto.ExtensionRange</code> |
||||
*/ |
||||
class DescriptorProto_ExtensionRange extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>optional int32 start = 1;</code> |
||||
*/ |
||||
private $start = 0; |
||||
private $has_start = false; |
||||
/** |
||||
* <code>optional int32 end = 2;</code> |
||||
*/ |
||||
private $end = 0; |
||||
private $has_end = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <code>optional int32 start = 1;</code> |
||||
*/ |
||||
public function getStart() |
||||
{ |
||||
return $this->start; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional int32 start = 1;</code> |
||||
*/ |
||||
public function setStart($var) |
||||
{ |
||||
GPBUtil::checkInt32($var); |
||||
$this->start = $var; |
||||
$this->has_start = true; |
||||
} |
||||
|
||||
public function hasStart() |
||||
{ |
||||
return $this->has_start; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional int32 end = 2;</code> |
||||
*/ |
||||
public function getEnd() |
||||
{ |
||||
return $this->end; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional int32 end = 2;</code> |
||||
*/ |
||||
public function setEnd($var) |
||||
{ |
||||
GPBUtil::checkInt32($var); |
||||
$this->end = $var; |
||||
$this->has_end = true; |
||||
} |
||||
|
||||
public function hasEnd() |
||||
{ |
||||
return $this->has_end; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,112 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* Range of reserved tag numbers. Reserved tag numbers may not be used by |
||||
* fields or extension ranges in the same message. Reserved ranges may |
||||
* not overlap. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.DescriptorProto.ReservedRange</code> |
||||
*/ |
||||
class DescriptorProto_ReservedRange extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Inclusive. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 start = 1;</code> |
||||
*/ |
||||
private $start = 0; |
||||
private $has_start = false; |
||||
/** |
||||
* <pre> |
||||
* Exclusive. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 end = 2;</code> |
||||
*/ |
||||
private $end = 0; |
||||
private $has_end = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Inclusive. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 start = 1;</code> |
||||
*/ |
||||
public function getStart() |
||||
{ |
||||
return $this->start; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Inclusive. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 start = 1;</code> |
||||
*/ |
||||
public function setStart($var) |
||||
{ |
||||
GPBUtil::checkInt32($var); |
||||
$this->start = $var; |
||||
$this->has_start = true; |
||||
} |
||||
|
||||
public function hasStart() |
||||
{ |
||||
return $this->has_start; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Exclusive. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 end = 2;</code> |
||||
*/ |
||||
public function getEnd() |
||||
{ |
||||
return $this->end; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Exclusive. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 end = 2;</code> |
||||
*/ |
||||
public function setEnd($var) |
||||
{ |
||||
GPBUtil::checkInt32($var); |
||||
$this->end = $var; |
||||
$this->has_end = true; |
||||
} |
||||
|
||||
public function hasEnd() |
||||
{ |
||||
return $this->has_end; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,114 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* Describes an enum type. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.EnumDescriptorProto</code> |
||||
*/ |
||||
class EnumDescriptorProto extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
private $name = ''; |
||||
private $has_name = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.EnumValueDescriptorProto value = 2;</code> |
||||
*/ |
||||
private $value; |
||||
private $has_value = false; |
||||
/** |
||||
* <code>optional .google.protobuf.EnumOptions options = 3;</code> |
||||
*/ |
||||
private $options = null; |
||||
private $has_options = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function getName() |
||||
{ |
||||
return $this->name; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function setName($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->name = $var; |
||||
$this->has_name = true; |
||||
} |
||||
|
||||
public function hasName() |
||||
{ |
||||
return $this->has_name; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.EnumValueDescriptorProto value = 2;</code> |
||||
*/ |
||||
public function getValue() |
||||
{ |
||||
return $this->value; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.EnumValueDescriptorProto value = 2;</code> |
||||
*/ |
||||
public function setValue(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\EnumValueDescriptorProto::class); |
||||
$this->value = $var; |
||||
$this->has_value = true; |
||||
} |
||||
|
||||
public function hasValue() |
||||
{ |
||||
return $this->has_value; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.EnumOptions options = 3;</code> |
||||
*/ |
||||
public function getOptions() |
||||
{ |
||||
return $this->options; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.EnumOptions options = 3;</code> |
||||
*/ |
||||
public function setOptions(&$var) |
||||
{ |
||||
GPBUtil::checkMessage($var, \Google\Protobuf\Internal\EnumOptions::class); |
||||
$this->options = $var; |
||||
$this->has_options = true; |
||||
} |
||||
|
||||
public function hasOptions() |
||||
{ |
||||
return $this->has_options; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,158 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>google.protobuf.EnumOptions</code> |
||||
*/ |
||||
class EnumOptions extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Set this option to true to allow mapping different tag names to the same |
||||
* value. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool allow_alias = 2;</code> |
||||
*/ |
||||
private $allow_alias = false; |
||||
private $has_allow_alias = false; |
||||
/** |
||||
* <pre> |
||||
* Is this enum deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the enum, or it will be completely ignored; in the very least, this |
||||
* is a formalization for deprecating enums. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 3 [default = false];</code> |
||||
*/ |
||||
private $deprecated = false; |
||||
private $has_deprecated = false; |
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
private $uninterpreted_option; |
||||
private $has_uninterpreted_option = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Set this option to true to allow mapping different tag names to the same |
||||
* value. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool allow_alias = 2;</code> |
||||
*/ |
||||
public function getAllowAlias() |
||||
{ |
||||
return $this->allow_alias; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Set this option to true to allow mapping different tag names to the same |
||||
* value. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool allow_alias = 2;</code> |
||||
*/ |
||||
public function setAllowAlias($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->allow_alias = $var; |
||||
$this->has_allow_alias = true; |
||||
} |
||||
|
||||
public function hasAllowAlias() |
||||
{ |
||||
return $this->has_allow_alias; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this enum deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the enum, or it will be completely ignored; in the very least, this |
||||
* is a formalization for deprecating enums. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 3 [default = false];</code> |
||||
*/ |
||||
public function getDeprecated() |
||||
{ |
||||
return $this->deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this enum deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the enum, or it will be completely ignored; in the very least, this |
||||
* is a formalization for deprecating enums. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 3 [default = false];</code> |
||||
*/ |
||||
public function setDeprecated($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->deprecated = $var; |
||||
$this->has_deprecated = true; |
||||
} |
||||
|
||||
public function hasDeprecated() |
||||
{ |
||||
return $this->has_deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function getUninterpretedOption() |
||||
{ |
||||
return $this->uninterpreted_option; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function setUninterpretedOption(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption::class); |
||||
$this->uninterpreted_option = $var; |
||||
$this->has_uninterpreted_option = true; |
||||
} |
||||
|
||||
public function hasUninterpretedOption() |
||||
{ |
||||
return $this->has_uninterpreted_option; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,114 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* Describes a value within an enum. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.EnumValueDescriptorProto</code> |
||||
*/ |
||||
class EnumValueDescriptorProto extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
private $name = ''; |
||||
private $has_name = false; |
||||
/** |
||||
* <code>optional int32 number = 2;</code> |
||||
*/ |
||||
private $number = 0; |
||||
private $has_number = false; |
||||
/** |
||||
* <code>optional .google.protobuf.EnumValueOptions options = 3;</code> |
||||
*/ |
||||
private $options = null; |
||||
private $has_options = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function getName() |
||||
{ |
||||
return $this->name; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function setName($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->name = $var; |
||||
$this->has_name = true; |
||||
} |
||||
|
||||
public function hasName() |
||||
{ |
||||
return $this->has_name; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional int32 number = 2;</code> |
||||
*/ |
||||
public function getNumber() |
||||
{ |
||||
return $this->number; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional int32 number = 2;</code> |
||||
*/ |
||||
public function setNumber($var) |
||||
{ |
||||
GPBUtil::checkInt32($var); |
||||
$this->number = $var; |
||||
$this->has_number = true; |
||||
} |
||||
|
||||
public function hasNumber() |
||||
{ |
||||
return $this->has_number; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.EnumValueOptions options = 3;</code> |
||||
*/ |
||||
public function getOptions() |
||||
{ |
||||
return $this->options; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.EnumValueOptions options = 3;</code> |
||||
*/ |
||||
public function setOptions(&$var) |
||||
{ |
||||
GPBUtil::checkMessage($var, \Google\Protobuf\Internal\EnumValueOptions::class); |
||||
$this->options = $var; |
||||
$this->has_options = true; |
||||
} |
||||
|
||||
public function hasOptions() |
||||
{ |
||||
return $this->has_options; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,115 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>google.protobuf.EnumValueOptions</code> |
||||
*/ |
||||
class EnumValueOptions extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Is this enum value deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the enum value, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating enum values. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 1 [default = false];</code> |
||||
*/ |
||||
private $deprecated = false; |
||||
private $has_deprecated = false; |
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
private $uninterpreted_option; |
||||
private $has_uninterpreted_option = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this enum value deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the enum value, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating enum values. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 1 [default = false];</code> |
||||
*/ |
||||
public function getDeprecated() |
||||
{ |
||||
return $this->deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this enum value deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the enum value, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating enum values. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 1 [default = false];</code> |
||||
*/ |
||||
public function setDeprecated($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->deprecated = $var; |
||||
$this->has_deprecated = true; |
||||
} |
||||
|
||||
public function hasDeprecated() |
||||
{ |
||||
return $this->has_deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function getUninterpretedOption() |
||||
{ |
||||
return $this->uninterpreted_option; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function setUninterpretedOption(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption::class); |
||||
$this->uninterpreted_option = $var; |
||||
$this->has_uninterpreted_option = true; |
||||
} |
||||
|
||||
public function hasUninterpretedOption() |
||||
{ |
||||
return $this->has_uninterpreted_option; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,424 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* Describes a field within a message. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.FieldDescriptorProto</code> |
||||
*/ |
||||
class FieldDescriptorProto extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
private $name = ''; |
||||
private $has_name = false; |
||||
/** |
||||
* <code>optional int32 number = 3;</code> |
||||
*/ |
||||
private $number = 0; |
||||
private $has_number = false; |
||||
/** |
||||
* <code>optional .google.protobuf.FieldDescriptorProto.Label label = 4;</code> |
||||
*/ |
||||
private $label = 0; |
||||
private $has_label = false; |
||||
/** |
||||
* <pre> |
||||
* If type_name is set, this need not be set. If both this and type_name |
||||
* are set, this must be one of TYPE_ENUM, TYPE_MESSAGE or TYPE_GROUP. |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.FieldDescriptorProto.Type type = 5;</code> |
||||
*/ |
||||
private $type = 0; |
||||
private $has_type = false; |
||||
/** |
||||
* <pre> |
||||
* For message and enum types, this is the name of the type. If the name |
||||
* starts with a '.', it is fully-qualified. Otherwise, C++-like scoping |
||||
* rules are used to find the type (i.e. first the nested types within this |
||||
* message are searched, then within the parent, on up to the root |
||||
* namespace). |
||||
* </pre> |
||||
* |
||||
* <code>optional string type_name = 6;</code> |
||||
*/ |
||||
private $type_name = ''; |
||||
private $has_type_name = false; |
||||
/** |
||||
* <pre> |
||||
* For extensions, this is the name of the type being extended. It is |
||||
* resolved in the same manner as type_name. |
||||
* </pre> |
||||
* |
||||
* <code>optional string extendee = 2;</code> |
||||
*/ |
||||
private $extendee = ''; |
||||
private $has_extendee = false; |
||||
/** |
||||
* <pre> |
||||
* For numeric types, contains the original text representation of the value. |
||||
* For booleans, "true" or "false". |
||||
* For strings, contains the default text contents (not escaped in any way). |
||||
* For bytes, contains the C escaped value. All bytes >= 128 are escaped. |
||||
* TODO(kenton): Base-64 encode? |
||||
* </pre> |
||||
* |
||||
* <code>optional string default_value = 7;</code> |
||||
*/ |
||||
private $default_value = ''; |
||||
private $has_default_value = false; |
||||
/** |
||||
* <pre> |
||||
* If set, gives the index of a oneof in the containing type's oneof_decl |
||||
* list. This field is a member of that oneof. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 oneof_index = 9;</code> |
||||
*/ |
||||
private $oneof_index = 0; |
||||
private $has_oneof_index = false; |
||||
/** |
||||
* <pre> |
||||
* JSON name of this field. The value is set by protocol compiler. If the |
||||
* user has set a "json_name" option on this field, that option's value |
||||
* will be used. Otherwise, it's deduced from the field's name by converting |
||||
* it to camelCase. |
||||
* </pre> |
||||
* |
||||
* <code>optional string json_name = 10;</code> |
||||
*/ |
||||
private $json_name = ''; |
||||
private $has_json_name = false; |
||||
/** |
||||
* <code>optional .google.protobuf.FieldOptions options = 8;</code> |
||||
*/ |
||||
private $options = null; |
||||
private $has_options = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function getName() |
||||
{ |
||||
return $this->name; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function setName($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->name = $var; |
||||
$this->has_name = true; |
||||
} |
||||
|
||||
public function hasName() |
||||
{ |
||||
return $this->has_name; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional int32 number = 3;</code> |
||||
*/ |
||||
public function getNumber() |
||||
{ |
||||
return $this->number; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional int32 number = 3;</code> |
||||
*/ |
||||
public function setNumber($var) |
||||
{ |
||||
GPBUtil::checkInt32($var); |
||||
$this->number = $var; |
||||
$this->has_number = true; |
||||
} |
||||
|
||||
public function hasNumber() |
||||
{ |
||||
return $this->has_number; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.FieldDescriptorProto.Label label = 4;</code> |
||||
*/ |
||||
public function getLabel() |
||||
{ |
||||
return $this->label; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.FieldDescriptorProto.Label label = 4;</code> |
||||
*/ |
||||
public function setLabel($var) |
||||
{ |
||||
GPBUtil::checkEnum($var, \Google\Protobuf\Internal\FieldDescriptorProto_Label::class); |
||||
$this->label = $var; |
||||
$this->has_label = true; |
||||
} |
||||
|
||||
public function hasLabel() |
||||
{ |
||||
return $this->has_label; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If type_name is set, this need not be set. If both this and type_name |
||||
* are set, this must be one of TYPE_ENUM, TYPE_MESSAGE or TYPE_GROUP. |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.FieldDescriptorProto.Type type = 5;</code> |
||||
*/ |
||||
public function getType() |
||||
{ |
||||
return $this->type; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If type_name is set, this need not be set. If both this and type_name |
||||
* are set, this must be one of TYPE_ENUM, TYPE_MESSAGE or TYPE_GROUP. |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.FieldDescriptorProto.Type type = 5;</code> |
||||
*/ |
||||
public function setType($var) |
||||
{ |
||||
GPBUtil::checkEnum($var, \Google\Protobuf\Internal\FieldDescriptorProto_Type::class); |
||||
$this->type = $var; |
||||
$this->has_type = true; |
||||
} |
||||
|
||||
public function hasType() |
||||
{ |
||||
return $this->has_type; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* For message and enum types, this is the name of the type. If the name |
||||
* starts with a '.', it is fully-qualified. Otherwise, C++-like scoping |
||||
* rules are used to find the type (i.e. first the nested types within this |
||||
* message are searched, then within the parent, on up to the root |
||||
* namespace). |
||||
* </pre> |
||||
* |
||||
* <code>optional string type_name = 6;</code> |
||||
*/ |
||||
public function getTypeName() |
||||
{ |
||||
return $this->type_name; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* For message and enum types, this is the name of the type. If the name |
||||
* starts with a '.', it is fully-qualified. Otherwise, C++-like scoping |
||||
* rules are used to find the type (i.e. first the nested types within this |
||||
* message are searched, then within the parent, on up to the root |
||||
* namespace). |
||||
* </pre> |
||||
* |
||||
* <code>optional string type_name = 6;</code> |
||||
*/ |
||||
public function setTypeName($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->type_name = $var; |
||||
$this->has_type_name = true; |
||||
} |
||||
|
||||
public function hasTypeName() |
||||
{ |
||||
return $this->has_type_name; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* For extensions, this is the name of the type being extended. It is |
||||
* resolved in the same manner as type_name. |
||||
* </pre> |
||||
* |
||||
* <code>optional string extendee = 2;</code> |
||||
*/ |
||||
public function getExtendee() |
||||
{ |
||||
return $this->extendee; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* For extensions, this is the name of the type being extended. It is |
||||
* resolved in the same manner as type_name. |
||||
* </pre> |
||||
* |
||||
* <code>optional string extendee = 2;</code> |
||||
*/ |
||||
public function setExtendee($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->extendee = $var; |
||||
$this->has_extendee = true; |
||||
} |
||||
|
||||
public function hasExtendee() |
||||
{ |
||||
return $this->has_extendee; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* For numeric types, contains the original text representation of the value. |
||||
* For booleans, "true" or "false". |
||||
* For strings, contains the default text contents (not escaped in any way). |
||||
* For bytes, contains the C escaped value. All bytes >= 128 are escaped. |
||||
* TODO(kenton): Base-64 encode? |
||||
* </pre> |
||||
* |
||||
* <code>optional string default_value = 7;</code> |
||||
*/ |
||||
public function getDefaultValue() |
||||
{ |
||||
return $this->default_value; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* For numeric types, contains the original text representation of the value. |
||||
* For booleans, "true" or "false". |
||||
* For strings, contains the default text contents (not escaped in any way). |
||||
* For bytes, contains the C escaped value. All bytes >= 128 are escaped. |
||||
* TODO(kenton): Base-64 encode? |
||||
* </pre> |
||||
* |
||||
* <code>optional string default_value = 7;</code> |
||||
*/ |
||||
public function setDefaultValue($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->default_value = $var; |
||||
$this->has_default_value = true; |
||||
} |
||||
|
||||
public function hasDefaultValue() |
||||
{ |
||||
return $this->has_default_value; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If set, gives the index of a oneof in the containing type's oneof_decl |
||||
* list. This field is a member of that oneof. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 oneof_index = 9;</code> |
||||
*/ |
||||
public function getOneofIndex() |
||||
{ |
||||
return $this->oneof_index; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If set, gives the index of a oneof in the containing type's oneof_decl |
||||
* list. This field is a member of that oneof. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 oneof_index = 9;</code> |
||||
*/ |
||||
public function setOneofIndex($var) |
||||
{ |
||||
GPBUtil::checkInt32($var); |
||||
$this->oneof_index = $var; |
||||
$this->has_oneof_index = true; |
||||
} |
||||
|
||||
public function hasOneofIndex() |
||||
{ |
||||
return $this->has_oneof_index; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* JSON name of this field. The value is set by protocol compiler. If the |
||||
* user has set a "json_name" option on this field, that option's value |
||||
* will be used. Otherwise, it's deduced from the field's name by converting |
||||
* it to camelCase. |
||||
* </pre> |
||||
* |
||||
* <code>optional string json_name = 10;</code> |
||||
*/ |
||||
public function getJsonName() |
||||
{ |
||||
return $this->json_name; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* JSON name of this field. The value is set by protocol compiler. If the |
||||
* user has set a "json_name" option on this field, that option's value |
||||
* will be used. Otherwise, it's deduced from the field's name by converting |
||||
* it to camelCase. |
||||
* </pre> |
||||
* |
||||
* <code>optional string json_name = 10;</code> |
||||
*/ |
||||
public function setJsonName($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->json_name = $var; |
||||
$this->has_json_name = true; |
||||
} |
||||
|
||||
public function hasJsonName() |
||||
{ |
||||
return $this->has_json_name; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.FieldOptions options = 8;</code> |
||||
*/ |
||||
public function getOptions() |
||||
{ |
||||
return $this->options; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.FieldOptions options = 8;</code> |
||||
*/ |
||||
public function setOptions(&$var) |
||||
{ |
||||
GPBUtil::checkMessage($var, \Google\Protobuf\Internal\FieldOptions::class); |
||||
$this->options = $var; |
||||
$this->has_options = true; |
||||
} |
||||
|
||||
public function hasOptions() |
||||
{ |
||||
return $this->has_options; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,29 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
/** |
||||
* Protobuf enum <code>google.protobuf.FieldDescriptorProto.Label</code> |
||||
*/ |
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
class FieldDescriptorProto_Label |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* 0 is reserved for errors |
||||
* </pre> |
||||
* |
||||
* <code>LABEL_OPTIONAL = 1;</code> |
||||
*/ |
||||
const LABEL_OPTIONAL = 1; |
||||
/** |
||||
* <code>LABEL_REQUIRED = 2;</code> |
||||
*/ |
||||
const LABEL_REQUIRED = 2; |
||||
/** |
||||
* <code>LABEL_REPEATED = 3;</code> |
||||
*/ |
||||
const LABEL_REPEATED = 3; |
||||
} |
||||
|
@ -0,0 +1,120 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
/** |
||||
* Protobuf enum <code>google.protobuf.FieldDescriptorProto.Type</code> |
||||
*/ |
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
class FieldDescriptorProto_Type |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* 0 is reserved for errors. |
||||
* Order is weird for historical reasons. |
||||
* </pre> |
||||
* |
||||
* <code>TYPE_DOUBLE = 1;</code> |
||||
*/ |
||||
const TYPE_DOUBLE = 1; |
||||
/** |
||||
* <code>TYPE_FLOAT = 2;</code> |
||||
*/ |
||||
const TYPE_FLOAT = 2; |
||||
/** |
||||
* <pre> |
||||
* Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT64 if |
||||
* negative values are likely. |
||||
* </pre> |
||||
* |
||||
* <code>TYPE_INT64 = 3;</code> |
||||
*/ |
||||
const TYPE_INT64 = 3; |
||||
/** |
||||
* <code>TYPE_UINT64 = 4;</code> |
||||
*/ |
||||
const TYPE_UINT64 = 4; |
||||
/** |
||||
* <pre> |
||||
* Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT32 if |
||||
* negative values are likely. |
||||
* </pre> |
||||
* |
||||
* <code>TYPE_INT32 = 5;</code> |
||||
*/ |
||||
const TYPE_INT32 = 5; |
||||
/** |
||||
* <code>TYPE_FIXED64 = 6;</code> |
||||
*/ |
||||
const TYPE_FIXED64 = 6; |
||||
/** |
||||
* <code>TYPE_FIXED32 = 7;</code> |
||||
*/ |
||||
const TYPE_FIXED32 = 7; |
||||
/** |
||||
* <code>TYPE_BOOL = 8;</code> |
||||
*/ |
||||
const TYPE_BOOL = 8; |
||||
/** |
||||
* <code>TYPE_STRING = 9;</code> |
||||
*/ |
||||
const TYPE_STRING = 9; |
||||
/** |
||||
* <pre> |
||||
* Tag-delimited aggregate. |
||||
* </pre> |
||||
* |
||||
* <code>TYPE_GROUP = 10;</code> |
||||
*/ |
||||
const TYPE_GROUP = 10; |
||||
/** |
||||
* <pre> |
||||
* Length-delimited aggregate. |
||||
* </pre> |
||||
* |
||||
* <code>TYPE_MESSAGE = 11;</code> |
||||
*/ |
||||
const TYPE_MESSAGE = 11; |
||||
/** |
||||
* <pre> |
||||
* New in version 2. |
||||
* </pre> |
||||
* |
||||
* <code>TYPE_BYTES = 12;</code> |
||||
*/ |
||||
const TYPE_BYTES = 12; |
||||
/** |
||||
* <code>TYPE_UINT32 = 13;</code> |
||||
*/ |
||||
const TYPE_UINT32 = 13; |
||||
/** |
||||
* <code>TYPE_ENUM = 14;</code> |
||||
*/ |
||||
const TYPE_ENUM = 14; |
||||
/** |
||||
* <code>TYPE_SFIXED32 = 15;</code> |
||||
*/ |
||||
const TYPE_SFIXED32 = 15; |
||||
/** |
||||
* <code>TYPE_SFIXED64 = 16;</code> |
||||
*/ |
||||
const TYPE_SFIXED64 = 16; |
||||
/** |
||||
* <pre> |
||||
* Uses ZigZag encoding. |
||||
* </pre> |
||||
* |
||||
* <code>TYPE_SINT32 = 17;</code> |
||||
*/ |
||||
const TYPE_SINT32 = 17; |
||||
/** |
||||
* <pre> |
||||
* Uses ZigZag encoding. |
||||
* </pre> |
||||
* |
||||
* <code>TYPE_SINT64 = 18;</code> |
||||
*/ |
||||
const TYPE_SINT64 = 18; |
||||
} |
||||
|
@ -0,0 +1,429 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>google.protobuf.FieldOptions</code> |
||||
*/ |
||||
class FieldOptions extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* The ctype option instructs the C++ code generator to use a different |
||||
* representation of the field than it normally would. See the specific |
||||
* options below. This option is not yet implemented in the open source |
||||
* release -- sorry, we'll try to include it in a future version! |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.FieldOptions.CType ctype = 1 [default = STRING];</code> |
||||
*/ |
||||
private $ctype = 0; |
||||
private $has_ctype = false; |
||||
/** |
||||
* <pre> |
||||
* The packed option can be enabled for repeated primitive fields to enable |
||||
* a more efficient representation on the wire. Rather than repeatedly |
||||
* writing the tag and type for each element, the entire array is encoded as |
||||
* a single length-delimited blob. In proto3, only explicit setting it to |
||||
* false will avoid using packed encoding. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool packed = 2;</code> |
||||
*/ |
||||
private $packed = false; |
||||
private $has_packed = false; |
||||
/** |
||||
* <pre> |
||||
* The jstype option determines the JavaScript type used for values of the |
||||
* field. The option is permitted only for 64 bit integral and fixed types |
||||
* (int64, uint64, sint64, fixed64, sfixed64). By default these types are |
||||
* represented as JavaScript strings. This avoids loss of precision that can |
||||
* happen when a large value is converted to a floating point JavaScript |
||||
* numbers. Specifying JS_NUMBER for the jstype causes the generated |
||||
* JavaScript code to use the JavaScript "number" type instead of strings. |
||||
* This option is an enum to permit additional types to be added, |
||||
* e.g. goog.math.Integer. |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.FieldOptions.JSType jstype = 6 [default = JS_NORMAL];</code> |
||||
*/ |
||||
private $jstype = 0; |
||||
private $has_jstype = false; |
||||
/** |
||||
* <pre> |
||||
* Should this field be parsed lazily? Lazy applies only to message-type |
||||
* fields. It means that when the outer message is initially parsed, the |
||||
* inner message's contents will not be parsed but instead stored in encoded |
||||
* form. The inner message will actually be parsed when it is first accessed. |
||||
* This is only a hint. Implementations are free to choose whether to use |
||||
* eager or lazy parsing regardless of the value of this option. However, |
||||
* setting this option true suggests that the protocol author believes that |
||||
* using lazy parsing on this field is worth the additional bookkeeping |
||||
* overhead typically needed to implement it. |
||||
* This option does not affect the public interface of any generated code; |
||||
* all method signatures remain the same. Furthermore, thread-safety of the |
||||
* interface is not affected by this option; const methods remain safe to |
||||
* call from multiple threads concurrently, while non-const methods continue |
||||
* to require exclusive access. |
||||
* Note that implementations may choose not to check required fields within |
||||
* a lazy sub-message. That is, calling IsInitialized() on the outer message |
||||
* may return true even if the inner message has missing required fields. |
||||
* This is necessary because otherwise the inner message would have to be |
||||
* parsed in order to perform the check, defeating the purpose of lazy |
||||
* parsing. An implementation which chooses not to check required fields |
||||
* must be consistent about it. That is, for any particular sub-message, the |
||||
* implementation must either *always* check its required fields, or *never* |
||||
* check its required fields, regardless of whether or not the message has |
||||
* been parsed. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool lazy = 5 [default = false];</code> |
||||
*/ |
||||
private $lazy = false; |
||||
private $has_lazy = false; |
||||
/** |
||||
* <pre> |
||||
* Is this field deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for accessors, or it will be completely ignored; in the very least, this |
||||
* is a formalization for deprecating fields. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 3 [default = false];</code> |
||||
*/ |
||||
private $deprecated = false; |
||||
private $has_deprecated = false; |
||||
/** |
||||
* <pre> |
||||
* For Google-internal migration only. Do not use. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool weak = 10 [default = false];</code> |
||||
*/ |
||||
private $weak = false; |
||||
private $has_weak = false; |
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
private $uninterpreted_option; |
||||
private $has_uninterpreted_option = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The ctype option instructs the C++ code generator to use a different |
||||
* representation of the field than it normally would. See the specific |
||||
* options below. This option is not yet implemented in the open source |
||||
* release -- sorry, we'll try to include it in a future version! |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.FieldOptions.CType ctype = 1 [default = STRING];</code> |
||||
*/ |
||||
public function getCtype() |
||||
{ |
||||
return $this->ctype; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The ctype option instructs the C++ code generator to use a different |
||||
* representation of the field than it normally would. See the specific |
||||
* options below. This option is not yet implemented in the open source |
||||
* release -- sorry, we'll try to include it in a future version! |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.FieldOptions.CType ctype = 1 [default = STRING];</code> |
||||
*/ |
||||
public function setCtype($var) |
||||
{ |
||||
GPBUtil::checkEnum($var, \Google\Protobuf\Internal\FieldOptions_CType::class); |
||||
$this->ctype = $var; |
||||
$this->has_ctype = true; |
||||
} |
||||
|
||||
public function hasCtype() |
||||
{ |
||||
return $this->has_ctype; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The packed option can be enabled for repeated primitive fields to enable |
||||
* a more efficient representation on the wire. Rather than repeatedly |
||||
* writing the tag and type for each element, the entire array is encoded as |
||||
* a single length-delimited blob. In proto3, only explicit setting it to |
||||
* false will avoid using packed encoding. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool packed = 2;</code> |
||||
*/ |
||||
public function getPacked() |
||||
{ |
||||
return $this->packed; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The packed option can be enabled for repeated primitive fields to enable |
||||
* a more efficient representation on the wire. Rather than repeatedly |
||||
* writing the tag and type for each element, the entire array is encoded as |
||||
* a single length-delimited blob. In proto3, only explicit setting it to |
||||
* false will avoid using packed encoding. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool packed = 2;</code> |
||||
*/ |
||||
public function setPacked($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->packed = $var; |
||||
$this->has_packed = true; |
||||
} |
||||
|
||||
public function hasPacked() |
||||
{ |
||||
return $this->has_packed; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The jstype option determines the JavaScript type used for values of the |
||||
* field. The option is permitted only for 64 bit integral and fixed types |
||||
* (int64, uint64, sint64, fixed64, sfixed64). By default these types are |
||||
* represented as JavaScript strings. This avoids loss of precision that can |
||||
* happen when a large value is converted to a floating point JavaScript |
||||
* numbers. Specifying JS_NUMBER for the jstype causes the generated |
||||
* JavaScript code to use the JavaScript "number" type instead of strings. |
||||
* This option is an enum to permit additional types to be added, |
||||
* e.g. goog.math.Integer. |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.FieldOptions.JSType jstype = 6 [default = JS_NORMAL];</code> |
||||
*/ |
||||
public function getJstype() |
||||
{ |
||||
return $this->jstype; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The jstype option determines the JavaScript type used for values of the |
||||
* field. The option is permitted only for 64 bit integral and fixed types |
||||
* (int64, uint64, sint64, fixed64, sfixed64). By default these types are |
||||
* represented as JavaScript strings. This avoids loss of precision that can |
||||
* happen when a large value is converted to a floating point JavaScript |
||||
* numbers. Specifying JS_NUMBER for the jstype causes the generated |
||||
* JavaScript code to use the JavaScript "number" type instead of strings. |
||||
* This option is an enum to permit additional types to be added, |
||||
* e.g. goog.math.Integer. |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.FieldOptions.JSType jstype = 6 [default = JS_NORMAL];</code> |
||||
*/ |
||||
public function setJstype($var) |
||||
{ |
||||
GPBUtil::checkEnum($var, \Google\Protobuf\Internal\FieldOptions_JSType::class); |
||||
$this->jstype = $var; |
||||
$this->has_jstype = true; |
||||
} |
||||
|
||||
public function hasJstype() |
||||
{ |
||||
return $this->has_jstype; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Should this field be parsed lazily? Lazy applies only to message-type |
||||
* fields. It means that when the outer message is initially parsed, the |
||||
* inner message's contents will not be parsed but instead stored in encoded |
||||
* form. The inner message will actually be parsed when it is first accessed. |
||||
* This is only a hint. Implementations are free to choose whether to use |
||||
* eager or lazy parsing regardless of the value of this option. However, |
||||
* setting this option true suggests that the protocol author believes that |
||||
* using lazy parsing on this field is worth the additional bookkeeping |
||||
* overhead typically needed to implement it. |
||||
* This option does not affect the public interface of any generated code; |
||||
* all method signatures remain the same. Furthermore, thread-safety of the |
||||
* interface is not affected by this option; const methods remain safe to |
||||
* call from multiple threads concurrently, while non-const methods continue |
||||
* to require exclusive access. |
||||
* Note that implementations may choose not to check required fields within |
||||
* a lazy sub-message. That is, calling IsInitialized() on the outer message |
||||
* may return true even if the inner message has missing required fields. |
||||
* This is necessary because otherwise the inner message would have to be |
||||
* parsed in order to perform the check, defeating the purpose of lazy |
||||
* parsing. An implementation which chooses not to check required fields |
||||
* must be consistent about it. That is, for any particular sub-message, the |
||||
* implementation must either *always* check its required fields, or *never* |
||||
* check its required fields, regardless of whether or not the message has |
||||
* been parsed. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool lazy = 5 [default = false];</code> |
||||
*/ |
||||
public function getLazy() |
||||
{ |
||||
return $this->lazy; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Should this field be parsed lazily? Lazy applies only to message-type |
||||
* fields. It means that when the outer message is initially parsed, the |
||||
* inner message's contents will not be parsed but instead stored in encoded |
||||
* form. The inner message will actually be parsed when it is first accessed. |
||||
* This is only a hint. Implementations are free to choose whether to use |
||||
* eager or lazy parsing regardless of the value of this option. However, |
||||
* setting this option true suggests that the protocol author believes that |
||||
* using lazy parsing on this field is worth the additional bookkeeping |
||||
* overhead typically needed to implement it. |
||||
* This option does not affect the public interface of any generated code; |
||||
* all method signatures remain the same. Furthermore, thread-safety of the |
||||
* interface is not affected by this option; const methods remain safe to |
||||
* call from multiple threads concurrently, while non-const methods continue |
||||
* to require exclusive access. |
||||
* Note that implementations may choose not to check required fields within |
||||
* a lazy sub-message. That is, calling IsInitialized() on the outer message |
||||
* may return true even if the inner message has missing required fields. |
||||
* This is necessary because otherwise the inner message would have to be |
||||
* parsed in order to perform the check, defeating the purpose of lazy |
||||
* parsing. An implementation which chooses not to check required fields |
||||
* must be consistent about it. That is, for any particular sub-message, the |
||||
* implementation must either *always* check its required fields, or *never* |
||||
* check its required fields, regardless of whether or not the message has |
||||
* been parsed. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool lazy = 5 [default = false];</code> |
||||
*/ |
||||
public function setLazy($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->lazy = $var; |
||||
$this->has_lazy = true; |
||||
} |
||||
|
||||
public function hasLazy() |
||||
{ |
||||
return $this->has_lazy; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this field deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for accessors, or it will be completely ignored; in the very least, this |
||||
* is a formalization for deprecating fields. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 3 [default = false];</code> |
||||
*/ |
||||
public function getDeprecated() |
||||
{ |
||||
return $this->deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this field deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for accessors, or it will be completely ignored; in the very least, this |
||||
* is a formalization for deprecating fields. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 3 [default = false];</code> |
||||
*/ |
||||
public function setDeprecated($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->deprecated = $var; |
||||
$this->has_deprecated = true; |
||||
} |
||||
|
||||
public function hasDeprecated() |
||||
{ |
||||
return $this->has_deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* For Google-internal migration only. Do not use. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool weak = 10 [default = false];</code> |
||||
*/ |
||||
public function getWeak() |
||||
{ |
||||
return $this->weak; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* For Google-internal migration only. Do not use. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool weak = 10 [default = false];</code> |
||||
*/ |
||||
public function setWeak($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->weak = $var; |
||||
$this->has_weak = true; |
||||
} |
||||
|
||||
public function hasWeak() |
||||
{ |
||||
return $this->has_weak; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function getUninterpretedOption() |
||||
{ |
||||
return $this->uninterpreted_option; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function setUninterpretedOption(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption::class); |
||||
$this->uninterpreted_option = $var; |
||||
$this->has_uninterpreted_option = true; |
||||
} |
||||
|
||||
public function hasUninterpretedOption() |
||||
{ |
||||
return $this->has_uninterpreted_option; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,29 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
/** |
||||
* Protobuf enum <code>google.protobuf.FieldOptions.CType</code> |
||||
*/ |
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
class FieldOptions_CType |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Default mode. |
||||
* </pre> |
||||
* |
||||
* <code>STRING = 0;</code> |
||||
*/ |
||||
const STRING = 0; |
||||
/** |
||||
* <code>CORD = 1;</code> |
||||
*/ |
||||
const CORD = 1; |
||||
/** |
||||
* <code>STRING_PIECE = 2;</code> |
||||
*/ |
||||
const STRING_PIECE = 2; |
||||
} |
||||
|
@ -0,0 +1,37 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
/** |
||||
* Protobuf enum <code>google.protobuf.FieldOptions.JSType</code> |
||||
*/ |
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
class FieldOptions_JSType |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Use the default type. |
||||
* </pre> |
||||
* |
||||
* <code>JS_NORMAL = 0;</code> |
||||
*/ |
||||
const JS_NORMAL = 0; |
||||
/** |
||||
* <pre> |
||||
* Use JavaScript strings. |
||||
* </pre> |
||||
* |
||||
* <code>JS_STRING = 1;</code> |
||||
*/ |
||||
const JS_STRING = 1; |
||||
/** |
||||
* <pre> |
||||
* Use JavaScript numbers. |
||||
* </pre> |
||||
* |
||||
* <code>JS_NUMBER = 2;</code> |
||||
*/ |
||||
const JS_NUMBER = 2; |
||||
} |
||||
|
@ -0,0 +1,477 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* Describes a complete .proto file. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.FileDescriptorProto</code> |
||||
*/ |
||||
class FileDescriptorProto extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* file name, relative to root of source tree |
||||
* </pre> |
||||
* |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
private $name = ''; |
||||
private $has_name = false; |
||||
/** |
||||
* <pre> |
||||
* e.g. "foo", "foo.bar", etc. |
||||
* </pre> |
||||
* |
||||
* <code>optional string package = 2;</code> |
||||
*/ |
||||
private $package = ''; |
||||
private $has_package = false; |
||||
/** |
||||
* <pre> |
||||
* Names of files imported by this file. |
||||
* </pre> |
||||
* |
||||
* <code>repeated string dependency = 3;</code> |
||||
*/ |
||||
private $dependency; |
||||
private $has_dependency = false; |
||||
/** |
||||
* <pre> |
||||
* Indexes of the public imported files in the dependency list above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 public_dependency = 10;</code> |
||||
*/ |
||||
private $public_dependency; |
||||
private $has_public_dependency = false; |
||||
/** |
||||
* <pre> |
||||
* Indexes of the weak imported files in the dependency list. |
||||
* For Google-internal migration only. Do not use. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 weak_dependency = 11;</code> |
||||
*/ |
||||
private $weak_dependency; |
||||
private $has_weak_dependency = false; |
||||
/** |
||||
* <pre> |
||||
* All top-level definitions in this file. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.DescriptorProto message_type = 4;</code> |
||||
*/ |
||||
private $message_type; |
||||
private $has_message_type = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.EnumDescriptorProto enum_type = 5;</code> |
||||
*/ |
||||
private $enum_type; |
||||
private $has_enum_type = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.ServiceDescriptorProto service = 6;</code> |
||||
*/ |
||||
private $service; |
||||
private $has_service = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.FieldDescriptorProto extension = 7;</code> |
||||
*/ |
||||
private $extension; |
||||
private $has_extension = false; |
||||
/** |
||||
* <code>optional .google.protobuf.FileOptions options = 8;</code> |
||||
*/ |
||||
private $options = null; |
||||
private $has_options = false; |
||||
/** |
||||
* <pre> |
||||
* This field contains optional information about the original source code. |
||||
* You may safely remove this entire field without harming runtime |
||||
* functionality of the descriptors -- the information is needed only by |
||||
* development tools. |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.SourceCodeInfo source_code_info = 9;</code> |
||||
*/ |
||||
private $source_code_info = null; |
||||
private $has_source_code_info = false; |
||||
/** |
||||
* <pre> |
||||
* The syntax of the proto file. |
||||
* The supported values are "proto2" and "proto3". |
||||
* </pre> |
||||
* |
||||
* <code>optional string syntax = 12;</code> |
||||
*/ |
||||
private $syntax = ''; |
||||
private $has_syntax = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* file name, relative to root of source tree |
||||
* </pre> |
||||
* |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function getName() |
||||
{ |
||||
return $this->name; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* file name, relative to root of source tree |
||||
* </pre> |
||||
* |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function setName($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->name = $var; |
||||
$this->has_name = true; |
||||
} |
||||
|
||||
public function hasName() |
||||
{ |
||||
return $this->has_name; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* e.g. "foo", "foo.bar", etc. |
||||
* </pre> |
||||
* |
||||
* <code>optional string package = 2;</code> |
||||
*/ |
||||
public function getPackage() |
||||
{ |
||||
return $this->package; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* e.g. "foo", "foo.bar", etc. |
||||
* </pre> |
||||
* |
||||
* <code>optional string package = 2;</code> |
||||
*/ |
||||
public function setPackage($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->package = $var; |
||||
$this->has_package = true; |
||||
} |
||||
|
||||
public function hasPackage() |
||||
{ |
||||
return $this->has_package; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Names of files imported by this file. |
||||
* </pre> |
||||
* |
||||
* <code>repeated string dependency = 3;</code> |
||||
*/ |
||||
public function getDependency() |
||||
{ |
||||
return $this->dependency; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Names of files imported by this file. |
||||
* </pre> |
||||
* |
||||
* <code>repeated string dependency = 3;</code> |
||||
*/ |
||||
public function setDependency(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); |
||||
$this->dependency = $var; |
||||
$this->has_dependency = true; |
||||
} |
||||
|
||||
public function hasDependency() |
||||
{ |
||||
return $this->has_dependency; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Indexes of the public imported files in the dependency list above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 public_dependency = 10;</code> |
||||
*/ |
||||
public function getPublicDependency() |
||||
{ |
||||
return $this->public_dependency; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Indexes of the public imported files in the dependency list above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 public_dependency = 10;</code> |
||||
*/ |
||||
public function setPublicDependency(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); |
||||
$this->public_dependency = $var; |
||||
$this->has_public_dependency = true; |
||||
} |
||||
|
||||
public function hasPublicDependency() |
||||
{ |
||||
return $this->has_public_dependency; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Indexes of the weak imported files in the dependency list. |
||||
* For Google-internal migration only. Do not use. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 weak_dependency = 11;</code> |
||||
*/ |
||||
public function getWeakDependency() |
||||
{ |
||||
return $this->weak_dependency; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Indexes of the weak imported files in the dependency list. |
||||
* For Google-internal migration only. Do not use. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 weak_dependency = 11;</code> |
||||
*/ |
||||
public function setWeakDependency(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); |
||||
$this->weak_dependency = $var; |
||||
$this->has_weak_dependency = true; |
||||
} |
||||
|
||||
public function hasWeakDependency() |
||||
{ |
||||
return $this->has_weak_dependency; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* All top-level definitions in this file. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.DescriptorProto message_type = 4;</code> |
||||
*/ |
||||
public function getMessageType() |
||||
{ |
||||
return $this->message_type; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* All top-level definitions in this file. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.DescriptorProto message_type = 4;</code> |
||||
*/ |
||||
public function setMessageType(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\DescriptorProto::class); |
||||
$this->message_type = $var; |
||||
$this->has_message_type = true; |
||||
} |
||||
|
||||
public function hasMessageType() |
||||
{ |
||||
return $this->has_message_type; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.EnumDescriptorProto enum_type = 5;</code> |
||||
*/ |
||||
public function getEnumType() |
||||
{ |
||||
return $this->enum_type; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.EnumDescriptorProto enum_type = 5;</code> |
||||
*/ |
||||
public function setEnumType(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\EnumDescriptorProto::class); |
||||
$this->enum_type = $var; |
||||
$this->has_enum_type = true; |
||||
} |
||||
|
||||
public function hasEnumType() |
||||
{ |
||||
return $this->has_enum_type; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.ServiceDescriptorProto service = 6;</code> |
||||
*/ |
||||
public function getService() |
||||
{ |
||||
return $this->service; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.ServiceDescriptorProto service = 6;</code> |
||||
*/ |
||||
public function setService(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\ServiceDescriptorProto::class); |
||||
$this->service = $var; |
||||
$this->has_service = true; |
||||
} |
||||
|
||||
public function hasService() |
||||
{ |
||||
return $this->has_service; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.FieldDescriptorProto extension = 7;</code> |
||||
*/ |
||||
public function getExtension() |
||||
{ |
||||
return $this->extension; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.FieldDescriptorProto extension = 7;</code> |
||||
*/ |
||||
public function setExtension(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\FieldDescriptorProto::class); |
||||
$this->extension = $var; |
||||
$this->has_extension = true; |
||||
} |
||||
|
||||
public function hasExtension() |
||||
{ |
||||
return $this->has_extension; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.FileOptions options = 8;</code> |
||||
*/ |
||||
public function getOptions() |
||||
{ |
||||
return $this->options; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.FileOptions options = 8;</code> |
||||
*/ |
||||
public function setOptions(&$var) |
||||
{ |
||||
GPBUtil::checkMessage($var, \Google\Protobuf\Internal\FileOptions::class); |
||||
$this->options = $var; |
||||
$this->has_options = true; |
||||
} |
||||
|
||||
public function hasOptions() |
||||
{ |
||||
return $this->has_options; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* This field contains optional information about the original source code. |
||||
* You may safely remove this entire field without harming runtime |
||||
* functionality of the descriptors -- the information is needed only by |
||||
* development tools. |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.SourceCodeInfo source_code_info = 9;</code> |
||||
*/ |
||||
public function getSourceCodeInfo() |
||||
{ |
||||
return $this->source_code_info; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* This field contains optional information about the original source code. |
||||
* You may safely remove this entire field without harming runtime |
||||
* functionality of the descriptors -- the information is needed only by |
||||
* development tools. |
||||
* </pre> |
||||
* |
||||
* <code>optional .google.protobuf.SourceCodeInfo source_code_info = 9;</code> |
||||
*/ |
||||
public function setSourceCodeInfo(&$var) |
||||
{ |
||||
GPBUtil::checkMessage($var, \Google\Protobuf\Internal\SourceCodeInfo::class); |
||||
$this->source_code_info = $var; |
||||
$this->has_source_code_info = true; |
||||
} |
||||
|
||||
public function hasSourceCodeInfo() |
||||
{ |
||||
return $this->has_source_code_info; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The syntax of the proto file. |
||||
* The supported values are "proto2" and "proto3". |
||||
* </pre> |
||||
* |
||||
* <code>optional string syntax = 12;</code> |
||||
*/ |
||||
public function getSyntax() |
||||
{ |
||||
return $this->syntax; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The syntax of the proto file. |
||||
* The supported values are "proto2" and "proto3". |
||||
* </pre> |
||||
* |
||||
* <code>optional string syntax = 12;</code> |
||||
*/ |
||||
public function setSyntax($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->syntax = $var; |
||||
$this->has_syntax = true; |
||||
} |
||||
|
||||
public function hasSyntax() |
||||
{ |
||||
return $this->has_syntax; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,59 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* The protocol compiler can output a FileDescriptorSet containing the .proto |
||||
* files it parses. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.FileDescriptorSet</code> |
||||
*/ |
||||
class FileDescriptorSet extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>repeated .google.protobuf.FileDescriptorProto file = 1;</code> |
||||
*/ |
||||
private $file; |
||||
private $has_file = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.FileDescriptorProto file = 1;</code> |
||||
*/ |
||||
public function getFile() |
||||
{ |
||||
return $this->file; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.FileDescriptorProto file = 1;</code> |
||||
*/ |
||||
public function setFile(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\FileDescriptorProto::class); |
||||
$this->file = $var; |
||||
$this->has_file = true; |
||||
} |
||||
|
||||
public function hasFile() |
||||
{ |
||||
return $this->has_file; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,741 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>google.protobuf.FileOptions</code> |
||||
*/ |
||||
class FileOptions extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Sets the Java package where classes generated from this .proto will be |
||||
* placed. By default, the proto package is used, but this is often |
||||
* inappropriate because proto packages do not normally start with backwards |
||||
* domain names. |
||||
* </pre> |
||||
* |
||||
* <code>optional string java_package = 1;</code> |
||||
*/ |
||||
private $java_package = ''; |
||||
private $has_java_package = false; |
||||
/** |
||||
* <pre> |
||||
* If set, all the classes from the .proto file are wrapped in a single |
||||
* outer class with the given name. This applies to both Proto1 |
||||
* (equivalent to the old "--one_java_file" option) and Proto2 (where |
||||
* a .proto always translates to a single class, but you may want to |
||||
* explicitly choose the class name). |
||||
* </pre> |
||||
* |
||||
* <code>optional string java_outer_classname = 8;</code> |
||||
*/ |
||||
private $java_outer_classname = ''; |
||||
private $has_java_outer_classname = false; |
||||
/** |
||||
* <pre> |
||||
* If set true, then the Java code generator will generate a separate .java |
||||
* file for each top-level message, enum, and service defined in the .proto |
||||
* file. Thus, these types will *not* be nested inside the outer class |
||||
* named by java_outer_classname. However, the outer class will still be |
||||
* generated to contain the file's getDescriptor() method as well as any |
||||
* top-level extensions defined in the file. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool java_multiple_files = 10 [default = false];</code> |
||||
*/ |
||||
private $java_multiple_files = false; |
||||
private $has_java_multiple_files = false; |
||||
/** |
||||
* <pre> |
||||
* This option does nothing. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool java_generate_equals_and_hash = 20 [deprecated = true];</code> |
||||
*/ |
||||
private $java_generate_equals_and_hash = false; |
||||
private $has_java_generate_equals_and_hash = false; |
||||
/** |
||||
* <pre> |
||||
* If set true, then the Java2 code generator will generate code that |
||||
* throws an exception whenever an attempt is made to assign a non-UTF-8 |
||||
* byte sequence to a string field. |
||||
* Message reflection will do the same. |
||||
* However, an extension field still accepts non-UTF-8 byte sequences. |
||||
* This option has no effect on when used with the lite runtime. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool java_string_check_utf8 = 27 [default = false];</code> |
||||
*/ |
||||
private $java_string_check_utf8 = false; |
||||
private $has_java_string_check_utf8 = false; |
||||
/** |
||||
* <code>optional .google.protobuf.FileOptions.OptimizeMode optimize_for = 9 [default = SPEED];</code> |
||||
*/ |
||||
private $optimize_for = 0; |
||||
private $has_optimize_for = false; |
||||
/** |
||||
* <pre> |
||||
* Sets the Go package where structs generated from this .proto will be |
||||
* placed. If omitted, the Go package will be derived from the following: |
||||
* - The basename of the package import path, if provided. |
||||
* - Otherwise, the package statement in the .proto file, if present. |
||||
* - Otherwise, the basename of the .proto file, without extension. |
||||
* </pre> |
||||
* |
||||
* <code>optional string go_package = 11;</code> |
||||
*/ |
||||
private $go_package = ''; |
||||
private $has_go_package = false; |
||||
/** |
||||
* <pre> |
||||
* Should generic services be generated in each language? "Generic" services |
||||
* are not specific to any particular RPC system. They are generated by the |
||||
* main code generators in each language (without additional plugins). |
||||
* Generic services were the only kind of service generation supported by |
||||
* early versions of google.protobuf. |
||||
* Generic services are now considered deprecated in favor of using plugins |
||||
* that generate code specific to your particular RPC system. Therefore, |
||||
* these default to false. Old code which depends on generic services should |
||||
* explicitly set them to true. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool cc_generic_services = 16 [default = false];</code> |
||||
*/ |
||||
private $cc_generic_services = false; |
||||
private $has_cc_generic_services = false; |
||||
/** |
||||
* <code>optional bool java_generic_services = 17 [default = false];</code> |
||||
*/ |
||||
private $java_generic_services = false; |
||||
private $has_java_generic_services = false; |
||||
/** |
||||
* <code>optional bool py_generic_services = 18 [default = false];</code> |
||||
*/ |
||||
private $py_generic_services = false; |
||||
private $has_py_generic_services = false; |
||||
/** |
||||
* <pre> |
||||
* Is this file deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for everything in the file, or it will be completely ignored; in the very |
||||
* least, this is a formalization for deprecating files. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 23 [default = false];</code> |
||||
*/ |
||||
private $deprecated = false; |
||||
private $has_deprecated = false; |
||||
/** |
||||
* <pre> |
||||
* Enables the use of arenas for the proto messages in this file. This applies |
||||
* only to generated classes for C++. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool cc_enable_arenas = 31 [default = false];</code> |
||||
*/ |
||||
private $cc_enable_arenas = false; |
||||
private $has_cc_enable_arenas = false; |
||||
/** |
||||
* <pre> |
||||
* Sets the objective c class prefix which is prepended to all objective c |
||||
* generated classes from this .proto. There is no default. |
||||
* </pre> |
||||
* |
||||
* <code>optional string objc_class_prefix = 36;</code> |
||||
*/ |
||||
private $objc_class_prefix = ''; |
||||
private $has_objc_class_prefix = false; |
||||
/** |
||||
* <pre> |
||||
* Namespace for generated classes; defaults to the package. |
||||
* </pre> |
||||
* |
||||
* <code>optional string csharp_namespace = 37;</code> |
||||
*/ |
||||
private $csharp_namespace = ''; |
||||
private $has_csharp_namespace = false; |
||||
/** |
||||
* <pre> |
||||
* By default Swift generators will take the proto package and CamelCase it |
||||
* replacing '.' with underscore and use that to prefix the types/symbols |
||||
* defined. When this options is provided, they will use this value instead |
||||
* to prefix the types/symbols defined. |
||||
* </pre> |
||||
* |
||||
* <code>optional string swift_prefix = 39;</code> |
||||
*/ |
||||
private $swift_prefix = ''; |
||||
private $has_swift_prefix = false; |
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
private $uninterpreted_option; |
||||
private $has_uninterpreted_option = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Sets the Java package where classes generated from this .proto will be |
||||
* placed. By default, the proto package is used, but this is often |
||||
* inappropriate because proto packages do not normally start with backwards |
||||
* domain names. |
||||
* </pre> |
||||
* |
||||
* <code>optional string java_package = 1;</code> |
||||
*/ |
||||
public function getJavaPackage() |
||||
{ |
||||
return $this->java_package; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Sets the Java package where classes generated from this .proto will be |
||||
* placed. By default, the proto package is used, but this is often |
||||
* inappropriate because proto packages do not normally start with backwards |
||||
* domain names. |
||||
* </pre> |
||||
* |
||||
* <code>optional string java_package = 1;</code> |
||||
*/ |
||||
public function setJavaPackage($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->java_package = $var; |
||||
$this->has_java_package = true; |
||||
} |
||||
|
||||
public function hasJavaPackage() |
||||
{ |
||||
return $this->has_java_package; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If set, all the classes from the .proto file are wrapped in a single |
||||
* outer class with the given name. This applies to both Proto1 |
||||
* (equivalent to the old "--one_java_file" option) and Proto2 (where |
||||
* a .proto always translates to a single class, but you may want to |
||||
* explicitly choose the class name). |
||||
* </pre> |
||||
* |
||||
* <code>optional string java_outer_classname = 8;</code> |
||||
*/ |
||||
public function getJavaOuterClassname() |
||||
{ |
||||
return $this->java_outer_classname; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If set, all the classes from the .proto file are wrapped in a single |
||||
* outer class with the given name. This applies to both Proto1 |
||||
* (equivalent to the old "--one_java_file" option) and Proto2 (where |
||||
* a .proto always translates to a single class, but you may want to |
||||
* explicitly choose the class name). |
||||
* </pre> |
||||
* |
||||
* <code>optional string java_outer_classname = 8;</code> |
||||
*/ |
||||
public function setJavaOuterClassname($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->java_outer_classname = $var; |
||||
$this->has_java_outer_classname = true; |
||||
} |
||||
|
||||
public function hasJavaOuterClassname() |
||||
{ |
||||
return $this->has_java_outer_classname; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If set true, then the Java code generator will generate a separate .java |
||||
* file for each top-level message, enum, and service defined in the .proto |
||||
* file. Thus, these types will *not* be nested inside the outer class |
||||
* named by java_outer_classname. However, the outer class will still be |
||||
* generated to contain the file's getDescriptor() method as well as any |
||||
* top-level extensions defined in the file. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool java_multiple_files = 10 [default = false];</code> |
||||
*/ |
||||
public function getJavaMultipleFiles() |
||||
{ |
||||
return $this->java_multiple_files; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If set true, then the Java code generator will generate a separate .java |
||||
* file for each top-level message, enum, and service defined in the .proto |
||||
* file. Thus, these types will *not* be nested inside the outer class |
||||
* named by java_outer_classname. However, the outer class will still be |
||||
* generated to contain the file's getDescriptor() method as well as any |
||||
* top-level extensions defined in the file. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool java_multiple_files = 10 [default = false];</code> |
||||
*/ |
||||
public function setJavaMultipleFiles($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->java_multiple_files = $var; |
||||
$this->has_java_multiple_files = true; |
||||
} |
||||
|
||||
public function hasJavaMultipleFiles() |
||||
{ |
||||
return $this->has_java_multiple_files; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* This option does nothing. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool java_generate_equals_and_hash = 20 [deprecated = true];</code> |
||||
*/ |
||||
public function getJavaGenerateEqualsAndHash() |
||||
{ |
||||
return $this->java_generate_equals_and_hash; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* This option does nothing. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool java_generate_equals_and_hash = 20 [deprecated = true];</code> |
||||
*/ |
||||
public function setJavaGenerateEqualsAndHash($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->java_generate_equals_and_hash = $var; |
||||
$this->has_java_generate_equals_and_hash = true; |
||||
} |
||||
|
||||
public function hasJavaGenerateEqualsAndHash() |
||||
{ |
||||
return $this->has_java_generate_equals_and_hash; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If set true, then the Java2 code generator will generate code that |
||||
* throws an exception whenever an attempt is made to assign a non-UTF-8 |
||||
* byte sequence to a string field. |
||||
* Message reflection will do the same. |
||||
* However, an extension field still accepts non-UTF-8 byte sequences. |
||||
* This option has no effect on when used with the lite runtime. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool java_string_check_utf8 = 27 [default = false];</code> |
||||
*/ |
||||
public function getJavaStringCheckUtf8() |
||||
{ |
||||
return $this->java_string_check_utf8; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If set true, then the Java2 code generator will generate code that |
||||
* throws an exception whenever an attempt is made to assign a non-UTF-8 |
||||
* byte sequence to a string field. |
||||
* Message reflection will do the same. |
||||
* However, an extension field still accepts non-UTF-8 byte sequences. |
||||
* This option has no effect on when used with the lite runtime. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool java_string_check_utf8 = 27 [default = false];</code> |
||||
*/ |
||||
public function setJavaStringCheckUtf8($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->java_string_check_utf8 = $var; |
||||
$this->has_java_string_check_utf8 = true; |
||||
} |
||||
|
||||
public function hasJavaStringCheckUtf8() |
||||
{ |
||||
return $this->has_java_string_check_utf8; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.FileOptions.OptimizeMode optimize_for = 9 [default = SPEED];</code> |
||||
*/ |
||||
public function getOptimizeFor() |
||||
{ |
||||
return $this->optimize_for; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.FileOptions.OptimizeMode optimize_for = 9 [default = SPEED];</code> |
||||
*/ |
||||
public function setOptimizeFor($var) |
||||
{ |
||||
GPBUtil::checkEnum($var, \Google\Protobuf\Internal\FileOptions_OptimizeMode::class); |
||||
$this->optimize_for = $var; |
||||
$this->has_optimize_for = true; |
||||
} |
||||
|
||||
public function hasOptimizeFor() |
||||
{ |
||||
return $this->has_optimize_for; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Sets the Go package where structs generated from this .proto will be |
||||
* placed. If omitted, the Go package will be derived from the following: |
||||
* - The basename of the package import path, if provided. |
||||
* - Otherwise, the package statement in the .proto file, if present. |
||||
* - Otherwise, the basename of the .proto file, without extension. |
||||
* </pre> |
||||
* |
||||
* <code>optional string go_package = 11;</code> |
||||
*/ |
||||
public function getGoPackage() |
||||
{ |
||||
return $this->go_package; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Sets the Go package where structs generated from this .proto will be |
||||
* placed. If omitted, the Go package will be derived from the following: |
||||
* - The basename of the package import path, if provided. |
||||
* - Otherwise, the package statement in the .proto file, if present. |
||||
* - Otherwise, the basename of the .proto file, without extension. |
||||
* </pre> |
||||
* |
||||
* <code>optional string go_package = 11;</code> |
||||
*/ |
||||
public function setGoPackage($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->go_package = $var; |
||||
$this->has_go_package = true; |
||||
} |
||||
|
||||
public function hasGoPackage() |
||||
{ |
||||
return $this->has_go_package; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Should generic services be generated in each language? "Generic" services |
||||
* are not specific to any particular RPC system. They are generated by the |
||||
* main code generators in each language (without additional plugins). |
||||
* Generic services were the only kind of service generation supported by |
||||
* early versions of google.protobuf. |
||||
* Generic services are now considered deprecated in favor of using plugins |
||||
* that generate code specific to your particular RPC system. Therefore, |
||||
* these default to false. Old code which depends on generic services should |
||||
* explicitly set them to true. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool cc_generic_services = 16 [default = false];</code> |
||||
*/ |
||||
public function getCcGenericServices() |
||||
{ |
||||
return $this->cc_generic_services; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Should generic services be generated in each language? "Generic" services |
||||
* are not specific to any particular RPC system. They are generated by the |
||||
* main code generators in each language (without additional plugins). |
||||
* Generic services were the only kind of service generation supported by |
||||
* early versions of google.protobuf. |
||||
* Generic services are now considered deprecated in favor of using plugins |
||||
* that generate code specific to your particular RPC system. Therefore, |
||||
* these default to false. Old code which depends on generic services should |
||||
* explicitly set them to true. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool cc_generic_services = 16 [default = false];</code> |
||||
*/ |
||||
public function setCcGenericServices($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->cc_generic_services = $var; |
||||
$this->has_cc_generic_services = true; |
||||
} |
||||
|
||||
public function hasCcGenericServices() |
||||
{ |
||||
return $this->has_cc_generic_services; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional bool java_generic_services = 17 [default = false];</code> |
||||
*/ |
||||
public function getJavaGenericServices() |
||||
{ |
||||
return $this->java_generic_services; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional bool java_generic_services = 17 [default = false];</code> |
||||
*/ |
||||
public function setJavaGenericServices($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->java_generic_services = $var; |
||||
$this->has_java_generic_services = true; |
||||
} |
||||
|
||||
public function hasJavaGenericServices() |
||||
{ |
||||
return $this->has_java_generic_services; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional bool py_generic_services = 18 [default = false];</code> |
||||
*/ |
||||
public function getPyGenericServices() |
||||
{ |
||||
return $this->py_generic_services; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional bool py_generic_services = 18 [default = false];</code> |
||||
*/ |
||||
public function setPyGenericServices($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->py_generic_services = $var; |
||||
$this->has_py_generic_services = true; |
||||
} |
||||
|
||||
public function hasPyGenericServices() |
||||
{ |
||||
return $this->has_py_generic_services; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this file deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for everything in the file, or it will be completely ignored; in the very |
||||
* least, this is a formalization for deprecating files. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 23 [default = false];</code> |
||||
*/ |
||||
public function getDeprecated() |
||||
{ |
||||
return $this->deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this file deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for everything in the file, or it will be completely ignored; in the very |
||||
* least, this is a formalization for deprecating files. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 23 [default = false];</code> |
||||
*/ |
||||
public function setDeprecated($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->deprecated = $var; |
||||
$this->has_deprecated = true; |
||||
} |
||||
|
||||
public function hasDeprecated() |
||||
{ |
||||
return $this->has_deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Enables the use of arenas for the proto messages in this file. This applies |
||||
* only to generated classes for C++. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool cc_enable_arenas = 31 [default = false];</code> |
||||
*/ |
||||
public function getCcEnableArenas() |
||||
{ |
||||
return $this->cc_enable_arenas; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Enables the use of arenas for the proto messages in this file. This applies |
||||
* only to generated classes for C++. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool cc_enable_arenas = 31 [default = false];</code> |
||||
*/ |
||||
public function setCcEnableArenas($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->cc_enable_arenas = $var; |
||||
$this->has_cc_enable_arenas = true; |
||||
} |
||||
|
||||
public function hasCcEnableArenas() |
||||
{ |
||||
return $this->has_cc_enable_arenas; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Sets the objective c class prefix which is prepended to all objective c |
||||
* generated classes from this .proto. There is no default. |
||||
* </pre> |
||||
* |
||||
* <code>optional string objc_class_prefix = 36;</code> |
||||
*/ |
||||
public function getObjcClassPrefix() |
||||
{ |
||||
return $this->objc_class_prefix; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Sets the objective c class prefix which is prepended to all objective c |
||||
* generated classes from this .proto. There is no default. |
||||
* </pre> |
||||
* |
||||
* <code>optional string objc_class_prefix = 36;</code> |
||||
*/ |
||||
public function setObjcClassPrefix($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->objc_class_prefix = $var; |
||||
$this->has_objc_class_prefix = true; |
||||
} |
||||
|
||||
public function hasObjcClassPrefix() |
||||
{ |
||||
return $this->has_objc_class_prefix; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Namespace for generated classes; defaults to the package. |
||||
* </pre> |
||||
* |
||||
* <code>optional string csharp_namespace = 37;</code> |
||||
*/ |
||||
public function getCsharpNamespace() |
||||
{ |
||||
return $this->csharp_namespace; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Namespace for generated classes; defaults to the package. |
||||
* </pre> |
||||
* |
||||
* <code>optional string csharp_namespace = 37;</code> |
||||
*/ |
||||
public function setCsharpNamespace($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->csharp_namespace = $var; |
||||
$this->has_csharp_namespace = true; |
||||
} |
||||
|
||||
public function hasCsharpNamespace() |
||||
{ |
||||
return $this->has_csharp_namespace; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* By default Swift generators will take the proto package and CamelCase it |
||||
* replacing '.' with underscore and use that to prefix the types/symbols |
||||
* defined. When this options is provided, they will use this value instead |
||||
* to prefix the types/symbols defined. |
||||
* </pre> |
||||
* |
||||
* <code>optional string swift_prefix = 39;</code> |
||||
*/ |
||||
public function getSwiftPrefix() |
||||
{ |
||||
return $this->swift_prefix; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* By default Swift generators will take the proto package and CamelCase it |
||||
* replacing '.' with underscore and use that to prefix the types/symbols |
||||
* defined. When this options is provided, they will use this value instead |
||||
* to prefix the types/symbols defined. |
||||
* </pre> |
||||
* |
||||
* <code>optional string swift_prefix = 39;</code> |
||||
*/ |
||||
public function setSwiftPrefix($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->swift_prefix = $var; |
||||
$this->has_swift_prefix = true; |
||||
} |
||||
|
||||
public function hasSwiftPrefix() |
||||
{ |
||||
return $this->has_swift_prefix; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function getUninterpretedOption() |
||||
{ |
||||
return $this->uninterpreted_option; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function setUninterpretedOption(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption::class); |
||||
$this->uninterpreted_option = $var; |
||||
$this->has_uninterpreted_option = true; |
||||
} |
||||
|
||||
public function hasUninterpretedOption() |
||||
{ |
||||
return $this->has_uninterpreted_option; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,41 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
/** |
||||
* <pre> |
||||
* Generated classes can be optimized for speed or code size. |
||||
* </pre> |
||||
* |
||||
* Protobuf enum <code>google.protobuf.FileOptions.OptimizeMode</code> |
||||
*/ |
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
class FileOptions_OptimizeMode |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Generate complete code for parsing, serialization, |
||||
* </pre> |
||||
* |
||||
* <code>SPEED = 1;</code> |
||||
*/ |
||||
const SPEED = 1; |
||||
/** |
||||
* <pre> |
||||
* etc. |
||||
* </pre> |
||||
* |
||||
* <code>CODE_SIZE = 2;</code> |
||||
*/ |
||||
const CODE_SIZE = 2; |
||||
/** |
||||
* <pre> |
||||
* Generate code using MessageLite and the lite runtime. |
||||
* </pre> |
||||
* |
||||
* <code>LITE_RUNTIME = 3;</code> |
||||
*/ |
||||
const LITE_RUNTIME = 3; |
||||
} |
||||
|
@ -0,0 +1,75 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* Describes the relationship between generated code and its original source |
||||
* file. A GeneratedCodeInfo message is associated with only one generated |
||||
* source file, but may contain references to different source .proto files. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.GeneratedCodeInfo</code> |
||||
*/ |
||||
class GeneratedCodeInfo extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* An Annotation connects some span of text in generated code to an element |
||||
* of its generating .proto file. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.GeneratedCodeInfo.Annotation annotation = 1;</code> |
||||
*/ |
||||
private $annotation; |
||||
private $has_annotation = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* An Annotation connects some span of text in generated code to an element |
||||
* of its generating .proto file. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.GeneratedCodeInfo.Annotation annotation = 1;</code> |
||||
*/ |
||||
public function getAnnotation() |
||||
{ |
||||
return $this->annotation; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* An Annotation connects some span of text in generated code to an element |
||||
* of its generating .proto file. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.GeneratedCodeInfo.Annotation annotation = 1;</code> |
||||
*/ |
||||
public function setAnnotation(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\GeneratedCodeInfo_Annotation::class); |
||||
$this->annotation = $var; |
||||
$this->has_annotation = true; |
||||
} |
||||
|
||||
public function hasAnnotation() |
||||
{ |
||||
return $this->has_annotation; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,198 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>google.protobuf.GeneratedCodeInfo.Annotation</code> |
||||
*/ |
||||
class GeneratedCodeInfo_Annotation extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Identifies the element in the original source .proto file. This field |
||||
* is formatted the same as SourceCodeInfo.Location.path. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 path = 1 [packed = true];</code> |
||||
*/ |
||||
private $path; |
||||
private $has_path = false; |
||||
/** |
||||
* <pre> |
||||
* Identifies the filesystem path to the original source .proto. |
||||
* </pre> |
||||
* |
||||
* <code>optional string source_file = 2;</code> |
||||
*/ |
||||
private $source_file = ''; |
||||
private $has_source_file = false; |
||||
/** |
||||
* <pre> |
||||
* Identifies the starting offset in bytes in the generated code |
||||
* that relates to the identified object. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 begin = 3;</code> |
||||
*/ |
||||
private $begin = 0; |
||||
private $has_begin = false; |
||||
/** |
||||
* <pre> |
||||
* Identifies the ending offset in bytes in the generated code that |
||||
* relates to the identified offset. The end offset should be one past |
||||
* the last relevant byte (so the length of the text = end - begin). |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 end = 4;</code> |
||||
*/ |
||||
private $end = 0; |
||||
private $has_end = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies the element in the original source .proto file. This field |
||||
* is formatted the same as SourceCodeInfo.Location.path. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 path = 1 [packed = true];</code> |
||||
*/ |
||||
public function getPath() |
||||
{ |
||||
return $this->path; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies the element in the original source .proto file. This field |
||||
* is formatted the same as SourceCodeInfo.Location.path. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 path = 1 [packed = true];</code> |
||||
*/ |
||||
public function setPath(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); |
||||
$this->path = $var; |
||||
$this->has_path = true; |
||||
} |
||||
|
||||
public function hasPath() |
||||
{ |
||||
return $this->has_path; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies the filesystem path to the original source .proto. |
||||
* </pre> |
||||
* |
||||
* <code>optional string source_file = 2;</code> |
||||
*/ |
||||
public function getSourceFile() |
||||
{ |
||||
return $this->source_file; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies the filesystem path to the original source .proto. |
||||
* </pre> |
||||
* |
||||
* <code>optional string source_file = 2;</code> |
||||
*/ |
||||
public function setSourceFile($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->source_file = $var; |
||||
$this->has_source_file = true; |
||||
} |
||||
|
||||
public function hasSourceFile() |
||||
{ |
||||
return $this->has_source_file; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies the starting offset in bytes in the generated code |
||||
* that relates to the identified object. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 begin = 3;</code> |
||||
*/ |
||||
public function getBegin() |
||||
{ |
||||
return $this->begin; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies the starting offset in bytes in the generated code |
||||
* that relates to the identified object. |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 begin = 3;</code> |
||||
*/ |
||||
public function setBegin($var) |
||||
{ |
||||
GPBUtil::checkInt32($var); |
||||
$this->begin = $var; |
||||
$this->has_begin = true; |
||||
} |
||||
|
||||
public function hasBegin() |
||||
{ |
||||
return $this->has_begin; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies the ending offset in bytes in the generated code that |
||||
* relates to the identified offset. The end offset should be one past |
||||
* the last relevant byte (so the length of the text = end - begin). |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 end = 4;</code> |
||||
*/ |
||||
public function getEnd() |
||||
{ |
||||
return $this->end; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies the ending offset in bytes in the generated code that |
||||
* relates to the identified offset. The end offset should be one past |
||||
* the last relevant byte (so the length of the text = end - begin). |
||||
* </pre> |
||||
* |
||||
* <code>optional int32 end = 4;</code> |
||||
*/ |
||||
public function setEnd($var) |
||||
{ |
||||
GPBUtil::checkInt32($var); |
||||
$this->end = $var; |
||||
$this->has_end = true; |
||||
} |
||||
|
||||
public function hasEnd() |
||||
{ |
||||
return $this->has_end; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,334 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>google.protobuf.MessageOptions</code> |
||||
*/ |
||||
class MessageOptions extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Set true to use the old proto1 MessageSet wire format for extensions. |
||||
* This is provided for backwards-compatibility with the MessageSet wire |
||||
* format. You should not use this for any other reason: It's less |
||||
* efficient, has fewer features, and is more complicated. |
||||
* The message must be defined exactly as follows: |
||||
* message Foo { |
||||
* option message_set_wire_format = true; |
||||
* extensions 4 to max; |
||||
* } |
||||
* Note that the message cannot have any defined fields; MessageSets only |
||||
* have extensions. |
||||
* All extensions of your type must be singular messages; e.g. they cannot |
||||
* be int32s, enums, or repeated messages. |
||||
* Because this is an option, the above two restrictions are not enforced by |
||||
* the protocol compiler. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool message_set_wire_format = 1 [default = false];</code> |
||||
*/ |
||||
private $message_set_wire_format = false; |
||||
private $has_message_set_wire_format = false; |
||||
/** |
||||
* <pre> |
||||
* Disables the generation of the standard "descriptor()" accessor, which can |
||||
* conflict with a field of the same name. This is meant to make migration |
||||
* from proto1 easier; new code should avoid fields named "descriptor". |
||||
* </pre> |
||||
* |
||||
* <code>optional bool no_standard_descriptor_accessor = 2 [default = false];</code> |
||||
*/ |
||||
private $no_standard_descriptor_accessor = false; |
||||
private $has_no_standard_descriptor_accessor = false; |
||||
/** |
||||
* <pre> |
||||
* Is this message deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the message, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating messages. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 3 [default = false];</code> |
||||
*/ |
||||
private $deprecated = false; |
||||
private $has_deprecated = false; |
||||
/** |
||||
* <pre> |
||||
* Whether the message is an automatically generated map entry type for the |
||||
* maps field. |
||||
* For maps fields: |
||||
* map<KeyType, ValueType> map_field = 1; |
||||
* The parsed descriptor looks like: |
||||
* message MapFieldEntry { |
||||
* option map_entry = true; |
||||
* optional KeyType key = 1; |
||||
* optional ValueType value = 2; |
||||
* } |
||||
* repeated MapFieldEntry map_field = 1; |
||||
* Implementations may choose not to generate the map_entry=true message, but |
||||
* use a native map in the target language to hold the keys and values. |
||||
* The reflection APIs in such implementions still need to work as |
||||
* if the field is a repeated message field. |
||||
* NOTE: Do not set the option in .proto files. Always use the maps syntax |
||||
* instead. The option should only be implicitly set by the proto compiler |
||||
* parser. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool map_entry = 7;</code> |
||||
*/ |
||||
private $map_entry = false; |
||||
private $has_map_entry = false; |
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
private $uninterpreted_option; |
||||
private $has_uninterpreted_option = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Set true to use the old proto1 MessageSet wire format for extensions. |
||||
* This is provided for backwards-compatibility with the MessageSet wire |
||||
* format. You should not use this for any other reason: It's less |
||||
* efficient, has fewer features, and is more complicated. |
||||
* The message must be defined exactly as follows: |
||||
* message Foo { |
||||
* option message_set_wire_format = true; |
||||
* extensions 4 to max; |
||||
* } |
||||
* Note that the message cannot have any defined fields; MessageSets only |
||||
* have extensions. |
||||
* All extensions of your type must be singular messages; e.g. they cannot |
||||
* be int32s, enums, or repeated messages. |
||||
* Because this is an option, the above two restrictions are not enforced by |
||||
* the protocol compiler. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool message_set_wire_format = 1 [default = false];</code> |
||||
*/ |
||||
public function getMessageSetWireFormat() |
||||
{ |
||||
return $this->message_set_wire_format; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Set true to use the old proto1 MessageSet wire format for extensions. |
||||
* This is provided for backwards-compatibility with the MessageSet wire |
||||
* format. You should not use this for any other reason: It's less |
||||
* efficient, has fewer features, and is more complicated. |
||||
* The message must be defined exactly as follows: |
||||
* message Foo { |
||||
* option message_set_wire_format = true; |
||||
* extensions 4 to max; |
||||
* } |
||||
* Note that the message cannot have any defined fields; MessageSets only |
||||
* have extensions. |
||||
* All extensions of your type must be singular messages; e.g. they cannot |
||||
* be int32s, enums, or repeated messages. |
||||
* Because this is an option, the above two restrictions are not enforced by |
||||
* the protocol compiler. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool message_set_wire_format = 1 [default = false];</code> |
||||
*/ |
||||
public function setMessageSetWireFormat($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->message_set_wire_format = $var; |
||||
$this->has_message_set_wire_format = true; |
||||
} |
||||
|
||||
public function hasMessageSetWireFormat() |
||||
{ |
||||
return $this->has_message_set_wire_format; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Disables the generation of the standard "descriptor()" accessor, which can |
||||
* conflict with a field of the same name. This is meant to make migration |
||||
* from proto1 easier; new code should avoid fields named "descriptor". |
||||
* </pre> |
||||
* |
||||
* <code>optional bool no_standard_descriptor_accessor = 2 [default = false];</code> |
||||
*/ |
||||
public function getNoStandardDescriptorAccessor() |
||||
{ |
||||
return $this->no_standard_descriptor_accessor; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Disables the generation of the standard "descriptor()" accessor, which can |
||||
* conflict with a field of the same name. This is meant to make migration |
||||
* from proto1 easier; new code should avoid fields named "descriptor". |
||||
* </pre> |
||||
* |
||||
* <code>optional bool no_standard_descriptor_accessor = 2 [default = false];</code> |
||||
*/ |
||||
public function setNoStandardDescriptorAccessor($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->no_standard_descriptor_accessor = $var; |
||||
$this->has_no_standard_descriptor_accessor = true; |
||||
} |
||||
|
||||
public function hasNoStandardDescriptorAccessor() |
||||
{ |
||||
return $this->has_no_standard_descriptor_accessor; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this message deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the message, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating messages. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 3 [default = false];</code> |
||||
*/ |
||||
public function getDeprecated() |
||||
{ |
||||
return $this->deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this message deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the message, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating messages. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 3 [default = false];</code> |
||||
*/ |
||||
public function setDeprecated($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->deprecated = $var; |
||||
$this->has_deprecated = true; |
||||
} |
||||
|
||||
public function hasDeprecated() |
||||
{ |
||||
return $this->has_deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Whether the message is an automatically generated map entry type for the |
||||
* maps field. |
||||
* For maps fields: |
||||
* map<KeyType, ValueType> map_field = 1; |
||||
* The parsed descriptor looks like: |
||||
* message MapFieldEntry { |
||||
* option map_entry = true; |
||||
* optional KeyType key = 1; |
||||
* optional ValueType value = 2; |
||||
* } |
||||
* repeated MapFieldEntry map_field = 1; |
||||
* Implementations may choose not to generate the map_entry=true message, but |
||||
* use a native map in the target language to hold the keys and values. |
||||
* The reflection APIs in such implementions still need to work as |
||||
* if the field is a repeated message field. |
||||
* NOTE: Do not set the option in .proto files. Always use the maps syntax |
||||
* instead. The option should only be implicitly set by the proto compiler |
||||
* parser. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool map_entry = 7;</code> |
||||
*/ |
||||
public function getMapEntry() |
||||
{ |
||||
return $this->map_entry; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Whether the message is an automatically generated map entry type for the |
||||
* maps field. |
||||
* For maps fields: |
||||
* map<KeyType, ValueType> map_field = 1; |
||||
* The parsed descriptor looks like: |
||||
* message MapFieldEntry { |
||||
* option map_entry = true; |
||||
* optional KeyType key = 1; |
||||
* optional ValueType value = 2; |
||||
* } |
||||
* repeated MapFieldEntry map_field = 1; |
||||
* Implementations may choose not to generate the map_entry=true message, but |
||||
* use a native map in the target language to hold the keys and values. |
||||
* The reflection APIs in such implementions still need to work as |
||||
* if the field is a repeated message field. |
||||
* NOTE: Do not set the option in .proto files. Always use the maps syntax |
||||
* instead. The option should only be implicitly set by the proto compiler |
||||
* parser. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool map_entry = 7;</code> |
||||
*/ |
||||
public function setMapEntry($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->map_entry = $var; |
||||
$this->has_map_entry = true; |
||||
} |
||||
|
||||
public function hasMapEntry() |
||||
{ |
||||
return $this->has_map_entry; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function getUninterpretedOption() |
||||
{ |
||||
return $this->uninterpreted_option; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function setUninterpretedOption(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption::class); |
||||
$this->uninterpreted_option = $var; |
||||
$this->has_uninterpreted_option = true; |
||||
} |
||||
|
||||
public function hasUninterpretedOption() |
||||
{ |
||||
return $this->has_uninterpreted_option; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,237 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* Describes a method of a service. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.MethodDescriptorProto</code> |
||||
*/ |
||||
class MethodDescriptorProto extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
private $name = ''; |
||||
private $has_name = false; |
||||
/** |
||||
* <pre> |
||||
* Input and output type names. These are resolved in the same way as |
||||
* FieldDescriptorProto.type_name, but must refer to a message type. |
||||
* </pre> |
||||
* |
||||
* <code>optional string input_type = 2;</code> |
||||
*/ |
||||
private $input_type = ''; |
||||
private $has_input_type = false; |
||||
/** |
||||
* <code>optional string output_type = 3;</code> |
||||
*/ |
||||
private $output_type = ''; |
||||
private $has_output_type = false; |
||||
/** |
||||
* <code>optional .google.protobuf.MethodOptions options = 4;</code> |
||||
*/ |
||||
private $options = null; |
||||
private $has_options = false; |
||||
/** |
||||
* <pre> |
||||
* Identifies if client streams multiple client messages |
||||
* </pre> |
||||
* |
||||
* <code>optional bool client_streaming = 5 [default = false];</code> |
||||
*/ |
||||
private $client_streaming = false; |
||||
private $has_client_streaming = false; |
||||
/** |
||||
* <pre> |
||||
* Identifies if server streams multiple server messages |
||||
* </pre> |
||||
* |
||||
* <code>optional bool server_streaming = 6 [default = false];</code> |
||||
*/ |
||||
private $server_streaming = false; |
||||
private $has_server_streaming = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function getName() |
||||
{ |
||||
return $this->name; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function setName($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->name = $var; |
||||
$this->has_name = true; |
||||
} |
||||
|
||||
public function hasName() |
||||
{ |
||||
return $this->has_name; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Input and output type names. These are resolved in the same way as |
||||
* FieldDescriptorProto.type_name, but must refer to a message type. |
||||
* </pre> |
||||
* |
||||
* <code>optional string input_type = 2;</code> |
||||
*/ |
||||
public function getInputType() |
||||
{ |
||||
return $this->input_type; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Input and output type names. These are resolved in the same way as |
||||
* FieldDescriptorProto.type_name, but must refer to a message type. |
||||
* </pre> |
||||
* |
||||
* <code>optional string input_type = 2;</code> |
||||
*/ |
||||
public function setInputType($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->input_type = $var; |
||||
$this->has_input_type = true; |
||||
} |
||||
|
||||
public function hasInputType() |
||||
{ |
||||
return $this->has_input_type; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string output_type = 3;</code> |
||||
*/ |
||||
public function getOutputType() |
||||
{ |
||||
return $this->output_type; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string output_type = 3;</code> |
||||
*/ |
||||
public function setOutputType($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->output_type = $var; |
||||
$this->has_output_type = true; |
||||
} |
||||
|
||||
public function hasOutputType() |
||||
{ |
||||
return $this->has_output_type; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.MethodOptions options = 4;</code> |
||||
*/ |
||||
public function getOptions() |
||||
{ |
||||
return $this->options; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.MethodOptions options = 4;</code> |
||||
*/ |
||||
public function setOptions(&$var) |
||||
{ |
||||
GPBUtil::checkMessage($var, \Google\Protobuf\Internal\MethodOptions::class); |
||||
$this->options = $var; |
||||
$this->has_options = true; |
||||
} |
||||
|
||||
public function hasOptions() |
||||
{ |
||||
return $this->has_options; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies if client streams multiple client messages |
||||
* </pre> |
||||
* |
||||
* <code>optional bool client_streaming = 5 [default = false];</code> |
||||
*/ |
||||
public function getClientStreaming() |
||||
{ |
||||
return $this->client_streaming; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies if client streams multiple client messages |
||||
* </pre> |
||||
* |
||||
* <code>optional bool client_streaming = 5 [default = false];</code> |
||||
*/ |
||||
public function setClientStreaming($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->client_streaming = $var; |
||||
$this->has_client_streaming = true; |
||||
} |
||||
|
||||
public function hasClientStreaming() |
||||
{ |
||||
return $this->has_client_streaming; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies if server streams multiple server messages |
||||
* </pre> |
||||
* |
||||
* <code>optional bool server_streaming = 6 [default = false];</code> |
||||
*/ |
||||
public function getServerStreaming() |
||||
{ |
||||
return $this->server_streaming; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies if server streams multiple server messages |
||||
* </pre> |
||||
* |
||||
* <code>optional bool server_streaming = 6 [default = false];</code> |
||||
*/ |
||||
public function setServerStreaming($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->server_streaming = $var; |
||||
$this->has_server_streaming = true; |
||||
} |
||||
|
||||
public function hasServerStreaming() |
||||
{ |
||||
return $this->has_server_streaming; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,143 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>google.protobuf.MethodOptions</code> |
||||
*/ |
||||
class MethodOptions extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Is this method deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the method, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating methods. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 33 [default = false];</code> |
||||
*/ |
||||
private $deprecated = false; |
||||
private $has_deprecated = false; |
||||
/** |
||||
* <code>optional .google.protobuf.MethodOptions.IdempotencyLevel idempotency_level = 34 [default = IDEMPOTENCY_UNKNOWN];</code> |
||||
*/ |
||||
private $idempotency_level = 0; |
||||
private $has_idempotency_level = false; |
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
private $uninterpreted_option; |
||||
private $has_uninterpreted_option = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this method deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the method, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating methods. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 33 [default = false];</code> |
||||
*/ |
||||
public function getDeprecated() |
||||
{ |
||||
return $this->deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this method deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the method, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating methods. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 33 [default = false];</code> |
||||
*/ |
||||
public function setDeprecated($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->deprecated = $var; |
||||
$this->has_deprecated = true; |
||||
} |
||||
|
||||
public function hasDeprecated() |
||||
{ |
||||
return $this->has_deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.MethodOptions.IdempotencyLevel idempotency_level = 34 [default = IDEMPOTENCY_UNKNOWN];</code> |
||||
*/ |
||||
public function getIdempotencyLevel() |
||||
{ |
||||
return $this->idempotency_level; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.MethodOptions.IdempotencyLevel idempotency_level = 34 [default = IDEMPOTENCY_UNKNOWN];</code> |
||||
*/ |
||||
public function setIdempotencyLevel($var) |
||||
{ |
||||
GPBUtil::checkEnum($var, \Google\Protobuf\Internal\MethodOptions_IdempotencyLevel::class); |
||||
$this->idempotency_level = $var; |
||||
$this->has_idempotency_level = true; |
||||
} |
||||
|
||||
public function hasIdempotencyLevel() |
||||
{ |
||||
return $this->has_idempotency_level; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function getUninterpretedOption() |
||||
{ |
||||
return $this->uninterpreted_option; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function setUninterpretedOption(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption::class); |
||||
$this->uninterpreted_option = $var; |
||||
$this->has_uninterpreted_option = true; |
||||
} |
||||
|
||||
public function hasUninterpretedOption() |
||||
{ |
||||
return $this->has_uninterpreted_option; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,39 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this method side-effect-free (or safe in HTTP parlance), or idempotent, |
||||
* or neither? HTTP based RPC implementation may choose GET verb for safe |
||||
* methods, and PUT verb for idempotent methods instead of the default POST. |
||||
* </pre> |
||||
* |
||||
* Protobuf enum <code>google.protobuf.MethodOptions.IdempotencyLevel</code> |
||||
*/ |
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
class MethodOptions_IdempotencyLevel |
||||
{ |
||||
/** |
||||
* <code>IDEMPOTENCY_UNKNOWN = 0;</code> |
||||
*/ |
||||
const IDEMPOTENCY_UNKNOWN = 0; |
||||
/** |
||||
* <pre> |
||||
* implies idempotent |
||||
* </pre> |
||||
* |
||||
* <code>NO_SIDE_EFFECTS = 1;</code> |
||||
*/ |
||||
const NO_SIDE_EFFECTS = 1; |
||||
/** |
||||
* <pre> |
||||
* idempotent, but may have side effects |
||||
* </pre> |
||||
* |
||||
* <code>IDEMPOTENT = 2;</code> |
||||
*/ |
||||
const IDEMPOTENT = 2; |
||||
} |
||||
|
@ -0,0 +1,86 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* Describes a oneof. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.OneofDescriptorProto</code> |
||||
*/ |
||||
class OneofDescriptorProto extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
private $name = ''; |
||||
private $has_name = false; |
||||
/** |
||||
* <code>optional .google.protobuf.OneofOptions options = 2;</code> |
||||
*/ |
||||
private $options = null; |
||||
private $has_options = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function getName() |
||||
{ |
||||
return $this->name; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function setName($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->name = $var; |
||||
$this->has_name = true; |
||||
} |
||||
|
||||
public function hasName() |
||||
{ |
||||
return $this->has_name; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.OneofOptions options = 2;</code> |
||||
*/ |
||||
public function getOptions() |
||||
{ |
||||
return $this->options; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.OneofOptions options = 2;</code> |
||||
*/ |
||||
public function setOptions(&$var) |
||||
{ |
||||
GPBUtil::checkMessage($var, \Google\Protobuf\Internal\OneofOptions::class); |
||||
$this->options = $var; |
||||
$this->has_options = true; |
||||
} |
||||
|
||||
public function hasOptions() |
||||
{ |
||||
return $this->has_options; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,66 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>google.protobuf.OneofOptions</code> |
||||
*/ |
||||
class OneofOptions extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
private $uninterpreted_option; |
||||
private $has_uninterpreted_option = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function getUninterpretedOption() |
||||
{ |
||||
return $this->uninterpreted_option; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function setUninterpretedOption(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption::class); |
||||
$this->uninterpreted_option = $var; |
||||
$this->has_uninterpreted_option = true; |
||||
} |
||||
|
||||
public function hasUninterpretedOption() |
||||
{ |
||||
return $this->has_uninterpreted_option; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,114 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* Describes a service. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.ServiceDescriptorProto</code> |
||||
*/ |
||||
class ServiceDescriptorProto extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
private $name = ''; |
||||
private $has_name = false; |
||||
/** |
||||
* <code>repeated .google.protobuf.MethodDescriptorProto method = 2;</code> |
||||
*/ |
||||
private $method; |
||||
private $has_method = false; |
||||
/** |
||||
* <code>optional .google.protobuf.ServiceOptions options = 3;</code> |
||||
*/ |
||||
private $options = null; |
||||
private $has_options = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function getName() |
||||
{ |
||||
return $this->name; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string name = 1;</code> |
||||
*/ |
||||
public function setName($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->name = $var; |
||||
$this->has_name = true; |
||||
} |
||||
|
||||
public function hasName() |
||||
{ |
||||
return $this->has_name; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.MethodDescriptorProto method = 2;</code> |
||||
*/ |
||||
public function getMethod() |
||||
{ |
||||
return $this->method; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.MethodDescriptorProto method = 2;</code> |
||||
*/ |
||||
public function setMethod(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\MethodDescriptorProto::class); |
||||
$this->method = $var; |
||||
$this->has_method = true; |
||||
} |
||||
|
||||
public function hasMethod() |
||||
{ |
||||
return $this->has_method; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.ServiceOptions options = 3;</code> |
||||
*/ |
||||
public function getOptions() |
||||
{ |
||||
return $this->options; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional .google.protobuf.ServiceOptions options = 3;</code> |
||||
*/ |
||||
public function setOptions(&$var) |
||||
{ |
||||
GPBUtil::checkMessage($var, \Google\Protobuf\Internal\ServiceOptions::class); |
||||
$this->options = $var; |
||||
$this->has_options = true; |
||||
} |
||||
|
||||
public function hasOptions() |
||||
{ |
||||
return $this->has_options; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,115 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>google.protobuf.ServiceOptions</code> |
||||
*/ |
||||
class ServiceOptions extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Is this service deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the service, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating services. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 33 [default = false];</code> |
||||
*/ |
||||
private $deprecated = false; |
||||
private $has_deprecated = false; |
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
private $uninterpreted_option; |
||||
private $has_uninterpreted_option = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this service deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the service, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating services. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 33 [default = false];</code> |
||||
*/ |
||||
public function getDeprecated() |
||||
{ |
||||
return $this->deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Is this service deprecated? |
||||
* Depending on the target platform, this can emit Deprecated annotations |
||||
* for the service, or it will be completely ignored; in the very least, |
||||
* this is a formalization for deprecating services. |
||||
* </pre> |
||||
* |
||||
* <code>optional bool deprecated = 33 [default = false];</code> |
||||
*/ |
||||
public function setDeprecated($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->deprecated = $var; |
||||
$this->has_deprecated = true; |
||||
} |
||||
|
||||
public function hasDeprecated() |
||||
{ |
||||
return $this->has_deprecated; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function getUninterpretedOption() |
||||
{ |
||||
return $this->uninterpreted_option; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The parser stores options it doesn't recognize here. See above. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999;</code> |
||||
*/ |
||||
public function setUninterpretedOption(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption::class); |
||||
$this->uninterpreted_option = $var; |
||||
$this->has_uninterpreted_option = true; |
||||
} |
||||
|
||||
public function hasUninterpretedOption() |
||||
{ |
||||
return $this->has_uninterpreted_option; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,191 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* Encapsulates information about the original source file from which a |
||||
* FileDescriptorProto was generated. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.SourceCodeInfo</code> |
||||
*/ |
||||
class SourceCodeInfo extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* A Location identifies a piece of source code in a .proto file which |
||||
* corresponds to a particular definition. This information is intended |
||||
* to be useful to IDEs, code indexers, documentation generators, and similar |
||||
* tools. |
||||
* For example, say we have a file like: |
||||
* message Foo { |
||||
* optional string foo = 1; |
||||
* } |
||||
* Let's look at just the field definition: |
||||
* optional string foo = 1; |
||||
* ^ ^^ ^^ ^ ^^^ |
||||
* a bc de f ghi |
||||
* We have the following locations: |
||||
* span path represents |
||||
* [a,i) [ 4, 0, 2, 0 ] The whole field definition. |
||||
* [a,b) [ 4, 0, 2, 0, 4 ] The label (optional). |
||||
* [c,d) [ 4, 0, 2, 0, 5 ] The type (string). |
||||
* [e,f) [ 4, 0, 2, 0, 1 ] The name (foo). |
||||
* [g,h) [ 4, 0, 2, 0, 3 ] The number (1). |
||||
* Notes: |
||||
* - A location may refer to a repeated field itself (i.e. not to any |
||||
* particular index within it). This is used whenever a set of elements are |
||||
* logically enclosed in a single code segment. For example, an entire |
||||
* extend block (possibly containing multiple extension definitions) will |
||||
* have an outer location whose path refers to the "extensions" repeated |
||||
* field without an index. |
||||
* - Multiple locations may have the same path. This happens when a single |
||||
* logical declaration is spread out across multiple places. The most |
||||
* obvious example is the "extend" block again -- there may be multiple |
||||
* extend blocks in the same scope, each of which will have the same path. |
||||
* - A location's span is not always a subset of its parent's span. For |
||||
* example, the "extendee" of an extension declaration appears at the |
||||
* beginning of the "extend" block and is shared by all extensions within |
||||
* the block. |
||||
* - Just because a location's span is a subset of some other location's span |
||||
* does not mean that it is a descendent. For example, a "group" defines |
||||
* both a type and a field in a single declaration. Thus, the locations |
||||
* corresponding to the type and field and their components will overlap. |
||||
* - Code which tries to interpret locations should probably be designed to |
||||
* ignore those that it doesn't understand, as more types of locations could |
||||
* be recorded in the future. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.SourceCodeInfo.Location location = 1;</code> |
||||
*/ |
||||
private $location; |
||||
private $has_location = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* A Location identifies a piece of source code in a .proto file which |
||||
* corresponds to a particular definition. This information is intended |
||||
* to be useful to IDEs, code indexers, documentation generators, and similar |
||||
* tools. |
||||
* For example, say we have a file like: |
||||
* message Foo { |
||||
* optional string foo = 1; |
||||
* } |
||||
* Let's look at just the field definition: |
||||
* optional string foo = 1; |
||||
* ^ ^^ ^^ ^ ^^^ |
||||
* a bc de f ghi |
||||
* We have the following locations: |
||||
* span path represents |
||||
* [a,i) [ 4, 0, 2, 0 ] The whole field definition. |
||||
* [a,b) [ 4, 0, 2, 0, 4 ] The label (optional). |
||||
* [c,d) [ 4, 0, 2, 0, 5 ] The type (string). |
||||
* [e,f) [ 4, 0, 2, 0, 1 ] The name (foo). |
||||
* [g,h) [ 4, 0, 2, 0, 3 ] The number (1). |
||||
* Notes: |
||||
* - A location may refer to a repeated field itself (i.e. not to any |
||||
* particular index within it). This is used whenever a set of elements are |
||||
* logically enclosed in a single code segment. For example, an entire |
||||
* extend block (possibly containing multiple extension definitions) will |
||||
* have an outer location whose path refers to the "extensions" repeated |
||||
* field without an index. |
||||
* - Multiple locations may have the same path. This happens when a single |
||||
* logical declaration is spread out across multiple places. The most |
||||
* obvious example is the "extend" block again -- there may be multiple |
||||
* extend blocks in the same scope, each of which will have the same path. |
||||
* - A location's span is not always a subset of its parent's span. For |
||||
* example, the "extendee" of an extension declaration appears at the |
||||
* beginning of the "extend" block and is shared by all extensions within |
||||
* the block. |
||||
* - Just because a location's span is a subset of some other location's span |
||||
* does not mean that it is a descendent. For example, a "group" defines |
||||
* both a type and a field in a single declaration. Thus, the locations |
||||
* corresponding to the type and field and their components will overlap. |
||||
* - Code which tries to interpret locations should probably be designed to |
||||
* ignore those that it doesn't understand, as more types of locations could |
||||
* be recorded in the future. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.SourceCodeInfo.Location location = 1;</code> |
||||
*/ |
||||
public function getLocation() |
||||
{ |
||||
return $this->location; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* A Location identifies a piece of source code in a .proto file which |
||||
* corresponds to a particular definition. This information is intended |
||||
* to be useful to IDEs, code indexers, documentation generators, and similar |
||||
* tools. |
||||
* For example, say we have a file like: |
||||
* message Foo { |
||||
* optional string foo = 1; |
||||
* } |
||||
* Let's look at just the field definition: |
||||
* optional string foo = 1; |
||||
* ^ ^^ ^^ ^ ^^^ |
||||
* a bc de f ghi |
||||
* We have the following locations: |
||||
* span path represents |
||||
* [a,i) [ 4, 0, 2, 0 ] The whole field definition. |
||||
* [a,b) [ 4, 0, 2, 0, 4 ] The label (optional). |
||||
* [c,d) [ 4, 0, 2, 0, 5 ] The type (string). |
||||
* [e,f) [ 4, 0, 2, 0, 1 ] The name (foo). |
||||
* [g,h) [ 4, 0, 2, 0, 3 ] The number (1). |
||||
* Notes: |
||||
* - A location may refer to a repeated field itself (i.e. not to any |
||||
* particular index within it). This is used whenever a set of elements are |
||||
* logically enclosed in a single code segment. For example, an entire |
||||
* extend block (possibly containing multiple extension definitions) will |
||||
* have an outer location whose path refers to the "extensions" repeated |
||||
* field without an index. |
||||
* - Multiple locations may have the same path. This happens when a single |
||||
* logical declaration is spread out across multiple places. The most |
||||
* obvious example is the "extend" block again -- there may be multiple |
||||
* extend blocks in the same scope, each of which will have the same path. |
||||
* - A location's span is not always a subset of its parent's span. For |
||||
* example, the "extendee" of an extension declaration appears at the |
||||
* beginning of the "extend" block and is shared by all extensions within |
||||
* the block. |
||||
* - Just because a location's span is a subset of some other location's span |
||||
* does not mean that it is a descendent. For example, a "group" defines |
||||
* both a type and a field in a single declaration. Thus, the locations |
||||
* corresponding to the type and field and their components will overlap. |
||||
* - Code which tries to interpret locations should probably be designed to |
||||
* ignore those that it doesn't understand, as more types of locations could |
||||
* be recorded in the future. |
||||
* </pre> |
||||
* |
||||
* <code>repeated .google.protobuf.SourceCodeInfo.Location location = 1;</code> |
||||
*/ |
||||
public function setLocation(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\SourceCodeInfo_Location::class); |
||||
$this->location = $var; |
||||
$this->has_location = true; |
||||
} |
||||
|
||||
public function hasLocation() |
||||
{ |
||||
return $this->has_location; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,379 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>google.protobuf.SourceCodeInfo.Location</code> |
||||
*/ |
||||
class SourceCodeInfo_Location extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <pre> |
||||
* Identifies which part of the FileDescriptorProto was defined at this |
||||
* location. |
||||
* Each element is a field number or an index. They form a path from |
||||
* the root FileDescriptorProto to the place where the definition. For |
||||
* example, this path: |
||||
* [ 4, 3, 2, 7, 1 ] |
||||
* refers to: |
||||
* file.message_type(3) // 4, 3 |
||||
* .field(7) // 2, 7 |
||||
* .name() // 1 |
||||
* This is because FileDescriptorProto.message_type has field number 4: |
||||
* repeated DescriptorProto message_type = 4; |
||||
* and DescriptorProto.field has field number 2: |
||||
* repeated FieldDescriptorProto field = 2; |
||||
* and FieldDescriptorProto.name has field number 1: |
||||
* optional string name = 1; |
||||
* Thus, the above path gives the location of a field name. If we removed |
||||
* the last element: |
||||
* [ 4, 3, 2, 7 ] |
||||
* this path refers to the whole field declaration (from the beginning |
||||
* of the label to the terminating semicolon). |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 path = 1 [packed = true];</code> |
||||
*/ |
||||
private $path; |
||||
private $has_path = false; |
||||
/** |
||||
* <pre> |
||||
* Always has exactly three or four elements: start line, start column, |
||||
* end line (optional, otherwise assumed same as start line), end column. |
||||
* These are packed into a single field for efficiency. Note that line |
||||
* and column numbers are zero-based -- typically you will want to add |
||||
* 1 to each before displaying to a user. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 span = 2 [packed = true];</code> |
||||
*/ |
||||
private $span; |
||||
private $has_span = false; |
||||
/** |
||||
* <pre> |
||||
* If this SourceCodeInfo represents a complete declaration, these are any |
||||
* comments appearing before and after the declaration which appear to be |
||||
* attached to the declaration. |
||||
* A series of line comments appearing on consecutive lines, with no other |
||||
* tokens appearing on those lines, will be treated as a single comment. |
||||
* leading_detached_comments will keep paragraphs of comments that appear |
||||
* before (but not connected to) the current element. Each paragraph, |
||||
* separated by empty lines, will be one comment element in the repeated |
||||
* field. |
||||
* Only the comment content is provided; comment markers (e.g. //) are |
||||
* stripped out. For block comments, leading whitespace and an asterisk |
||||
* will be stripped from the beginning of each line other than the first. |
||||
* Newlines are included in the output. |
||||
* Examples: |
||||
* optional int32 foo = 1; // Comment attached to foo. |
||||
* // Comment attached to bar. |
||||
* optional int32 bar = 2; |
||||
* optional string baz = 3; |
||||
* // Comment attached to baz. |
||||
* // Another line attached to baz. |
||||
* // Comment attached to qux. |
||||
* // |
||||
* // Another line attached to qux. |
||||
* optional double qux = 4; |
||||
* // Detached comment for corge. This is not leading or trailing comments |
||||
* // to qux or corge because there are blank lines separating it from |
||||
* // both. |
||||
* // Detached comment for corge paragraph 2. |
||||
* optional string corge = 5; |
||||
* /* Block comment attached |
||||
* * to corge. Leading asterisks |
||||
* * will be removed. */ |
||||
* /* Block comment attached to |
||||
* * grault. */ |
||||
* optional int32 grault = 6; |
||||
* // ignored detached comments. |
||||
* </pre> |
||||
* |
||||
* <code>optional string leading_comments = 3;</code> |
||||
*/ |
||||
private $leading_comments = ''; |
||||
private $has_leading_comments = false; |
||||
/** |
||||
* <code>optional string trailing_comments = 4;</code> |
||||
*/ |
||||
private $trailing_comments = ''; |
||||
private $has_trailing_comments = false; |
||||
/** |
||||
* <code>repeated string leading_detached_comments = 6;</code> |
||||
*/ |
||||
private $leading_detached_comments; |
||||
private $has_leading_detached_comments = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies which part of the FileDescriptorProto was defined at this |
||||
* location. |
||||
* Each element is a field number or an index. They form a path from |
||||
* the root FileDescriptorProto to the place where the definition. For |
||||
* example, this path: |
||||
* [ 4, 3, 2, 7, 1 ] |
||||
* refers to: |
||||
* file.message_type(3) // 4, 3 |
||||
* .field(7) // 2, 7 |
||||
* .name() // 1 |
||||
* This is because FileDescriptorProto.message_type has field number 4: |
||||
* repeated DescriptorProto message_type = 4; |
||||
* and DescriptorProto.field has field number 2: |
||||
* repeated FieldDescriptorProto field = 2; |
||||
* and FieldDescriptorProto.name has field number 1: |
||||
* optional string name = 1; |
||||
* Thus, the above path gives the location of a field name. If we removed |
||||
* the last element: |
||||
* [ 4, 3, 2, 7 ] |
||||
* this path refers to the whole field declaration (from the beginning |
||||
* of the label to the terminating semicolon). |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 path = 1 [packed = true];</code> |
||||
*/ |
||||
public function getPath() |
||||
{ |
||||
return $this->path; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Identifies which part of the FileDescriptorProto was defined at this |
||||
* location. |
||||
* Each element is a field number or an index. They form a path from |
||||
* the root FileDescriptorProto to the place where the definition. For |
||||
* example, this path: |
||||
* [ 4, 3, 2, 7, 1 ] |
||||
* refers to: |
||||
* file.message_type(3) // 4, 3 |
||||
* .field(7) // 2, 7 |
||||
* .name() // 1 |
||||
* This is because FileDescriptorProto.message_type has field number 4: |
||||
* repeated DescriptorProto message_type = 4; |
||||
* and DescriptorProto.field has field number 2: |
||||
* repeated FieldDescriptorProto field = 2; |
||||
* and FieldDescriptorProto.name has field number 1: |
||||
* optional string name = 1; |
||||
* Thus, the above path gives the location of a field name. If we removed |
||||
* the last element: |
||||
* [ 4, 3, 2, 7 ] |
||||
* this path refers to the whole field declaration (from the beginning |
||||
* of the label to the terminating semicolon). |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 path = 1 [packed = true];</code> |
||||
*/ |
||||
public function setPath(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); |
||||
$this->path = $var; |
||||
$this->has_path = true; |
||||
} |
||||
|
||||
public function hasPath() |
||||
{ |
||||
return $this->has_path; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Always has exactly three or four elements: start line, start column, |
||||
* end line (optional, otherwise assumed same as start line), end column. |
||||
* These are packed into a single field for efficiency. Note that line |
||||
* and column numbers are zero-based -- typically you will want to add |
||||
* 1 to each before displaying to a user. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 span = 2 [packed = true];</code> |
||||
*/ |
||||
public function getSpan() |
||||
{ |
||||
return $this->span; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* Always has exactly three or four elements: start line, start column, |
||||
* end line (optional, otherwise assumed same as start line), end column. |
||||
* These are packed into a single field for efficiency. Note that line |
||||
* and column numbers are zero-based -- typically you will want to add |
||||
* 1 to each before displaying to a user. |
||||
* </pre> |
||||
* |
||||
* <code>repeated int32 span = 2 [packed = true];</code> |
||||
*/ |
||||
public function setSpan(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); |
||||
$this->span = $var; |
||||
$this->has_span = true; |
||||
} |
||||
|
||||
public function hasSpan() |
||||
{ |
||||
return $this->has_span; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If this SourceCodeInfo represents a complete declaration, these are any |
||||
* comments appearing before and after the declaration which appear to be |
||||
* attached to the declaration. |
||||
* A series of line comments appearing on consecutive lines, with no other |
||||
* tokens appearing on those lines, will be treated as a single comment. |
||||
* leading_detached_comments will keep paragraphs of comments that appear |
||||
* before (but not connected to) the current element. Each paragraph, |
||||
* separated by empty lines, will be one comment element in the repeated |
||||
* field. |
||||
* Only the comment content is provided; comment markers (e.g. //) are |
||||
* stripped out. For block comments, leading whitespace and an asterisk |
||||
* will be stripped from the beginning of each line other than the first. |
||||
* Newlines are included in the output. |
||||
* Examples: |
||||
* optional int32 foo = 1; // Comment attached to foo. |
||||
* // Comment attached to bar. |
||||
* optional int32 bar = 2; |
||||
* optional string baz = 3; |
||||
* // Comment attached to baz. |
||||
* // Another line attached to baz. |
||||
* // Comment attached to qux. |
||||
* // |
||||
* // Another line attached to qux. |
||||
* optional double qux = 4; |
||||
* // Detached comment for corge. This is not leading or trailing comments |
||||
* // to qux or corge because there are blank lines separating it from |
||||
* // both. |
||||
* // Detached comment for corge paragraph 2. |
||||
* optional string corge = 5; |
||||
* /* Block comment attached |
||||
* * to corge. Leading asterisks |
||||
* * will be removed. */ |
||||
* /* Block comment attached to |
||||
* * grault. */ |
||||
* optional int32 grault = 6; |
||||
* // ignored detached comments. |
||||
* </pre> |
||||
* |
||||
* <code>optional string leading_comments = 3;</code> |
||||
*/ |
||||
public function getLeadingComments() |
||||
{ |
||||
return $this->leading_comments; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* If this SourceCodeInfo represents a complete declaration, these are any |
||||
* comments appearing before and after the declaration which appear to be |
||||
* attached to the declaration. |
||||
* A series of line comments appearing on consecutive lines, with no other |
||||
* tokens appearing on those lines, will be treated as a single comment. |
||||
* leading_detached_comments will keep paragraphs of comments that appear |
||||
* before (but not connected to) the current element. Each paragraph, |
||||
* separated by empty lines, will be one comment element in the repeated |
||||
* field. |
||||
* Only the comment content is provided; comment markers (e.g. //) are |
||||
* stripped out. For block comments, leading whitespace and an asterisk |
||||
* will be stripped from the beginning of each line other than the first. |
||||
* Newlines are included in the output. |
||||
* Examples: |
||||
* optional int32 foo = 1; // Comment attached to foo. |
||||
* // Comment attached to bar. |
||||
* optional int32 bar = 2; |
||||
* optional string baz = 3; |
||||
* // Comment attached to baz. |
||||
* // Another line attached to baz. |
||||
* // Comment attached to qux. |
||||
* // |
||||
* // Another line attached to qux. |
||||
* optional double qux = 4; |
||||
* // Detached comment for corge. This is not leading or trailing comments |
||||
* // to qux or corge because there are blank lines separating it from |
||||
* // both. |
||||
* // Detached comment for corge paragraph 2. |
||||
* optional string corge = 5; |
||||
* /* Block comment attached |
||||
* * to corge. Leading asterisks |
||||
* * will be removed. */ |
||||
* /* Block comment attached to |
||||
* * grault. */ |
||||
* optional int32 grault = 6; |
||||
* // ignored detached comments. |
||||
* </pre> |
||||
* |
||||
* <code>optional string leading_comments = 3;</code> |
||||
*/ |
||||
public function setLeadingComments($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->leading_comments = $var; |
||||
$this->has_leading_comments = true; |
||||
} |
||||
|
||||
public function hasLeadingComments() |
||||
{ |
||||
return $this->has_leading_comments; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string trailing_comments = 4;</code> |
||||
*/ |
||||
public function getTrailingComments() |
||||
{ |
||||
return $this->trailing_comments; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string trailing_comments = 4;</code> |
||||
*/ |
||||
public function setTrailingComments($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->trailing_comments = $var; |
||||
$this->has_trailing_comments = true; |
||||
} |
||||
|
||||
public function hasTrailingComments() |
||||
{ |
||||
return $this->has_trailing_comments; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated string leading_detached_comments = 6;</code> |
||||
*/ |
||||
public function getLeadingDetachedComments() |
||||
{ |
||||
return $this->leading_detached_comments; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated string leading_detached_comments = 6;</code> |
||||
*/ |
||||
public function setLeadingDetachedComments(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); |
||||
$this->leading_detached_comments = $var; |
||||
$this->has_leading_detached_comments = true; |
||||
} |
||||
|
||||
public function hasLeadingDetachedComments() |
||||
{ |
||||
return $this->has_leading_detached_comments; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,246 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* A message representing a option the parser does not recognize. This only |
||||
* appears in options protos created by the compiler::Parser class. |
||||
* DescriptorPool resolves these when building Descriptor objects. Therefore, |
||||
* options protos in descriptor objects (e.g. returned by Descriptor::options(), |
||||
* or produced by Descriptor::CopyTo()) will never have UninterpretedOptions |
||||
* in them. |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.UninterpretedOption</code> |
||||
*/ |
||||
class UninterpretedOption extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>repeated .google.protobuf.UninterpretedOption.NamePart name = 2;</code> |
||||
*/ |
||||
private $name; |
||||
private $has_name = false; |
||||
/** |
||||
* <pre> |
||||
* The value of the uninterpreted option, in whatever type the tokenizer |
||||
* identified it as during parsing. Exactly one of these should be set. |
||||
* </pre> |
||||
* |
||||
* <code>optional string identifier_value = 3;</code> |
||||
*/ |
||||
private $identifier_value = ''; |
||||
private $has_identifier_value = false; |
||||
/** |
||||
* <code>optional uint64 positive_int_value = 4;</code> |
||||
*/ |
||||
private $positive_int_value = 0; |
||||
private $has_positive_int_value = false; |
||||
/** |
||||
* <code>optional int64 negative_int_value = 5;</code> |
||||
*/ |
||||
private $negative_int_value = 0; |
||||
private $has_negative_int_value = false; |
||||
/** |
||||
* <code>optional double double_value = 6;</code> |
||||
*/ |
||||
private $double_value = 0.0; |
||||
private $has_double_value = false; |
||||
/** |
||||
* <code>optional bytes string_value = 7;</code> |
||||
*/ |
||||
private $string_value = ''; |
||||
private $has_string_value = false; |
||||
/** |
||||
* <code>optional string aggregate_value = 8;</code> |
||||
*/ |
||||
private $aggregate_value = ''; |
||||
private $has_aggregate_value = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.UninterpretedOption.NamePart name = 2;</code> |
||||
*/ |
||||
public function getName() |
||||
{ |
||||
return $this->name; |
||||
} |
||||
|
||||
/** |
||||
* <code>repeated .google.protobuf.UninterpretedOption.NamePart name = 2;</code> |
||||
*/ |
||||
public function setName(&$var) |
||||
{ |
||||
GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption_NamePart::class); |
||||
$this->name = $var; |
||||
$this->has_name = true; |
||||
} |
||||
|
||||
public function hasName() |
||||
{ |
||||
return $this->has_name; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The value of the uninterpreted option, in whatever type the tokenizer |
||||
* identified it as during parsing. Exactly one of these should be set. |
||||
* </pre> |
||||
* |
||||
* <code>optional string identifier_value = 3;</code> |
||||
*/ |
||||
public function getIdentifierValue() |
||||
{ |
||||
return $this->identifier_value; |
||||
} |
||||
|
||||
/** |
||||
* <pre> |
||||
* The value of the uninterpreted option, in whatever type the tokenizer |
||||
* identified it as during parsing. Exactly one of these should be set. |
||||
* </pre> |
||||
* |
||||
* <code>optional string identifier_value = 3;</code> |
||||
*/ |
||||
public function setIdentifierValue($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->identifier_value = $var; |
||||
$this->has_identifier_value = true; |
||||
} |
||||
|
||||
public function hasIdentifierValue() |
||||
{ |
||||
return $this->has_identifier_value; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional uint64 positive_int_value = 4;</code> |
||||
*/ |
||||
public function getPositiveIntValue() |
||||
{ |
||||
return $this->positive_int_value; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional uint64 positive_int_value = 4;</code> |
||||
*/ |
||||
public function setPositiveIntValue($var) |
||||
{ |
||||
GPBUtil::checkUint64($var); |
||||
$this->positive_int_value = $var; |
||||
$this->has_positive_int_value = true; |
||||
} |
||||
|
||||
public function hasPositiveIntValue() |
||||
{ |
||||
return $this->has_positive_int_value; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional int64 negative_int_value = 5;</code> |
||||
*/ |
||||
public function getNegativeIntValue() |
||||
{ |
||||
return $this->negative_int_value; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional int64 negative_int_value = 5;</code> |
||||
*/ |
||||
public function setNegativeIntValue($var) |
||||
{ |
||||
GPBUtil::checkInt64($var); |
||||
$this->negative_int_value = $var; |
||||
$this->has_negative_int_value = true; |
||||
} |
||||
|
||||
public function hasNegativeIntValue() |
||||
{ |
||||
return $this->has_negative_int_value; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional double double_value = 6;</code> |
||||
*/ |
||||
public function getDoubleValue() |
||||
{ |
||||
return $this->double_value; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional double double_value = 6;</code> |
||||
*/ |
||||
public function setDoubleValue($var) |
||||
{ |
||||
GPBUtil::checkDouble($var); |
||||
$this->double_value = $var; |
||||
$this->has_double_value = true; |
||||
} |
||||
|
||||
public function hasDoubleValue() |
||||
{ |
||||
return $this->has_double_value; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional bytes string_value = 7;</code> |
||||
*/ |
||||
public function getStringValue() |
||||
{ |
||||
return $this->string_value; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional bytes string_value = 7;</code> |
||||
*/ |
||||
public function setStringValue($var) |
||||
{ |
||||
GPBUtil::checkString($var, False); |
||||
$this->string_value = $var; |
||||
$this->has_string_value = true; |
||||
} |
||||
|
||||
public function hasStringValue() |
||||
{ |
||||
return $this->has_string_value; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string aggregate_value = 8;</code> |
||||
*/ |
||||
public function getAggregateValue() |
||||
{ |
||||
return $this->aggregate_value; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional string aggregate_value = 8;</code> |
||||
*/ |
||||
public function setAggregateValue($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->aggregate_value = $var; |
||||
$this->has_aggregate_value = true; |
||||
} |
||||
|
||||
public function hasAggregateValue() |
||||
{ |
||||
return $this->has_aggregate_value; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,90 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/descriptor.proto |
||||
|
||||
namespace Google\Protobuf\Internal; |
||||
|
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\GPBWire; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\InputStream; |
||||
|
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* <pre> |
||||
* The name of the uninterpreted option. Each string represents a segment in |
||||
* a dot-separated name. is_extension is true iff a segment represents an |
||||
* extension (denoted with parentheses in options specs in .proto files). |
||||
* E.g.,{ ["foo", false], ["bar.baz", true], ["qux", false] } represents |
||||
* "foo.(bar.baz).qux". |
||||
* </pre> |
||||
* |
||||
* Protobuf type <code>google.protobuf.UninterpretedOption.NamePart</code> |
||||
*/ |
||||
class UninterpretedOption_NamePart extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>required string name_part = 1;</code> |
||||
*/ |
||||
private $name_part = ''; |
||||
private $has_name_part = false; |
||||
/** |
||||
* <code>required bool is_extension = 2;</code> |
||||
*/ |
||||
private $is_extension = false; |
||||
private $has_is_extension = false; |
||||
|
||||
public function __construct() { |
||||
\GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce(); |
||||
parent::__construct(); |
||||
} |
||||
|
||||
/** |
||||
* <code>required string name_part = 1;</code> |
||||
*/ |
||||
public function getNamePart() |
||||
{ |
||||
return $this->name_part; |
||||
} |
||||
|
||||
/** |
||||
* <code>required string name_part = 1;</code> |
||||
*/ |
||||
public function setNamePart($var) |
||||
{ |
||||
GPBUtil::checkString($var, True); |
||||
$this->name_part = $var; |
||||
$this->has_name_part = true; |
||||
} |
||||
|
||||
public function hasNamePart() |
||||
{ |
||||
return $this->has_name_part; |
||||
} |
||||
|
||||
/** |
||||
* <code>required bool is_extension = 2;</code> |
||||
*/ |
||||
public function getIsExtension() |
||||
{ |
||||
return $this->is_extension; |
||||
} |
||||
|
||||
/** |
||||
* <code>required bool is_extension = 2;</code> |
||||
*/ |
||||
public function setIsExtension($var) |
||||
{ |
||||
GPBUtil::checkBool($var); |
||||
$this->is_extension = $var; |
||||
$this->has_is_extension = true; |
||||
} |
||||
|
||||
public function hasIsExtension() |
||||
{ |
||||
return $this->has_is_extension; |
||||
} |
||||
|
||||
} |
||||
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,25 @@ |
||||
<?php |
||||
|
||||
function getGeneratedFiles($dir, &$results = array()) |
||||
{ |
||||
$files = scandir($dir); |
||||
|
||||
foreach ($files as $key => $value) { |
||||
$path = realpath($dir.DIRECTORY_SEPARATOR.$value); |
||||
if (!is_dir($path)) { |
||||
$results[] = $path; |
||||
} else if ($value != "." && $value != "..") { |
||||
getGeneratedFiles($path, $results); |
||||
} |
||||
} |
||||
return $results; |
||||
} |
||||
|
||||
foreach (getGeneratedFiles("generated") as $filename) |
||||
{ |
||||
if (!is_dir($filename)) { |
||||
include_once $filename; |
||||
} |
||||
|
||||
} |
||||
|
@ -0,0 +1,12 @@ |
||||
#!/bin/bash |
||||
|
||||
# gdb --args php -dextension=../ext/google/protobuf/modules/protobuf.so `which |
||||
# phpunit` --bootstrap autoload.php tmp_test.php |
||||
# |
||||
gdb --args php -dextension=../ext/google/protobuf/modules/protobuf.so `which phpunit` --bootstrap autoload.php encode_decode_test.php |
||||
# |
||||
# # gdb --args php -dextension=../ext/google/protobuf/modules/protobuf.so |
||||
# memory_leak_test.php |
||||
# |
||||
# # USE_ZEND_ALLOC=0 valgrind --leak-check=yes php |
||||
# -dextension=../ext/google/protobuf/modules/protobuf.so memory_leak_test.php |
@ -1,28 +0,0 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: google/protobuf/empty.proto |
||||
|
||||
namespace Google\Protobuf; |
||||
|
||||
use Google\Protobuf\Internal\DescriptorPool; |
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
class GPBEmpty extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
|
||||
} |
||||
|
||||
$pool = DescriptorPool::getGeneratedPool(); |
||||
|
||||
$pool->internalAddGeneratedFile(hex2bin( |
||||
"0ab7010a1b676f6f676c652f70726f746f6275662f656d7074792e70726f" . |
||||
"746f120f676f6f676c652e70726f746f62756622070a05456d7074794276" . |
||||
"0a13636f6d2e676f6f676c652e70726f746f627566420a456d7074795072" . |
||||
"6f746f50015a276769746875622e636f6d2f676f6c616e672f70726f746f" . |
||||
"6275662f7074797065732f656d707479f80101a20203475042aa021e476f" . |
||||
"6f676c652e50726f746f6275662e57656c6c4b6e6f776e54797065736206" . |
||||
"70726f746f33" |
||||
)); |
||||
|
@ -1,6 +1,6 @@ |
||||
syntax = "proto3"; |
||||
|
||||
import 'test_include.proto'; |
||||
import 'proto/test_include.proto'; |
||||
|
||||
package foo; |
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,48 +0,0 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: test_include.proto |
||||
|
||||
namespace Bar; |
||||
|
||||
use Google\Protobuf\Internal\DescriptorPool; |
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
/** |
||||
* Protobuf type <code>bar.TestInclude</code> |
||||
*/ |
||||
class TestInclude extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
/** |
||||
* <code>optional int32 a = 1;</code> |
||||
*/ |
||||
private $a = 0; |
||||
|
||||
/** |
||||
* <code>optional int32 a = 1;</code> |
||||
*/ |
||||
public function getA() |
||||
{ |
||||
return $this->a; |
||||
} |
||||
|
||||
/** |
||||
* <code>optional int32 a = 1;</code> |
||||
*/ |
||||
public function setA($var) |
||||
{ |
||||
GPBUtil::checkInt32($var); |
||||
$this->a = $var; |
||||
} |
||||
|
||||
} |
||||
|
||||
$pool = DescriptorPool::getGeneratedPool(); |
||||
|
||||
$pool->internalAddGeneratedFile(hex2bin( |
||||
"0a3b0a12746573745f696e636c7564652e70726f746f120362617222180a" . |
||||
"0b54657374496e636c75646512090a0161180120012805620670726f746f" . |
||||
"33" |
||||
)); |
||||
|
@ -1,34 +0,0 @@ |
||||
<?php |
||||
# Generated by the protocol buffer compiler. DO NOT EDIT! |
||||
# source: test_no_namespace.proto |
||||
|
||||
use Google\Protobuf\Internal\DescriptorPool; |
||||
use Google\Protobuf\Internal\GPBType; |
||||
use Google\Protobuf\Internal\RepeatedField; |
||||
use Google\Protobuf\Internal\GPBUtil; |
||||
|
||||
class NoNameSpace extends \Google\Protobuf\Internal\Message |
||||
{ |
||||
private $a = 0; |
||||
|
||||
public function getA() |
||||
{ |
||||
return $this->a; |
||||
} |
||||
|
||||
public function setA($var) |
||||
{ |
||||
GPBUtil::checkInt32($var); |
||||
$this->a = $var; |
||||
} |
||||
|
||||
} |
||||
|
||||
$pool = DescriptorPool::getGeneratedPool(); |
||||
|
||||
$pool->internalAddGeneratedFile(hex2bin( |
||||
"0a3b0a17746573745f6e6f5f6e616d6573706163652e70726f746f22180a" . |
||||
"0b4e6f4e616d65537061636512090a0161180120012805620670726f746f" . |
||||
"33" |
||||
)); |
||||
|
@ -1,14 +0,0 @@ |
||||
<?xml version="1.0" encoding="UTF-8"?> |
||||
<phpunit bootstrap="./vendor/autoload.php" |
||||
colors="true"> |
||||
<testsuites> |
||||
<testsuite name="protobuf-tests"> |
||||
<file>php/tests/php_implementation_test.php</file> |
||||
<file>php/tests/array_test.php</file> |
||||
<file>php/tests/encode_decode_test.php</file> |
||||
<file>php/tests/generated_class_test.php</file> |
||||
<file>php/tests/map_field_test.php</file> |
||||
<file>php/tests/well_known_test.php</file> |
||||
</testsuite> |
||||
</testsuites> |
||||
</phpunit> |
Loading…
Reference in new issue