aboutsummaryrefslogtreecommitdiff
path: root/protos
diff options
context:
space:
mode:
authorJon Skeet <skeet@pobox.com>2008-11-13 22:29:48 +0000
committerJon Skeet <skeet@pobox.com>2008-11-13 22:29:48 +0000
commit1d131c98f058dc0b5e0ebef73602e09dc88fe075 (patch)
treee94ff4c7383c557902ec5eb63b8889dda24e3bd7 /protos
parentd6343be707cb6a067fe2b5ccc2efd7848072d17c (diff)
downloadprotobuf-1d131c98f058dc0b5e0ebef73602e09dc88fe075.tar.gz
protobuf-1d131c98f058dc0b5e0ebef73602e09dc88fe075.tar.bz2
protobuf-1d131c98f058dc0b5e0ebef73602e09dc88fe075.zip
New options now work fine.
Diffstat (limited to 'protos')
-rw-r--r--protos/google/protobuf/csharp_options.proto19
-rw-r--r--protos/google/protobuf/unittest.proto4
-rw-r--r--protos/google/protobuf/unittest_custom_options.proto4
-rw-r--r--protos/google/protobuf/unittest_embed_optimize_for.proto4
-rw-r--r--protos/google/protobuf/unittest_import.proto4
-rw-r--r--protos/google/protobuf/unittest_mset.proto4
-rw-r--r--protos/google/protobuf/unittest_optimize_for.proto4
7 files changed, 24 insertions, 19 deletions
diff --git a/protos/google/protobuf/csharp_options.proto b/protos/google/protobuf/csharp_options.proto
index 6d81c5cd..29c7e8ad 100644
--- a/protos/google/protobuf/csharp_options.proto
+++ b/protos/google/protobuf/csharp_options.proto
@@ -10,16 +10,21 @@ message CSharpFileOptions {
optional bool public_classes = 3;
optional bool multiple_files = 4;
optional bool nest_classes = 5;
+}
+
+extend FileOptions {
+ optional CSharpFileOptions csharp_file_options = 1000;
+}
- extend FileOptions {
- optional CSharpFileOptions csharp_options = 1000;
- }
+extend FieldOptions {
+ optional CSharpFieldOptions csharp_field_options = 1000;
}
message CSharpFieldOptions {
+ // Provides the ability to override the name of the property
+ // generated for this field. This does not currently work with
+ // messages optimised for reflection, and is only applied to the
+ // actual property rather than associated methods. (Careful
+ // consideration needed here...)
optional string property_name = 1;
-
- extend FieldOptions {
- optional CSharpFieldOptions csharp_options = 1000;
- }
}
diff --git a/protos/google/protobuf/unittest.proto b/protos/google/protobuf/unittest.proto
index 45ee42b1..443ba782 100644
--- a/protos/google/protobuf/unittest.proto
+++ b/protos/google/protobuf/unittest.proto
@@ -2,8 +2,8 @@
// line onwards is as per original distribution.
import "google/protobuf/csharp_options.proto";
import "google/protobuf/descriptor.proto";
-option (google.protobuf.CSharpFileOptions.csharp_options).namespace = "Google.ProtocolBuffers.TestProtos";
-option (google.protobuf.CSharpFileOptions.csharp_options).umbrella_classname = "UnitTestProtoFile";
+option (google.protobuf.csharp_file_options).namespace = "Google.ProtocolBuffers.TestProtos";
+option (google.protobuf.csharp_file_options).umbrella_classname = "UnitTestProtoFile";
// Protocol Buffers - Google's data interchange format
// Copyright 2008 Google Inc. All rights reserved.
diff --git a/protos/google/protobuf/unittest_custom_options.proto b/protos/google/protobuf/unittest_custom_options.proto
index 44525279..49b578f4 100644
--- a/protos/google/protobuf/unittest_custom_options.proto
+++ b/protos/google/protobuf/unittest_custom_options.proto
@@ -1,8 +1,8 @@
// Additional options required for C# generation. File from copyright
// line onwards is as per original distribution.
import "google/protobuf/csharp_options.proto";
-option (google.protobuf.CSharpFileOptions.csharp_options).namespace = "Google.ProtocolBuffers.TestProtos";
-option (google.protobuf.CSharpFileOptions.csharp_options).umbrella_classname = "UnitTestCustomOptionsProtoFile";
+option (google.protobuf.csharp_file_options).namespace = "Google.ProtocolBuffers.TestProtos";
+option (google.protobuf.csharp_file_options).umbrella_classname = "UnitTestCustomOptionsProtoFile";
// Protocol Buffers - Google's data interchange format
// Copyright 2008 Google Inc. All rights reserved.
diff --git a/protos/google/protobuf/unittest_embed_optimize_for.proto b/protos/google/protobuf/unittest_embed_optimize_for.proto
index 9ab1092a..830df8fa 100644
--- a/protos/google/protobuf/unittest_embed_optimize_for.proto
+++ b/protos/google/protobuf/unittest_embed_optimize_for.proto
@@ -2,8 +2,8 @@
// line onwards is as per original distribution.
import "google/protobuf/csharp_options.proto";
import "google/protobuf/descriptor.proto";
-option (google.protobuf.CSharpFileOptions.csharp_options).namespace = "Google.ProtocolBuffers.TestProtos";
-option (google.protobuf.CSharpFileOptions.csharp_options).umbrella_classname = "UnitTestEmbedOptimizeForProtoFile";
+option (google.protobuf.csharp_file_options).namespace = "Google.ProtocolBuffers.TestProtos";
+option (google.protobuf.csharp_file_options).umbrella_classname = "UnitTestEmbedOptimizeForProtoFile";
// Protocol Buffers - Google's data interchange format
// Copyright 2008 Google Inc. All rights reserved.
diff --git a/protos/google/protobuf/unittest_import.proto b/protos/google/protobuf/unittest_import.proto
index 7af5b74c..bdabcc69 100644
--- a/protos/google/protobuf/unittest_import.proto
+++ b/protos/google/protobuf/unittest_import.proto
@@ -2,8 +2,8 @@
// line onwards is as per original distribution.
import "google/protobuf/csharp_options.proto";
import "google/protobuf/descriptor.proto";
-option (google.protobuf.CSharpFileOptions.csharp_options).namespace = "Google.ProtocolBuffers.TestProtos";
-option (google.protobuf.CSharpFileOptions.csharp_options).umbrella_classname = "UnitTestImportProtoFile";
+option (google.protobuf.csharp_file_options).namespace = "Google.ProtocolBuffers.TestProtos";
+option (google.protobuf.csharp_file_options).umbrella_classname = "UnitTestImportProtoFile";
// Protocol Buffers - Google's data interchange format
// Copyright 2008 Google Inc. All rights reserved.
diff --git a/protos/google/protobuf/unittest_mset.proto b/protos/google/protobuf/unittest_mset.proto
index 74f30021..60d68eb9 100644
--- a/protos/google/protobuf/unittest_mset.proto
+++ b/protos/google/protobuf/unittest_mset.proto
@@ -2,8 +2,8 @@
// line onwards is as per original distribution.
import "google/protobuf/csharp_options.proto";
import "google/protobuf/descriptor.proto";
-option (google.protobuf.CSharpFileOptions.csharp_options).namespace = "Google.ProtocolBuffers.TestProtos";
-option (google.protobuf.CSharpFileOptions.csharp_options).umbrella_classname = "UnitTestMessageSetProtoFile";
+option (google.protobuf.csharp_file_options).namespace = "Google.ProtocolBuffers.TestProtos";
+option (google.protobuf.csharp_file_options).umbrella_classname = "UnitTestMessageSetProtoFile";
// Protocol Buffers - Google's data interchange format
// Copyright 2008 Google Inc. All rights reserved.
diff --git a/protos/google/protobuf/unittest_optimize_for.proto b/protos/google/protobuf/unittest_optimize_for.proto
index 204d09f9..8f66c5e0 100644
--- a/protos/google/protobuf/unittest_optimize_for.proto
+++ b/protos/google/protobuf/unittest_optimize_for.proto
@@ -2,8 +2,8 @@
// line onwards is as per original distribution.
import "google/protobuf/csharp_options.proto";
import "google/protobuf/descriptor.proto";
-option (google.protobuf.CSharpFileOptions.csharp_options).namespace = "Google.ProtocolBuffers.TestProtos";
-option (google.protobuf.CSharpFileOptions.csharp_options).umbrella_classname = "UnitTestOptimizeForProtoFile";
+option (google.protobuf.csharp_file_options).namespace = "Google.ProtocolBuffers.TestProtos";
+option (google.protobuf.csharp_file_options).umbrella_classname = "UnitTestOptimizeForProtoFile";
// Protocol Buffers - Google's data interchange format
// Copyright 2008 Google Inc. All rights reserved.