Sdílet prostřednictvím


CborWriter.WriteStartArray(Nullable<Int32>) Method

Definition

Writes the start of a definite or indefinite-length array (major type 4).

public:
 void WriteStartArray(Nullable<int> definiteLength);
public void WriteStartArray (int? definiteLength);
member this.WriteStartArray : Nullable<int> -> unit
Public Sub WriteStartArray (definiteLength As Nullable(Of Integer))

Parameters

definiteLength
Nullable<Int32>

The length of the definite-length array, or null for an indefinite-length array.

Exceptions

The definiteLength parameter cannot be negative.

Writing a new value exceeds the definite length of the parent data item.

-or-

The major type of the encoded value is not permitted in the parent data item.

-or-

The written data is not accepted under the current conformance mode.

Remarks

In canonical conformance modes, the writer will reject indefinite-length writes unless the ConvertIndefiniteLengthEncodings flag is enabled.

Applies to