pub struct WebSocketServiceClient { /* private fields */ }Implementations§
Source§impl WebSocketServiceClient
impl WebSocketServiceClient
pub fn instance_id(&self) -> InstanceId
pub fn for_instance(client: RpcClient, instance_id: InstanceId) -> Self
pub async fn resolve_named( client: RpcClient, name: impl Into<String>, ) -> Result<Self, RuntimeError>
pub async fn connect( &self, request: &WebSocketConnectRequest, ) -> Result<ResourceHandle, RuntimeError>
pub async fn send_text( &self, request: &WebSocketSendTextRequest, ) -> Result<Empty, RuntimeError>
pub async fn send_binary( &self, request: &SocketWriteRequest, ) -> Result<Empty, RuntimeError>
pub async fn close( &self, request: &ResourceHandle, ) -> Result<Empty, RuntimeError>
pub async fn server_listen( &self, request: &SocketListenRequest, ) -> Result<ListenResult, RuntimeError>
pub async fn server_close( &self, request: &ResourceHandle, ) -> Result<Empty, RuntimeError>
pub fn subscribe_event(&self) -> WebSocketServiceEventReceiver
Trait Implementations§
Source§impl Clone for WebSocketServiceClient
impl Clone for WebSocketServiceClient
Source§fn clone(&self) -> WebSocketServiceClient
fn clone(&self) -> WebSocketServiceClient
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl !RefUnwindSafe for WebSocketServiceClient
impl !UnwindSafe for WebSocketServiceClient
impl Freeze for WebSocketServiceClient
impl Send for WebSocketServiceClient
impl Sync for WebSocketServiceClient
impl Unpin for WebSocketServiceClient
impl UnsafeUnpin for WebSocketServiceClient
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more