craftutils.observation.epoch.Time.replicate(format=None, copy=False, cls=None)

Return a replica of the Time object, optionally changing the format.

If format is supplied then the time format of the returned Time object will be set accordingly, otherwise it will be unchanged from the original.

If copy is set to True then a full copy of the internal time arrays will be made. By default the replica will use a reference to the original arrays when possible to save memory. The internal time arrays are normally not changeable by the user so in most cases it should not be necessary to set copy to True.

The convenience method copy() is available in which copy is True by default.

Parameters

formatstr, optional

Time format of the replica.

copybool, optional

Return a true copy instead of using references where possible.

Returns

tmTime object

Replica of this object