
    i%                     d    S SK Jr   " S S\R                  5      r " S S\R                  5      rg)   )base_namespacec                       \ rS rSrSrS r  SS jr  SS jr  SS jrSS jr	SS	 jr
SS
 jrSS jrSS jrSS jrSS jrSrg)	Namespace   a  Base class for server-side class-based namespaces.

A class-based namespace is a class that contains all the event handlers
for a Socket.IO namespace. The event handlers are methods of the class
with the prefix ``on_``, such as ``on_connect``, ``on_disconnect``,
``on_message``, ``on_json``, and so on.

:param namespace: The Socket.IO namespace to be used with all the event
                  handlers defined in this class. If this argument is
                  omitted, the default namespace is used.
c                     SU=(       d    S-   n[        X5      (       a   [        X5      " U6 $ g! [         a    US:X  a  [        X5      " USS 6 s $ e f = fa:  Dispatch an event to the proper handler method.

In the most common usage, this method is not overloaded by subclasses,
as it performs the routing of events to methods. However, this
method can be overridden if special dispatching rules are needed, or if
having a single method that catches all events is desired.
on_ 
disconnectNhasattrgetattr	TypeErrorselfeventargshandler_names       O/home/admin/cozy_coffee/venv/lib/python3.13/site-packages/socketio/namespace.pytrigger_eventNamespace.trigger_event   i     ,4&&t2D99 '  L("46Sb	BB   / !AANc	                 b    U R                   R                  XX4UU=(       d    U R                  XxS9$ )zEmit a custom event to one or more connected clients.

The only difference with the :func:`socketio.Server.emit` method is
that when the ``namespace`` argument is not given the namespace
associated with the class is used.
)datatoroomskip_sid	namespacecallbackignore_queue)serveremitr    )	r   r   r   r   r   r   r    r!   r"   s	            r   r$   Namespace.emit#   s8     {{R)1*3*Et~~)1   N 	N    c           
      `    U R                   R                  XX4U=(       d    U R                  XgS9$ )zSend a message to one or more connected clients.

The only difference with the :func:`socketio.Server.send` method is
that when the ``namespace`` argument is not given the namespace
associated with the class is used.
)r   r   r   r    r!   r"   )r#   sendr    )r   r   r   r   r   r    r!   r"   s           r   r(   Namespace.send0   s5     {{$*3*Et~~)1   N 	Nr&   c           
      `    U R                   R                  XX4U=(       d    U R                  XgS9$ )zEmit a custom event to a client and wait for the response.

The only difference with the :func:`socketio.Server.call` method is
that when the ``namespace`` argument is not given the namespace
associated with the class is used.
)r   r   sidr    timeoutr"   )r#   callr    )r   r   r   r   r+   r    r,   r"   s           r   r-   Namespace.call<   s5     {{R*3*Et~~(/   L 	Lr&   c                 \    U R                   R                  XU=(       d    U R                  S9$ )zEnter a room.

The only difference with the :func:`socketio.Server.enter_room` method
is that when the ``namespace`` argument is not given the namespace
associated with the class is used.
r    )r#   
enter_roomr    r   r+   r   r    s       r   r1   Namespace.enter_roomH   0     {{%%c090KT^^ & M 	Mr&   c                 \    U R                   R                  XU=(       d    U R                  S9$ )zLeave a room.

The only difference with the :func:`socketio.Server.leave_room` method
is that when the ``namespace`` argument is not given the namespace
associated with the class is used.
r0   )r#   
leave_roomr    r2   s       r   r6   Namespace.leave_roomR   r4   r&   c                 \    U R                   R                  UU=(       d    U R                  S9$ )zClose a room.

The only difference with the :func:`socketio.Server.close_room` method
is that when the ``namespace`` argument is not given the namespace
associated with the class is used.
r0   )r#   
close_roomr    )r   r   r    s      r   r9   Namespace.close_room\   s0     {{%%d090KT^^ & M 	Mr&   c                 Z    U R                   R                  X=(       d    U R                  S9$ )zReturn the user session for a client.

The only difference with the :func:`socketio.Server.get_session`
method is that when the ``namespace`` argument is not given the
namespace associated with the class is used.
r0   )r#   get_sessionr    r   r+   r    s      r   r<   Namespace.get_sessionf   s,     {{&&6 ' 8 	8r&   c                 \    U R                   R                  XU=(       d    U R                  S9$ )zStore the user session for a client.

The only difference with the :func:`socketio.Server.save_session`
method is that when the ``namespace`` argument is not given the
namespace associated with the class is used.
r0   )r#   save_sessionr    )r   r+   sessionr    s       r   r@   Namespace.save_sessionp   s0     {{''I$? ( A 	Ar&   c                 Z    U R                   R                  X=(       d    U R                  S9$ )zReturn the user session for a client with context manager syntax.

The only difference with the :func:`socketio.Server.session` method is
that when the ``namespace`` argument is not given the namespace
associated with the class is used.
r0   )r#   rA   r    r=   s      r   rA   Namespace.sessionz   s%     {{""32Mt~~"NNr&   c                 \    U R                   R                  UU=(       d    U R                  S9$ )zDisconnect a client.

The only difference with the :func:`socketio.Server.disconnect` method
is that when the ``namespace`` argument is not given the namespace
associated with the class is used.
r0   )r#   r   r    r=   s      r   r   Namespace.disconnect   r4   r&    )NNNNNNF)NNNNNF)N)__name__
__module____qualname____firstlineno____doc__r   r$   r(   r-   r1   r6   r9   r<   r@   rA   r   __static_attributes__rG   r&   r   r   r      se    
& CG9>N GK).
N CG(-
LMMM8AOMr&   r   c                   B    \ rS rSrSrS rS
S jrS
S jrS
S jrS r	S	r
g)ClientNamespace   a  Base class for client-side class-based namespaces.

A class-based namespace is a class that contains all the event handlers
for a Socket.IO namespace. The event handlers are methods of the class
with the prefix ``on_``, such as ``on_connect``, ``on_disconnect``,
``on_message``, ``on_json``, and so on.

:param namespace: The Socket.IO namespace to be used with all the event
                  handlers defined in this class. If this argument is
                  omitted, the default namespace is used.
c                     SU=(       d    S-   n[        X5      (       a   [        X5      " U6 $ g! [         a    US:X  a  [        X5      " USS 6 s $ e f = fr   r   r   s       r   r   ClientNamespace.trigger_event   r   r   Nc                 ^    U R                   R                  XU=(       d    U R                  US9$ )zEmit a custom event to the server.

The only difference with the :func:`socketio.Client.emit` method is
that when the ``namespace`` argument is not given the namespace
associated with the class is used.
)r   r    r!   )clientr$   r    )r   r   r   r    r!   s        r   r$   ClientNamespace.emit   s1     {{*3*Et~~)1   3 	3r&   c                 \    U R                   R                  X=(       d    U R                  US9$ )zSend a message to the server.

The only difference with the :func:`socketio.Client.send` method is
that when the ``namespace`` argument is not given the namespace
associated with the class is used.
)r    r!   )rT   r(   r    )r   r   r   r    r!   s        r   r(   ClientNamespace.send   s.     {{0KT^^)1   3 	3r&   c                 ^    U R                   R                  XU=(       d    U R                  US9$ )zEmit a custom event to the server and wait for the response.

The only difference with the :func:`socketio.Client.call` method is
that when the ``namespace`` argument is not given the namespace
associated with the class is used.
)r   r    r,   )rT   r-   r    )r   r   r   r    r,   s        r   r-   ClientNamespace.call   s1     {{*3*Et~~(/   1 	1r&   c                 6    U R                   R                  5       $ )zDisconnect from the server.

The only difference with the :func:`socketio.Client.disconnect` method
is that when the ``namespace`` argument is not given the namespace
associated with the class is used.
)rT   r   )r   s    r   r   ClientNamespace.disconnect   s     {{%%''r&   rG   )NNN)rH   rI   rJ   rK   rL   r   r$   r(   r-   r   rM   rG   r&   r   rO   rO      s     
&	33	1(r&   rO   N)r
   r   BaseServerNamespacer   BaseClientNamespacerO   rG   r&   r   <module>r^      s3    GM22 GMTF(n88 F(r&   