API Reference

Class

OneNoteBinaryPayload

Namespace OfficeIMO.OneNote
Assembly OfficeIMO.OneNote
Modifiers sealed

Lazily materialized binary data associated with a OneNote image, file, recording, or ink object.

Inheritance

  • Object
  • OneNoteBinaryPayload

Usage

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Methods

public static OneNoteBinaryPayload FromBytes(Byte[] bytes) #
Returns: OneNoteBinaryPayload

Creates an independently owned payload by copying a byte array.

Parameters

bytes System.Byte[] requiredposition: 0
public static OneNoteBinaryPayload FromStreamFactory(Func<Stream> streamFactory, Nullable<Int64> length = null) #
Returns: OneNoteBinaryPayload

Creates a lazy payload. The factory must return a new readable stream for every call.

Parameters

streamFactory System.Func{System.IO.Stream} requiredposition: 0
length System.Nullable{System.Int64} = null optionalposition: 1
public Stream OpenRead() #
Returns: Stream

Opens a new readable stream for the payload.

public Byte[] ToArray(Int64 maxBytes) #
Returns: Byte[]

Materializes a defensive copy of the payload with a caller-provided size bound.

Parameters

maxBytes System.Int64 requiredposition: 0

Properties

public Nullable<Int64> Length { get; } #

Payload length when known without opening the stream.