Class MapContract
- Namespace
- ShapeShift.Schema
- Assembly
- ShapeShift.dll
Describes a type that associates keys with values.
public sealed class MapContract : DataContract
- Inheritance
-
MapContract
- Inherited Members
Constructors
MapContract(Type, DataContract, DataContract, MapEncoding)
Initializes a new instance of the MapContract class.
public MapContract(Type dataType, DataContract keyType, DataContract valueType, MapEncoding encoding)
Parameters
dataTypeType- The .NET type that this contract describes.
keyTypeDataContractThe contract describing each key.
valueTypeDataContractThe contract describing each value.
encodingMapEncodingThe encoding used for the map.
Properties
Encoding
Gets the encoding used for the map.
public MapEncoding Encoding { get; }
Property Value
KeyType
Gets the contract describing each key.
public DataContract KeyType { get; }
Property Value
Kind
Gets the kind of this contract, which identifies the concrete subclass.
public override DataContractKind Kind { get; }
Property Value
ReferencedContracts
Gets the contracts that this contract directly refers to.
public override IEnumerable<DataContract> ReferencedContracts { get; }
Property Value
Remarks
The sequence may contain the same contract more than once, and (for recursive types) may transitively include this contract itself.
ValueType
Gets the contract describing each value.
public DataContract ValueType { get; }