| OLD | NEW |
| 1 // Protocol Buffers - Google's data interchange format | 1 // Protocol Buffers - Google's data interchange format |
| 2 // Copyright 2008 Google Inc. All rights reserved. | 2 // Copyright 2008 Google Inc. All rights reserved. |
| 3 // https://developers.google.com/protocol-buffers/ | 3 // https://developers.google.com/protocol-buffers/ |
| 4 // | 4 // |
| 5 // Redistribution and use in source and binary forms, with or without | 5 // Redistribution and use in source and binary forms, with or without |
| 6 // modification, are permitted provided that the following conditions are | 6 // modification, are permitted provided that the following conditions are |
| 7 // met: | 7 // met: |
| 8 // | 8 // |
| 9 // * Redistributions of source code must retain the above copyright | 9 // * Redistributions of source code must retain the above copyright |
| 10 // notice, this list of conditions and the following disclaimer. | 10 // notice, this list of conditions and the following disclaimer. |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 // See descriptor_containers.cc for more description. | 36 // See descriptor_containers.cc for more description. |
| 37 #include <Python.h> | 37 #include <Python.h> |
| 38 | 38 |
| 39 namespace google { | 39 namespace google { |
| 40 namespace protobuf { | 40 namespace protobuf { |
| 41 | 41 |
| 42 class Descriptor; | 42 class Descriptor; |
| 43 class FileDescriptor; | 43 class FileDescriptor; |
| 44 class EnumDescriptor; | 44 class EnumDescriptor; |
| 45 class OneofDescriptor; | 45 class OneofDescriptor; |
| 46 class ServiceDescriptor; |
| 46 | 47 |
| 47 namespace python { | 48 namespace python { |
| 48 | 49 |
| 49 // Initialize the various types and objects. | 50 // Initialize the various types and objects. |
| 50 bool InitDescriptorMappingTypes(); | 51 bool InitDescriptorMappingTypes(); |
| 51 | 52 |
| 52 // Each function below returns a Mapping, or a Sequence of descriptors. | 53 // Each function below returns a Mapping, or a Sequence of descriptors. |
| 53 // They all return a new reference. | 54 // They all return a new reference. |
| 54 | 55 |
| 55 namespace message_descriptor { | 56 namespace message_descriptor { |
| (...skipping 26 matching lines...) Expand all Loading... |
| 82 PyObject* NewOneofFieldsSeq(const OneofDescriptor* descriptor); | 83 PyObject* NewOneofFieldsSeq(const OneofDescriptor* descriptor); |
| 83 } // namespace oneof_descriptor | 84 } // namespace oneof_descriptor |
| 84 | 85 |
| 85 namespace file_descriptor { | 86 namespace file_descriptor { |
| 86 PyObject* NewFileMessageTypesByName(const FileDescriptor* descriptor); | 87 PyObject* NewFileMessageTypesByName(const FileDescriptor* descriptor); |
| 87 | 88 |
| 88 PyObject* NewFileEnumTypesByName(const FileDescriptor* descriptor); | 89 PyObject* NewFileEnumTypesByName(const FileDescriptor* descriptor); |
| 89 | 90 |
| 90 PyObject* NewFileExtensionsByName(const FileDescriptor* descriptor); | 91 PyObject* NewFileExtensionsByName(const FileDescriptor* descriptor); |
| 91 | 92 |
| 93 PyObject* NewFileServicesByName(const FileDescriptor* descriptor); |
| 94 |
| 92 PyObject* NewFileDependencies(const FileDescriptor* descriptor); | 95 PyObject* NewFileDependencies(const FileDescriptor* descriptor); |
| 93 PyObject* NewFilePublicDependencies(const FileDescriptor* descriptor); | 96 PyObject* NewFilePublicDependencies(const FileDescriptor* descriptor); |
| 94 } // namespace file_descriptor | 97 } // namespace file_descriptor |
| 95 | 98 |
| 99 namespace service_descriptor { |
| 100 PyObject* NewServiceMethodsSeq(const ServiceDescriptor* descriptor); |
| 101 PyObject* NewServiceMethodsByName(const ServiceDescriptor* descriptor); |
| 102 } // namespace service_descriptor |
| 103 |
| 96 | 104 |
| 97 } // namespace python | 105 } // namespace python |
| 98 } // namespace protobuf | 106 } // namespace protobuf |
| 99 | 107 |
| 100 } // namespace google | 108 } // namespace google |
| 101 #endif // GOOGLE_PROTOBUF_PYTHON_CPP_DESCRIPTOR_CONTAINERS_H__ | 109 #endif // GOOGLE_PROTOBUF_PYTHON_CPP_DESCRIPTOR_CONTAINERS_H__ |
| OLD | NEW |