CborReader Constructors
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| CborReader(ReadOnlyMemory<Byte>, CborReaderOptions) |
Initializes a CborReader instance over the specified |
| CborReader(ReadOnlyMemory<Byte>, CborConformanceMode, Boolean) |
Initializes a CborReader instance over the specified |
| CborReader(ReadOnlyMemory<Byte>, CborReaderOptions, Boolean) |
Initializes a CborReader instance over the specified |
CborReader(ReadOnlyMemory<Byte>, CborReaderOptions)
- Source:
- CborReader.cs
Initializes a CborReader instance over the specified data with the given options.
public:
CborReader(ReadOnlyMemory<System::Byte> data, System::Formats::Cbor::CborReaderOptions ^ options);
public CborReader(ReadOnlyMemory<byte> data, System.Formats.Cbor.CborReaderOptions? options);
new System.Formats.Cbor.CborReader : ReadOnlyMemory<byte> * System.Formats.Cbor.CborReaderOptions -> System.Formats.Cbor.CborReader
Public Sub New (data As ReadOnlyMemory(Of Byte), options As CborReaderOptions)
Parameters
- data
- ReadOnlyMemory<Byte>
The CBOR-encoded data to read.
- options
- CborReaderOptions
The options that control reading behavior.
Applies to
CborReader(ReadOnlyMemory<Byte>, CborConformanceMode, Boolean)
- Source:
- CborReader.cs
- Source:
- CborReader.cs
- Source:
- CborReader.cs
- Source:
- CborReader.cs
Initializes a CborReader instance over the specified data with the given configuration.
public CborReader(ReadOnlyMemory<byte> data, System.Formats.Cbor.CborConformanceMode conformanceMode = System.Formats.Cbor.CborConformanceMode.Strict, bool allowMultipleRootLevelValues = false);
new System.Formats.Cbor.CborReader : ReadOnlyMemory<byte> * System.Formats.Cbor.CborConformanceMode * bool -> System.Formats.Cbor.CborReader
Public Sub New (data As ReadOnlyMemory(Of Byte), Optional conformanceMode As CborConformanceMode = System.Formats.Cbor.CborConformanceMode.Strict, Optional allowMultipleRootLevelValues As Boolean = false)
Parameters
- data
- ReadOnlyMemory<Byte>
The CBOR-encoded data to read.
- conformanceMode
- CborConformanceMode
One of the enumeration values to specify a conformance mode guiding the checks performed on the encoded data. Defaults to Strict conformance mode.
- allowMultipleRootLevelValues
- Boolean
true to indicate that multiple root-level values are supported by the reader; otherwise, false.
Exceptions
conformanceMode is not defined.
Applies to
CborReader(ReadOnlyMemory<Byte>, CborReaderOptions, Boolean)
- Source:
- CborReader.cs
Initializes a CborReader instance over the specified data with the given options.
public:
CborReader(ReadOnlyMemory<System::Byte> data, System::Formats::Cbor::CborReaderOptions ^ options, bool isFinalBlock);
public CborReader(ReadOnlyMemory<byte> data, System.Formats.Cbor.CborReaderOptions? options, bool isFinalBlock);
new System.Formats.Cbor.CborReader : ReadOnlyMemory<byte> * System.Formats.Cbor.CborReaderOptions * bool -> System.Formats.Cbor.CborReader
Public Sub New (data As ReadOnlyMemory(Of Byte), options As CborReaderOptions, isFinalBlock As Boolean)
Parameters
- data
- ReadOnlyMemory<Byte>
The CBOR-encoded data to read.
- options
- CborReaderOptions
The options that control reading behavior.
- isFinalBlock
- Boolean
true to indicate that data contains the complete remainder of the document(s) to read;
false if more data may be supplied using SlideData(ReadOnlyMemory<Byte>, Boolean).
Exceptions
isFinalBlock is false and the conformance mode is not Lax.