TWSDocumentMetadata Class Reference

Inherits from NSObject
Declared in TWSDocumentMetadata.h

Overview

Metadata associated with the Document.

+ withTtl:

Optionally specify TTL for the Document.

+ (nullable TWSDocumentMetadata *)withTtl:(int)ttl

Parameters

ttl

Time to live in seconds from now or TWSDurationInfinity to indicate no expiry.

Return Value

Metadata object with given ttl.

Discussion

Optionally specify TTL for the Document.

TTL specifies the minimum time the Document will live, sometime soon after this time the object will be deleted.

If time to live is not specified, object lives infinitely long.

TTL could be used in order to auto-recycle old unused objects, but it is not recommended to build some app logic like timers using ttl.

Declared In

TWSDocumentMetadata.h