pub enum CounterType {
Show 19 variants
P1P1,
M1M1,
Poison,
Loyalty,
Charge,
Quest,
Study,
Age,
Fade,
Time,
Depletion,
Storage,
Mining,
Brick,
Level,
Lore,
Page,
Dream,
Named(String),
}Expand description
Counter types commonly used in MTG.
Note: Copy is intentionally absent because the Named(String) variant
holds heap-allocated data. Use .clone() when an owned copy is needed.
Variants§
P1P1
M1M1
Poison
Loyalty
Charge
Quest
Study
Age
Fade
Time
Depletion
Storage
Mining
Brick
Level
Lore
Page
Dream
Named(String)
Catch-all for counter types not in the enum (e.g. SUPPLY, VERSE, LUCK). Stored as uppercase name for consistent comparison.
Implementations§
Source§impl CounterType
impl CounterType
Sourcepub fn is(&self, other: &CounterType) -> bool
pub fn is(&self, other: &CounterType) -> bool
Java parity helper for interface-style checks.
Sourcepub fn is_keyword_counter(&self) -> bool
pub fn is_keyword_counter(&self) -> bool
Java parity helper for “keyword counter” classification.
Trait Implementations§
Source§impl Clone for CounterType
impl Clone for CounterType
Source§fn clone(&self) -> CounterType
fn clone(&self) -> CounterType
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CounterType
impl Debug for CounterType
Source§impl<'de> Deserialize<'de> for CounterType
impl<'de> Deserialize<'de> for CounterType
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for CounterType
impl Display for CounterType
impl Eq for CounterType
Source§impl FromStr for CounterType
impl FromStr for CounterType
Source§impl Hash for CounterType
impl Hash for CounterType
Source§impl Ord for CounterType
impl Ord for CounterType
Source§fn cmp(&self, other: &CounterType) -> Ordering
fn cmp(&self, other: &CounterType) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for CounterType
impl PartialEq for CounterType
Source§impl PartialOrd for CounterType
impl PartialOrd for CounterType
Source§impl Serialize for CounterType
impl Serialize for CounterType
impl StructuralPartialEq for CounterType
Auto Trait Implementations§
impl Freeze for CounterType
impl RefUnwindSafe for CounterType
impl Send for CounterType
impl Sync for CounterType
impl Unpin for CounterType
impl UnsafeUnpin for CounterType
impl UnwindSafe for CounterType
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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> CallHasher for T
impl<T> CallHasher for T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
Source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Gets the layout of the type.