1
0
mirror of https://github.com/JoelBender/bacpypes synced 2025-09-28 22:15:23 +08:00

add __str__ to DateTime for easier introspection (#487)

Take advantage of Date and Time __str__ methods
This commit is contained in:
Safrone 2025-01-21 23:15:42 -05:00 committed by GitHub
parent fe00d344ff
commit df6476cc91
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -2233,6 +2233,9 @@ class DateTime(Sequence):
, Element('time', Time)
]
def __str__(self):
return "%s(date=%s, time=%s)" % (self.__class__.__name__, self.date, self.time)
class DateRange(Sequence):
sequenceElements = \
[ Element('startDate', Date)