tiled.server.object_cache.ObjectCache.put

ObjectCache.put(key, value, cost, nbytes=None)[source]

Put cache item.

Parameters
keyuniquely identifies content
valueobject

May be any Python object. For future-proofing, the object should be pickle-able, as an _external_ object cache will be added in the future.

costfloat

Time in seconds that this value cost to obtain.

nbytesbytesize, optional

Computed (with best effort) if not provided.