aboutsummaryrefslogtreecommitdiff
path: root/php/src
Commit message (Collapse)AuthorAgeFilesLines
* Adopt upb change for timestamp and duration json to php (#5106)Paul Yang2018-09-222-4/+12
| | | | | | | | | | | | | | | | | | | | | | | | | * Adopt upb change for timestamp and duration json to php * Remove unused code * Re-sync upb * Fix php implementation timestamp json parsing * Fix strptime use local timezone on mac. * Remove succeeding tests * Resync * Add tests for values * Fix php tests * Fix encoder handlers change default value Previously, oneofsubmsg_handler and submsg_handler change zval's default value directly. The fix use REPLACE_ZVAL_VALUE which create a copy of parsed value and assign it to zval.
* Update generated descriptors.integrationFeng Xiao2018-08-0812-0/+192
|
* php: Added nanosecond support for Timestamp (#3972)Leonard Hecker2018-07-201-4/+5
| | | | | | * php: Added nanosecond support for Timestamp * php: Fixed compatibility test
* Fix 32bit php testsBo Yang2018-07-132-18/+23
|
* Fix php testsBo Yang2018-07-131-5/+2
|
* add JSON_UNESCAPED_UNICODE option (#4191)吕海涛2018-07-092-2/+2
|
* Merge branch '3.6.x' into merge-3-6-xAdam Cozzette2018-06-256-6/+104
|\
| * Use legacy name in php runtime (#4741)v3.6.0.1Paul Yang2018-06-076-6/+101
| | | | | | | | | | | | | | | | | | * Use legacy name in php runtime Old generated code cannot work with new runtime, because the new runtime assumes new class name for nested message. For details see #4738. * Remove unused method
| * PHP namespaces for nested messages and enums (#4536)Brent Shaffer2018-05-2552-287/+806
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * uses namespaces for nested messages and enums * fixes namespaces for PHP dist * fixes namespace for Descriptors, adds Cardinality and Kind * fixes nested namespaces for reserved words and adds tests * adds tests and generator fix for php class prefixes * fixes escaping of protobuf packages, enum comments, misc others * nice refactor of generated code * adds class files for backwards compatibility * simplifies code with templates * adds compatibility files to makefile * cleanup of generator and fixes nested namespace bug * regenerates proto types * remove internal BC classes * adds deprecated warning, adds methods back * simplifies if statement * fixes dist files * addresses review comments * adds back TYPE_URL_PREFIX constant * adds @deprecated to old nested class files * skips tests which require a separate process when protobuf.so is enabled * Adds tests for legacy nested classes that do not require separate processes to test * uses legacy names for GPBUtil message check * adds block for IDE @deprecated message * Namespace for nested message/enum in c extension * Remove unused code
| * PHP array constructors for protobuf messages (#4530)Brent Shaffer2018-05-2528-152/+875
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PHP array constructors for protobuf messages * removes Descriptor from error message * allows mergeFrom to accept an array * only use initWithDescriptor if instanceof MapEntry * adds doc comments * removes ability for constructors to take arrays for submessages * Revert "allows mergeFrom to accept an array" This reverts commit b7b72182d561634af12c5c5c56a7cda3b33241f9. * makes mergeFromArray protected and fixes mergeFrom whitespace * Separates merging from JSON and merging from PHP array * removes well-known types and json keys from array construction * Addresses PR review comments * cleans up tests * fixes exception messages
* | PHP namespaces for nested messages and enums (#4536)Brent Shaffer2018-05-2452-287/+806
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * uses namespaces for nested messages and enums * fixes namespaces for PHP dist * fixes namespace for Descriptors, adds Cardinality and Kind * fixes nested namespaces for reserved words and adds tests * adds tests and generator fix for php class prefixes * fixes escaping of protobuf packages, enum comments, misc others * nice refactor of generated code * adds class files for backwards compatibility * simplifies code with templates * adds compatibility files to makefile * cleanup of generator and fixes nested namespace bug * regenerates proto types * remove internal BC classes * adds deprecated warning, adds methods back * simplifies if statement * fixes dist files * addresses review comments * adds back TYPE_URL_PREFIX constant * adds @deprecated to old nested class files * skips tests which require a separate process when protobuf.so is enabled * Adds tests for legacy nested classes that do not require separate processes to test * uses legacy names for GPBUtil message check * adds block for IDE @deprecated message * Namespace for nested message/enum in c extension * Remove unused code
* | PHP array constructors for protobuf messages (#4530)Brent Shaffer2018-05-2428-152/+875
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PHP array constructors for protobuf messages * removes Descriptor from error message * allows mergeFrom to accept an array * only use initWithDescriptor if instanceof MapEntry * adds doc comments * removes ability for constructors to take arrays for submessages * Revert "allows mergeFrom to accept an array" This reverts commit b7b72182d561634af12c5c5c56a7cda3b33241f9. * makes mergeFromArray protected and fixes mergeFrom whitespace * Separates merging from JSON and merging from PHP array * removes well-known types and json keys from array construction * Addresses PR review comments * cleans up tests * fixes exception messages
* | Updated PHP generated code for timestamp.protoAdam Cozzette2018-05-171-3/+5
|/
* Add file option php_metadata_namespace and ruby_package (#4609)Paul Yang2018-05-112-0/+92
|
* Avoid direct check of class name (#4601)Paul Yang2018-05-101-7/+3
| | | | | | | | * Avoid direct check of class name So that subclasses are also ok * Use type hint in function signature.
* Add space between class name and concat message (#4577)Petar Dambovaliev2018-04-301-1/+1
| | | | The class name was linked to the next word in the sentence. "User\UserRequestis not found in descriptor pool."
* fix json_decode call parameters (#4381)urfinjuezz2018-04-091-1/+1
|
* includes the expected class in the exception, otherwise the error is harder ↵Brent Shaffer2018-04-091-1/+1
| | | | to track down (#3371)
* Add backslach to make class explict in global namespaceBo Yang2017-12-111-1/+1
|
* Recursively clear unknown fields in submessages. (#3982)Paul Yang2017-12-071-0/+28
| | | | | | | | | | | | | | * Recursively clear unknown fields in submessages. * Recursively discard unknown fields in submsg for c extension * Fix zts build * Add comment for tests * Add a TODO to add a util for encoding varint for better readability. * Add test for oneof message field.
* Provide discardUnknonwnFields API in php (#3976)Paul Yang2017-11-301-0/+9
| | | | | | * Provide discardUnknownFields API in php implementation * Provide discardUnknownFields API in php c extension.
* Use fully qualifed name for DescriptorPool in Any.php to avoid name (#3886)Paul Yang2017-11-151-4/+3
| | | conflict
* All integer types should accept null in json. (#3869)Paul Yang2017-11-131-5/+6
|
* Fix php well known type conformance tests (#3828) (#3840)Paul Yang2017-11-044-47/+433
| | | | | | | | | | | | | | | * Fix php well known type conformance tests * Properly generate code for test.proto * Provide GPBMetadata files in c extensions for generated files to import. * Remove unnecessary test * Clean up code * Add declaration for initOnce. * Refactoring
* update joda-time javadoc urlxuwei-k2017-10-301-1/+1
|
* Update descriptor protosJisi Liu2017-10-181-3/+6
|
* Merge remote-tracking branch 'origin/3.4.x' into masterJisi Liu2017-10-113-8/+196
|\
| * Change array to associate array.Bo Yang2017-09-111-20/+21
| |
| * Add prefix to php reserved keywords.Bo Yang2017-09-081-2/+16
| |
| * change the field number of php_generic_service to fix the conflict with (#3576)Paul Yang2017-08-303-4/+68
| | | | | | internal descriptor.proto
* | Reserve unknown fields in php (#3659)Paul Yang2017-10-093-8/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Reserve unknown fields in upb 1) For decoding, an unknownfields will be lazily created on message, which contains bytes of unknown fields. 2) For encoding, if the unknownfields is present on message, all bytes contained in it will be serialized. * Register the function to encode unknown field at decode time. * Remove upb_handlers_setaddunknown * Use upb_sink_putunknown in decoder * Remove upb_pb_encoder_encode_unknown * Do not expose encode_unknown * Implement reserve unknown field in php Implement. * Make buffer private to CodedInputStream
* | Add well known types to php runtime. (#3697)Paul Yang2017-10-0534-0/+3353
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add well known types to php runtime. * Fix php7.0 tests * No longer generate empty.proto in test as it has been included in runtime. * Fix zts build * Clean code * Rename g_p_b_empty to empty. * Don't generate code for empty.proto in compatibility test * Fix 32-bit * Fix mac build * Fix Makefile.am to add new files
* | Enforce all error report for php tests. (#3670)Paul Yang2017-09-221-4/+16
| | | | | | | | | | | | * Enforce all error report for php tests. * Import vendor/autoload.php in tests/bootstrap_phpunit.php
* | Add $ before url_prefix_len to make it a variable. (#3668)Paul Yang2017-09-201-4/+2
| | | | | | | | | | | | | | | | * Add $ before url_prefix_len to make it a variable. * Remove unnecessary string length check * Remove useless $type_url_len
* | Integrated internal changes from GoogleAdam Cozzette2017-09-143-4/+98
| |
* | Add well-known timestamps to JSON for PHP (#3564)Jack Wakefield2017-09-103-31/+142
| |
* | Add native php support for Duration. (#3583)Paul Yang2017-09-052-0/+184
| |
* | Add php support for Timestamp. (#3575)Paul Yang2017-08-312-0/+215
| | | | | | | | | | | | * Add php support for Timestamp. * Fix comments
* | Add any support in php runtime. (#3486)Paul Yang2017-08-252-0/+304
|/ | | | | | | | | | | | * Add any support in php runtime. * Remove unused file in config.m4 * Fix comments * Fix error for tsrmls build * Add newly added file to Makefile.am
* Use message name as defined in php runtime.Bo Yang2017-08-212-1/+4
|
* Merge branch 'master' into 3.4.xBo Yang2017-08-0517-26/+616
|\
| * Update PHP descriptors (#3391)michaelbausor2017-08-0413-12/+604
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add descriptors test * Update descriptors tests * Add public descriptors * Add test_desriptors.proto to test script * Update composer files * Remove references to GPBType, update tests to be compatible with c * Update for c extension compatibility * Remove nested enums for descriptor, update tests * Strip leading '.' from descriptor name * Update tests with test for getClass, fix OneofDescriptor * Add new files to Makefile.am
| * Fixing HHVM Compatibility (#3437)Ryan Gordon2017-08-021-4/+2
| |
| * Change divideInt64ToInt32 to static (#3436)Tony Wong2017-08-011-1/+1
| | | | | | | | | | divideInt64ToInt32 is called statically from protobuf/php/src/Google/Protobuf/Internal/CodedOutputStream.php (the only reference) This causes fatal error in PHP 7.1 (32-bit only because 64-bit doesn't use this function)
| * Removes unnecessary pass-by-references in PHP internal classes (#3433)Brent Shaffer2017-08-013-10/+10
| |
| * compiles removal of newline (#3333) (#3370)Brent Shaffer2017-07-1925-25/+0
| |
* | Merge master into 3.4.xJisi Liu2017-07-1851-1865/+3293
|\|
| * Support PHP generic services (#3269)Matt A2017-07-182-0/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add php_generic_services option * Generate PHP generic services * Respect namespaces for generated PHP services * Test PHP generated services * Rename PHP generator service method doc comment function * Correct phpdoc service method case * Test namespaced PHP generic services * Always use the FQCN for PHP generic service input/output * Add generated_service_test to php test.sh * Add php service test protos to CI * Add php service files to php_EXTRA_DIST * Use Interface suffix for php generic services
| * remove pass by reference for php setters (#3344)Brent Shaffer2017-07-1722-42/+42
| | | | | | | | | | | | * remove pass by reference for php setters * comments out memory leak test
| * Add map iterator for c extension (#3350)Paul Yang2017-07-131-1/+4
| |