def serialize(self):
        """This function serialize into a simple dict object.
        It is used when transferring data to other daemons over the network (http)

        Here we directly return all attributes

        :return: json representation of a Daterange
        :rtype: dict
        """
        return {'day': self.day, 'other': self.other,
                'timeranges': [t.serialize() for t in self.timeranges]}