pub struct ClientWrapper { /* private fields */ }
Expand description
A wrapper around Client
. Helps reduce external imports.
Methods from Deref<Target = Client<DynConnector, Identity>>§
Sourcepub fn find_lobby(&self) -> FindLobby<C, M, R>
pub fn find_lobby(&self) -> FindLobby<C, M, R>
Constructs a fluent builder for the FindLobby
operation.
- The fluent builder is configurable:
game_modes(Vec<String>)
/set_game_modes(Option<Vec<String>>)
: Game modes to match lobbies against.regions(Vec<String>)
/set_regions(Option<Vec<String>>)
: Regions to match lobbies against. If not specified, the optimal region will be determined and will attempt to find lobbies in that region.prevent_auto_create_lobby(bool)
/set_prevent_auto_create_lobby(Option<bool>)
: Prevents a new lobby from being created when finding a lobby. If no lobby is found, aMATCHMAKER_LOBBY_NOT_FOUND
error will be thrown.captcha(CaptchaConfig)
/set_captcha(Option<CaptchaConfig>)
: Methods to verify a captcha.origin(impl Into<String>)
/set_origin(Option<String>)
: (undocumented)
- On success, responds with
FindLobbyOutput
with field(s):lobby(Option<MatchmakerLobbyJoinInfo>)
: A matchmaker lobby.
- On failure, responds with
SdkError<FindLobbyError>
Sourcepub fn join_lobby(&self) -> JoinLobby<C, M, R>
pub fn join_lobby(&self) -> JoinLobby<C, M, R>
Constructs a fluent builder for the JoinLobby
operation.
- The fluent builder is configurable:
lobby_id(impl Into<String>)
/set_lobby_id(Option<String>)
: A universally unique identifier.captcha(CaptchaConfig)
/set_captcha(Option<CaptchaConfig>)
: Methods to verify a captcha.
- On success, responds with
JoinLobbyOutput
with field(s):lobby(Option<MatchmakerLobbyJoinInfo>)
: A matchmaker lobby.
- On failure, responds with
SdkError<JoinLobbyError>
Sourcepub fn list_lobbies(&self) -> ListLobbies<C, M, R>
pub fn list_lobbies(&self) -> ListLobbies<C, M, R>
Constructs a fluent builder for the ListLobbies
operation.
- The fluent builder takes no input, just
send
it. - On success, responds with
ListLobbiesOutput
with field(s):game_modes(Option<Vec<GameModeInfo>>)
: (undocumented)regions(Option<Vec<RegionInfo>>)
: (undocumented)lobbies(Option<Vec<LobbyInfo>>)
: (undocumented)
- On failure, responds with
SdkError<ListLobbiesError>
Sourcepub fn list_regions(&self) -> ListRegions<C, M, R>
pub fn list_regions(&self) -> ListRegions<C, M, R>
Constructs a fluent builder for the ListRegions
operation.
- The fluent builder takes no input, just
send
it. - On success, responds with
ListRegionsOutput
with field(s):regions(Option<Vec<RegionInfo>>)
: (undocumented)
- On failure, responds with
SdkError<ListRegionsError>
Sourcepub fn lobby_ready(&self) -> LobbyReady<C, M, R>
pub fn lobby_ready(&self) -> LobbyReady<C, M, R>
Constructs a fluent builder for the LobbyReady
operation.
- The fluent builder takes no input, just
send
it. - On success, responds with
LobbyReadyOutput
- On failure, responds with
SdkError<LobbyReadyError>
Sourcepub fn player_connected(&self) -> PlayerConnected<C, M, R>
pub fn player_connected(&self) -> PlayerConnected<C, M, R>
Constructs a fluent builder for the PlayerConnected
operation.
- The fluent builder is configurable:
player_token(impl Into<String>)
/set_player_token(Option<String>)
: A JSON Web Token. Slightly modified to include a description prefix and use Protobufs of JSON.
- On success, responds with
PlayerConnectedOutput
- On failure, responds with
SdkError<PlayerConnectedError>
Sourcepub fn player_disconnected(&self) -> PlayerDisconnected<C, M, R>
pub fn player_disconnected(&self) -> PlayerDisconnected<C, M, R>
Constructs a fluent builder for the PlayerDisconnected
operation.
- The fluent builder is configurable:
player_token(impl Into<String>)
/set_player_token(Option<String>)
: A JSON Web Token. Slightly modified to include a description prefix and use Protobufs of JSON.
- On success, responds with
PlayerDisconnectedOutput
- On failure, responds with
SdkError<PlayerDisconnectedError>
Sourcepub fn set_lobby_closed(&self) -> SetLobbyClosed<C, M, R>
pub fn set_lobby_closed(&self) -> SetLobbyClosed<C, M, R>
Constructs a fluent builder for the SetLobbyClosed
operation.
- The fluent builder is configurable:
is_closed(bool)
/set_is_closed(Option<bool>)
: (undocumented)
- On success, responds with
SetLobbyClosedOutput
- On failure, responds with
SdkError<SetLobbyClosedError>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ClientWrapper
impl !RefUnwindSafe for ClientWrapper
impl Send for ClientWrapper
impl Sync for ClientWrapper
impl Unpin for ClientWrapper
impl !UnwindSafe for ClientWrapper
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more