Interface IExtendableMessage<T>
Generic interface for a Protocol Buffers message containing one or more extensions, where the type parameter is expected to be the same type as the implementation class.
This interface is experiemental and is subject to change.
Inherited Members
System.IEquatable<T>.Equals(T)
Assembly: Google.Protobuf.dll
Syntax
public interface IExtendableMessage<T> : IMessage<T>, IMessage, IEquatable<T>, IDeepCloneable<T> where T : IExtendableMessage<T>
Type Parameters
Methods
ClearExtension<TValue>(Extension<T, TValue>)
Clears the value of the specified extension
Declaration
void ClearExtension<TValue>(Extension<T, TValue> extension)
Parameters
Type |
Name |
Description |
Extension<T, TValue> |
extension |
|
Type Parameters
ClearExtension<TValue>(RepeatedExtension<T, TValue>)
Clears the value of the specified repeated extension
Declaration
void ClearExtension<TValue>(RepeatedExtension<T, TValue> extension)
Parameters
Type Parameters
GetExtension<TValue>(Extension<T, TValue>)
Gets the value of the specified extension
Declaration
TValue GetExtension<TValue>(Extension<T, TValue> extension)
Parameters
Type |
Name |
Description |
Extension<T, TValue> |
extension |
|
Returns
Type Parameters
GetExtension<TValue>(RepeatedExtension<T, TValue>)
Declaration
RepeatedField<TValue> GetExtension<TValue>(RepeatedExtension<T, TValue> extension)
Parameters
Returns
Type Parameters
GetOrInitializeExtension<TValue>(RepeatedExtension<T, TValue>)
Gets the value of the specified repeated extension, registering it if it hasn't already been registered.
Declaration
RepeatedField<TValue> GetOrInitializeExtension<TValue>(RepeatedExtension<T, TValue> extension)
Parameters
Returns
Type Parameters
HasExtension<TValue>(Extension<T, TValue>)
Gets whether the value of the specified extension is set
Declaration
bool HasExtension<TValue>(Extension<T, TValue> extension)
Parameters
Type |
Name |
Description |
Extension<T, TValue> |
extension |
|
Returns
Type |
Description |
System.Boolean |
|
Type Parameters
SetExtension<TValue>(Extension<T, TValue>, TValue)
Sets the value of the specified extension
Declaration
void SetExtension<TValue>(Extension<T, TValue> extension, TValue value)
Parameters
Type |
Name |
Description |
Extension<T, TValue> |
extension |
|
TValue |
value |
|
Type Parameters
Extension Methods