SetObjectJSON

Object model, document editing

Description

Validuje jednu typed JSON hodnotu a nahradí vybraný existujúci nepriamy objekt, pritom zachová jeho object a generation čísla. Dictionary, polia, streamy, skalárne hodnoty a referencie si zachovajú svoje PDF typy. Parsovanie a klonovanie sa dokončia skôr, než sa objekt zmení, takže deformovaný vstup ponechá pôvodný objekt nedotknutý

Syntax

Delphi

Function TPDFlib.SetObjectJSON(ObjectNumber: Integer; Const JSON: AnsiString; Options: Integer): Integer;

ActiveX

Function PDFlib::SetObjectJSON(ObjectNumber As Long, JSON As String, Options As Long) As Long

DLL

int DLSetObjectJSON(int InstanceID, int ObjectNumber, const char* JSON, int Options);

Parameters

ObjectNumberExisting indirect object number to replace
JSONTyped value returned by GetObjectJSON or extracted from an object graph
OptionsMust be 0

Return values

1The object was replaced
0The object or JSON is invalid; LastErrorCode is 105