[−][src]Struct libtombala::types::Game
Fields
id: u64
c1: Vec<u32>
c2: Vec<u32>
t: Vec<u32>
balls: Vec<u8>
card_state: HashMap<u32, CardState>
card_index_by_number: CardIndex
Implementations
impl Game
[src]
pub fn new(game_id: u64, index: CardIndex) -> Arc<RwLock<Game>>
[src]
Deprecated since 2.3.0:
this will be replaced with new_plain in next major release. Use new_plain for now and wrap in Arc and Lock manually
pub fn new_plain(index: CardIndex) -> Game
[src]
pub fn is_first5_c1(&self) -> bool
[src]
pub fn is_first10_c2(&self) -> bool
[src]
pub fn is_tulum(&self) -> bool
[src]
pub fn new_game(&mut self) -> u64
[src]
pub fn add_ball(&mut self, num: u8) -> Result<Option<Winning>, String>
[src]
Trait Implementations
impl Clone for Game
[src]
impl Debug for Game
[src]
impl Default for Game
[src]
impl<'de> Deserialize<'de> for Game
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
impl Serialize for Game
[src]
Auto Trait Implementations
impl RefUnwindSafe for Game
impl Send for Game
impl Sync for Game
impl Unpin for Game
impl UnwindSafe for Game
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,