bitcanon / visonicalarm

A simple library for the Visonic Alarm API written in Python 3.
MIT License
12 stars 2 forks source link

The __repr__() method should return object #4

Closed bitcanon closed 3 years ago

bitcanon commented 3 years ago

When calling the repr() method of the Device class it should return a text that can be used to create a new object of that class.

Example:

Device(id='123-4567', zone='5', location='Livingroom', alerts=None, ...and so on)

You should then be able to copy that text and create a new object:

test = Device(id='123-4567', zone='5', location='Livingroom', alerts=None, ...and so on)
print(text.id)