Struct google_games1::RoomMethods
[−]
[src]
pub struct RoomMethods<'a, C, A> where C: 'a, A: 'a { /* fields omitted */ }
A builder providing access to all methods supported on room resources.
It is not used directly, but through the Games
hub.
Example
Instantiate a resource builder
extern crate hyper; extern crate yup_oauth2 as oauth2; extern crate google_games1 as games1; use std::default::Default; use oauth2::{Authenticator, DefaultAuthenticatorDelegate, ApplicationSecret, MemoryStorage}; use games1::Games; let secret: ApplicationSecret = Default::default(); let auth = Authenticator::new(&secret, DefaultAuthenticatorDelegate, hyper::Client::new(), <MemoryStorage as Default>::default(), None); let mut hub = Games::new(hyper::Client::new(), auth); // Usually you wouldn't bind this to a variable, but keep calling *CallBuilders* // like `create(...)`, `decline(...)`, `dismiss(...)`, `get(...)`, `join(...)`, `leave(...)`, `list(...)` and `report_status(...)` // to build up your call. let rb = hub.rooms();
Methods
impl<'a, C, A> RoomMethods<'a, C, A>
[src]
fn get(&self, room_id: &str) -> RoomGetCall<'a, C, A>
Create a builder to help you perform the following task:
Get the data for a room.
Arguments
roomId
- The ID of the room.
fn leave(&self,
request: RoomLeaveRequest,
room_id: &str)
-> RoomLeaveCall<'a, C, A>
request: RoomLeaveRequest,
room_id: &str)
-> RoomLeaveCall<'a, C, A>
Create a builder to help you perform the following task:
Leave a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
Arguments
request
- No description provided.roomId
- The ID of the room.
fn list(&self) -> RoomListCall<'a, C, A>
Create a builder to help you perform the following task:
Returns invitations to join rooms.
fn report_status(&self,
request: RoomP2PStatuses,
room_id: &str)
-> RoomReportStatuCall<'a, C, A>
request: RoomP2PStatuses,
room_id: &str)
-> RoomReportStatuCall<'a, C, A>
Create a builder to help you perform the following task:
Updates sent by a client reporting the status of peers in a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
Arguments
request
- No description provided.roomId
- The ID of the room.
fn create(&self, request: RoomCreateRequest) -> RoomCreateCall<'a, C, A>
Create a builder to help you perform the following task:
Create a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
Arguments
request
- No description provided.
fn decline(&self, room_id: &str) -> RoomDeclineCall<'a, C, A>
Create a builder to help you perform the following task:
Decline an invitation to join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
Arguments
roomId
- The ID of the room.
fn dismiss(&self, room_id: &str) -> RoomDismisCall<'a, C, A>
Create a builder to help you perform the following task:
Dismiss an invitation to join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
Arguments
roomId
- The ID of the room.
fn join(&self,
request: RoomJoinRequest,
room_id: &str)
-> RoomJoinCall<'a, C, A>
request: RoomJoinRequest,
room_id: &str)
-> RoomJoinCall<'a, C, A>
Create a builder to help you perform the following task:
Join a room. For internal use by the Games SDK only. Calling this method directly is unsupported.
Arguments
request
- No description provided.roomId
- The ID of the room.