<PackageReference Include="System.Runtime.Serialization.Primitives" Version="4.0.11-beta-23409" />

CollectionDataContractAttribute

When applied to a collection type, enables custom specification of the collection item elements. This attribute can be applied only to types that are recognized by the DataContractSerializer as valid, serializable collections.
public bool IsItemNameSetExplicitly { get; }

public bool IsKeyNameSetExplicitly { get; }

public bool IsNameSetExplicitly { get; }

public bool IsNamespaceSetExplicitly { get; }

public bool IsReference { get; set; }

Gets or sets a value that indicates whether to preserve object reference data.

public bool IsReferenceSetExplicitly { get; }

public bool IsValueNameSetExplicitly { get; }

public string ItemName { get; set; }

Gets or sets a custom name for a collection element.

public string KeyName { get; set; }

Gets or sets the custom name for a dictionary key name.

public string Name { get; set; }

Gets or sets the data contract name for the collection type.

public string Namespace { get; set; }

Gets or sets the namespace for the data contract.

public string ValueName { get; set; }

Gets or sets the custom name for a dictionary value name.

Initializes a new instance of the CollectionDataContractAttribute class.