[][src]Struct gdnative::WebSocketServer

pub struct WebSocketServer { /* fields omitted */ }

core class WebSocketServer inherits WebSocketMultiplayerPeer (reference counted).

Official documentation

See the documentation of this class in the Godot engine's official documentation.

Memory management

The lifetime of this object is automatically managed through reference counting.

Class hierarchy

WebSocketServer inherits methods from:

Methods

impl WebSocketServer[src]

pub fn new() -> WebSocketServer[src]

pub fn new_ref(&self) -> WebSocketServer[src]

Creates a new reference to the same reference-counted object.

pub fn disconnect_peer(&mut self, id: i64, code: i64, reason: GodotString)[src]

pub fn get_peer_address(&self, id: i64) -> GodotString[src]

pub fn get_peer_port(&self, id: i64) -> i64[src]

pub fn has_peer(&self, id: i64) -> bool[src]

pub fn is_listening(&self) -> bool[src]

pub fn listen(
    &mut self,
    port: i64,
    protocols: StringArray,
    gd_mp_api: bool
) -> Result<(), GodotError>
[src]

pub fn stop(&mut self)[src]

pub fn to_web_socket_multiplayer_peer(&self) -> WebSocketMultiplayerPeer[src]

Up-cast.

pub fn to_networked_multiplayer_peer(&self) -> NetworkedMultiplayerPeer[src]

Up-cast.

pub fn to_packet_peer(&self) -> PacketPeer[src]

Up-cast.

pub fn to_reference(&self) -> Reference[src]

Up-cast.

pub fn to_object(&self) -> Object[src]

Up-cast.

pub fn cast<T>(&self) -> Option<T> where
    T: GodotObject
[src]

Generic dynamic cast.

Methods from Deref<Target = WebSocketMultiplayerPeer>

pub fn new_ref(&self) -> WebSocketMultiplayerPeer[src]

Creates a new reference to the same reference-counted object.

pub fn get_peer(&self, peer_id: i64) -> Option<WebSocketPeer>[src]

pub fn to_networked_multiplayer_peer(&self) -> NetworkedMultiplayerPeer[src]

Up-cast.

pub fn to_packet_peer(&self) -> PacketPeer[src]

Up-cast.

pub fn to_reference(&self) -> Reference[src]

Up-cast.

pub fn to_object(&self) -> Object[src]

Up-cast.

pub fn cast<T>(&self) -> Option<T> where
    T: GodotObject
[src]

Generic dynamic cast.

Trait Implementations

impl Clone for WebSocketServer[src]

impl Debug for WebSocketServer[src]

impl Deref for WebSocketServer[src]

type Target = WebSocketMultiplayerPeer

The resulting type after dereferencing.

impl DerefMut for WebSocketServer[src]

impl Drop for WebSocketServer[src]

impl FromVariant for WebSocketServer[src]

impl GodotObject for WebSocketServer[src]

impl Instanciable for WebSocketServer[src]

impl ToVariant for WebSocketServer[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.