descriptor_pool_test1.proto 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. // Protocol Buffers - Google's data interchange format
  2. // Copyright 2008 Google Inc. All rights reserved.
  3. // http://code.google.com/p/protobuf/
  4. //
  5. // Redistribution and use in source and binary forms, with or without
  6. // modification, are permitted provided that the following conditions are
  7. // met:
  8. //
  9. // * Redistributions of source code must retain the above copyright
  10. // notice, this list of conditions and the following disclaimer.
  11. // * Redistributions in binary form must reproduce the above
  12. // copyright notice, this list of conditions and the following disclaimer
  13. // in the documentation and/or other materials provided with the
  14. // distribution.
  15. // * Neither the name of Google Inc. nor the names of its
  16. // contributors may be used to endorse or promote products derived from
  17. // this software without specific prior written permission.
  18. //
  19. // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  20. // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  21. // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
  22. // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
  23. // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  24. // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  25. // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  26. // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  27. // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  28. // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  29. // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  30. package google.protobuf.python.internal;
  31. message DescriptorPoolTest1 {
  32. extensions 1000 to max;
  33. enum NestedEnum {
  34. ALPHA = 1;
  35. BETA = 2;
  36. }
  37. optional NestedEnum nested_enum = 1 [default = BETA];
  38. message NestedMessage {
  39. enum NestedEnum {
  40. EPSILON = 5;
  41. ZETA = 6;
  42. }
  43. optional NestedEnum nested_enum = 1 [default = ZETA];
  44. optional string nested_field = 2 [default = "beta"];
  45. optional DeepNestedMessage deep_nested_message = 3;
  46. message DeepNestedMessage {
  47. enum NestedEnum {
  48. ETA = 7;
  49. THETA = 8;
  50. }
  51. optional NestedEnum nested_enum = 1 [default = ETA];
  52. optional string nested_field = 2 [default = "theta"];
  53. }
  54. }
  55. optional NestedMessage nested_message = 2;
  56. }
  57. message DescriptorPoolTest2 {
  58. enum NestedEnum {
  59. GAMMA = 3;
  60. DELTA = 4;
  61. }
  62. optional NestedEnum nested_enum = 1 [default = GAMMA];
  63. message NestedMessage {
  64. enum NestedEnum {
  65. IOTA = 9;
  66. KAPPA = 10;
  67. }
  68. optional NestedEnum nested_enum = 1 [default = IOTA];
  69. optional string nested_field = 2 [default = "delta"];
  70. optional DeepNestedMessage deep_nested_message = 3;
  71. message DeepNestedMessage {
  72. enum NestedEnum {
  73. LAMBDA = 11;
  74. MU = 12;
  75. }
  76. optional NestedEnum nested_enum = 1 [default = MU];
  77. optional string nested_field = 2 [default = "lambda"];
  78. }
  79. }
  80. optional NestedMessage nested_message = 2;
  81. }