Struct InputManagerServiceSyncClient

Source
pub struct InputManagerServiceSyncClient<IP, OP>{ /* private fields */ }

Implementations§

Source§

impl<IP, OP> InputManagerServiceSyncClient<IP, OP>

Source

pub fn new( input_protocol: IP, output_protocol: OP, ) -> InputManagerServiceSyncClient<IP, OP>

Trait Implementations§

Source§

impl<IP, OP> TThriftClient for InputManagerServiceSyncClient<IP, OP>

Source§

fn i_prot_mut(&mut self) -> &mut dyn TInputProtocol

Returns the input protocol used to read serialized Thrift messages from the Thrift server.
Source§

fn o_prot_mut(&mut self) -> &mut dyn TOutputProtocol

Returns the output protocol used to write serialized Thrift messages to the Thrift server.
Source§

fn sequence_number(&self) -> i32

Returns the sequence number of the last message written to the Thrift server. Returns 0 if no messages have been written. Sequence numbers should never be negative, and this method returns an i32 simply because the Thrift protocol encodes sequence numbers as i32 on the wire.
Source§

fn increment_sequence_number(&mut self) -> i32

Increments the sequence number, indicating that a message with that number has been sent to the Thrift server.
Source§

impl<IP, OP> TInputManagerServiceSyncClientMarker for InputManagerServiceSyncClient<IP, OP>

Auto Trait Implementations§

§

impl<IP, OP> Freeze for InputManagerServiceSyncClient<IP, OP>
where IP: Freeze, OP: Freeze,

§

impl<IP, OP> RefUnwindSafe for InputManagerServiceSyncClient<IP, OP>

§

impl<IP, OP> Send for InputManagerServiceSyncClient<IP, OP>
where IP: Send, OP: Send,

§

impl<IP, OP> Sync for InputManagerServiceSyncClient<IP, OP>
where IP: Sync, OP: Sync,

§

impl<IP, OP> Unpin for InputManagerServiceSyncClient<IP, OP>
where IP: Unpin, OP: Unpin,

§

impl<IP, OP> UnwindSafe for InputManagerServiceSyncClient<IP, OP>
where IP: UnwindSafe, OP: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<C> TInputManagerServiceSyncClient for C

Source§

fn get_connected_gamepads(&mut self) -> Result<Vec<GamepadInfo>, Error>

Get the gamepads that are connected corrently
Source§

fn set_gamepad_vibration( &mut self, device_id: String, motor1_value: i8, motor1_time: i8, motor2_value: i8, motor2_time: i8, ) -> Result<bool, Error>

Activate the vibration of gamepad
Source§

fn set_gamepad_light( &mut self, device_id: String, r_value: i8, g_value: i8, b_value: i8, ) -> Result<bool, Error>

Change the light of gamepad (for ruyi controller only)
Source§

fn set_ruyi_controller_status( &mut self, channel: i8, enable_r: bool, enable_g: bool, enable_b: bool, enable_motor1: bool, enable_motor2: bool, shutdown: bool, r_value: i8, g_value: i8, b_value: i8, motor1_value: i8, motor1_time: i8, motor2_value: i8, motor2_time: i8, ) -> Result<bool, Error>

Obsolete. Temporary api the change the ruyi controller’s state, will be removed later.
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Err>