aboutsummaryrefslogtreecommitdiff
path: root/php/ext/google/protobuf/message.c
diff options
context:
space:
mode:
authorPaul Yang <TeBoring@users.noreply.github.com>2017-03-08 14:31:34 -0800
committerGitHub <noreply@github.com>2017-03-08 14:31:34 -0800
commitdd8d5f57d7068080283c2c03af01d806efbe6cf4 (patch)
treecbb2cb26804889ddfe61094044faaa6be4a47a12 /php/ext/google/protobuf/message.c
parent2b7430d96aeff2bb624c8d52182ff5e4b9f7f18a (diff)
downloadprotobuf-dd8d5f57d7068080283c2c03af01d806efbe6cf4.tar.gz
protobuf-dd8d5f57d7068080283c2c03af01d806efbe6cf4.tar.bz2
protobuf-dd8d5f57d7068080283c2c03af01d806efbe6cf4.zip
Rename encode/decode to serializeToString/mergeFromString (#2795)
This better shows the semantic of the API. For already setted fields, mergeFromString do replacement for singular fields and appending for repeated fields.
Diffstat (limited to 'php/ext/google/protobuf/message.c')
-rw-r--r--php/ext/google/protobuf/message.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/php/ext/google/protobuf/message.c b/php/ext/google/protobuf/message.c
index b35df311..59ce6ae6 100644
--- a/php/ext/google/protobuf/message.c
+++ b/php/ext/google/protobuf/message.c
@@ -39,8 +39,8 @@ zend_object_handlers* message_handlers;
static zend_function_entry message_methods[] = {
PHP_ME(Message, clear, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Message, encode, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Message, decode, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Message, serializeToString, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Message, mergeFromString, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Message, jsonEncode, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Message, jsonDecode, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Message, mergeFrom, NULL, ZEND_ACC_PUBLIC)