Document.from_bytes


Description:

[ CCode ( has_construct_function = false ) ]
[ Version ( since = "0.82" ) ]
public Document.from_bytes (Bytes bytes, string? password) throws Error

Creates a new Document from bytes.

The returned document will hold a reference to bytes.

On error, null is returned, with error set. Possible errors include those in the Error and FileError domains.

Parameters:

bytes

a Bytes

password

password to unlock the file with, or null

Returns:

a newly created Document, or null