Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

OneNoteBinaryPayload

OfficeIMO.OneNote

Namespace
OfficeIMO.OneNote
Assembly
OfficeIMO.OneNote
Source revision
be6c300e4ab1 with working tree changes
Modifiers
sealed

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

Inheritance

  • object
  • OneNoteBinaryPayload

Usage

Explore 12 API references to this type

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) #

Creates an independently owned payload by copying a byte array.

Parameters

bytes byte[] required
public static OneNoteBinaryPayload FromStreamFactory(Func<Stream> streamFactory, long? length = null) #

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

Parameters

streamFactory System.Func<System.IO.Stream> required
length long? = null optional
public Stream OpenRead() #

Opens a new readable stream for the payload.

Returns

Stream
public byte[] ToArray(long maxBytes) #

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

Parameters

maxBytes long required

Returns

byte[]

Properties

public long? Length { get; } #

Payload length when known without opening the stream.