mirror of
https://github.com/onyx-and-iris/obsws-python.git
synced 2024-11-25 06:10:52 +00:00
conn paramters added to __repr__ magic methods
add __str__ override (used in logger)
This commit is contained in:
parent
92e2c29bd6
commit
cf888b0c4a
@ -5,7 +5,7 @@ from threading import Thread
|
||||
|
||||
from .baseclient import ObsClient
|
||||
from .callback import Callback
|
||||
from .enum import Subs
|
||||
from .subs import Subs
|
||||
|
||||
"""
|
||||
A class to interact with obs-websocket events
|
||||
@ -28,6 +28,11 @@ class EventClient:
|
||||
self.subscribe()
|
||||
|
||||
def __repr__(self):
|
||||
return type(self).__name__ + "({host} {port} {password} {subs})".format(
|
||||
**self.base_client.__dict__
|
||||
)
|
||||
|
||||
def __str__(self):
|
||||
return type(self).__name__
|
||||
|
||||
def subscribe(self):
|
||||
|
@ -26,6 +26,11 @@ class ReqClient:
|
||||
self.base_client.ws.close()
|
||||
|
||||
def __repr__(self):
|
||||
return type(self).__name__ + "({host} {port} {password})".format(
|
||||
**self.base_client.__dict__
|
||||
)
|
||||
|
||||
def __str__(self):
|
||||
return type(self).__name__
|
||||
|
||||
def send(self, param, data=None, raw=False):
|
||||
|
Loading…
Reference in New Issue
Block a user