TWSDocumentDelegate Protocol Reference

Conforms to NSObject
Declared in TWSDocument.h

Overview

The delegate that will be called with lifecycle updates for the document.

– onDocumentOpened:

Called when the document referenced is opened.

- (void)onDocumentOpened:(nonnull TWSDocument *)document

Parameters

document

The document.

Discussion

Called when the document referenced is opened.

Declared In

TWSDocument.h

– onDocumentRemoved:previousData:eventContext:

Called when the document is removed as a result of a local operation.

- (void)onDocumentRemoved:(nonnull TWSDocument *)document previousData:(nonnull TWSData *)previousData eventContext:(nonnull TWSEventContext *)eventContext

Parameters

document

The document.

previousData

The data of the document before removing.

eventContext

Context for this event.

Discussion

Called when the document is removed as a result of a local operation.

Declared In

TWSDocument.h

– onDocument:updated:previousData:eventContext:

Called when the document is modified.

- (void)onDocument:(nonnull TWSDocument *)document updated:(nonnull TWSData *)data previousData:(nonnull TWSData *)previousData eventContext:(nonnull TWSEventContext *)eventContext

Parameters

document

The document.

data

The updated data for the document.

previousData

The data of the document before the change.

eventContext

Context for this event.

Discussion

Called when the document is modified.

Declared In

TWSDocument.h

– onDocument:errorOccurred:

Called when an error occurs as a result of a local operation.

- (void)onDocument:(nonnull TWSDocument *)document errorOccurred:(nonnull TWSError *)error

Parameters

document

The document.

error

The error encounted.

Discussion

Called when an error occurs as a result of a local operation.

Declared In

TWSDocument.h