caellion-python-commons
caellion.pycommons.serializers.datetime_serializer.DateTimeUnixMicrosSerializer Class Reference

Implementation of DateTime serializer, using Unix-epoch based timestamp with microsecond precision as serialized format. More...

Static Public Member Functions

def deserialize (integer)
 Alias for unserialize. More...
 
def unserialize (integer)
 Unserializes the unix timestamp with microsecond precision to DateTime object. More...
 
def serialize (datetime_to_serialize)
 Serializes the DateTime to Unix timestamp integer. More...
 

Detailed Description

Implementation of DateTime serializer, using Unix-epoch based timestamp with microsecond precision as serialized format.

Definition at line 97 of file datetime_serializer.py.

Member Function Documentation

◆ deserialize()

def caellion.pycommons.serializers.datetime_serializer.DateTimeUnixMicrosSerializer.deserialize (   integer)
static

Alias for unserialize.

Unserializes the unix timestamp with microsecond precision to DateTime object. Always returns UTC timezone DateTime.

Alias for unserialize()

Parameters
integerunix timestamp integer (microseconds)
Returns
DateTime with UTC timezone

Definition at line 104 of file datetime_serializer.py.

◆ serialize()

def caellion.pycommons.serializers.datetime_serializer.DateTimeUnixMicrosSerializer.serialize (   datetime_to_serialize)
static

Serializes the DateTime to Unix timestamp integer.

Always returns UTC timezone integer.

Parameters
datetime_to_serializeDateTime to serialize to unix timestamp integer
Returns
unix timestamp integer (microseconds)

Definition at line 128 of file datetime_serializer.py.

◆ unserialize()

def caellion.pycommons.serializers.datetime_serializer.DateTimeUnixMicrosSerializer.unserialize (   integer)
static

Unserializes the unix timestamp with microsecond precision to DateTime object.

Always returns UTC timezone DateTime.

Parameters
integerunix timestamp integer (microseconds)
Returns
DateTime with UTC timezone

Definition at line 117 of file datetime_serializer.py.


The documentation for this class was generated from the following file: