blob: 52d3349b40ad2ebcb00b4ec523b0be880575be36 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
using System;
using System.Collections.Generic;
using System.Text;
using Google.ProtocolBuffers.Descriptors;
namespace Google.ProtocolBuffers {
/// <summary>
/// Base class for all generated extensions.
/// </summary>
/// <remarks>
/// The protocol compiler generates a static singleton instance of this
/// class for each extension. For exmaple, imagine a .proto file with:
/// <code>
/// message Foo {
/// extensions 1000 to max
/// }
///
/// extend Foo {
/// optional int32 bar;
/// }
/// </code>
/// Then MyProto.Foo.Bar has type GeneratedExtension<MyProto.Foo,int>.
/// <para />
/// In general, users should ignore the details of this type, and
/// simply use the static singletons as parmaeters to the extension accessors
/// in ExtendableMessage and ExtendableBuilder.
/// </remarks>
public class GeneratedExtension<TContainer, TExtension> where TContainer : IMessage<TContainer> {
public FieldDescriptor Descriptor;
public IMessage MessageDefaultInstance;
}
}
|