pub struct SchnapsenDuoClient { /* private fields */ }
Implementations§
Source§impl SchnapsenDuoClient
impl SchnapsenDuoClient
pub fn new( player: Arc<RwLock<Player>>, instance: Arc<Mutex<SchnapsenDuo>>, ) -> Self
pub fn cutt_deck(&self, cards_to_take: usize) -> Result<(), PlayerError>
pub fn get_player_id(&self) -> String
pub fn is_active(&self) -> bool
pub fn draw_card(&self) -> Result<(), PlayerError>
pub fn close_talon(&self) -> Result<(), PlayerError>
pub fn take_cards_til(&self, idx: usize) -> Result<(), PlayerError>
pub fn play_card(&self, card: Card) -> Result<(), PlayerError>
pub fn swap_trump(&self, card: Card) -> Result<(), PlayerError>
pub fn announce_40(&self) -> Result<(), PlayerError>
pub fn announce_20(&self, cards: [Card; 2]) -> Result<(), PlayerError>
Auto Trait Implementations§
impl Freeze for SchnapsenDuoClient
impl RefUnwindSafe for SchnapsenDuoClient
impl Send for SchnapsenDuoClient
impl Sync for SchnapsenDuoClient
impl Unpin for SchnapsenDuoClient
impl UnwindSafe for SchnapsenDuoClient
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