pub enum Punctuation {
Show 21 variants Period, Bang, Question, Colon, Semicolon, Quote(Quote), Comma, Hyphen, OpenSquare, CloseSquare, OpenRound, CloseRound, Hash, Apostrophe, Percent, ForwardSlash, Backslash, LessThan, GreaterThan, Equal, Star,
}

Variants§

§

Period

.

§

Bang

!

§

Question

?

§

Colon

:

§

Semicolon

;

§

Quote(Quote)

§

Comma

,

§

Hyphen

§

OpenSquare

[

§

CloseSquare

]

§

OpenRound

(

§

CloseRound

)

§

Hash

§

Apostrophe

§

Percent

%

§

ForwardSlash

/

§

Backslash

\

§

LessThan

<

§

GreaterThan

§

Equal

=

§

Star

Implementations§

source§

impl Punctuation

source

pub const fn is_period(&self) -> bool

Returns true if self is of variant Period.

source

pub const fn is_bang(&self) -> bool

Returns true if self is of variant Bang.

source

pub const fn is_question(&self) -> bool

Returns true if self is of variant Question.

source

pub const fn is_colon(&self) -> bool

Returns true if self is of variant Colon.

source

pub const fn is_semicolon(&self) -> bool

Returns true if self is of variant Semicolon.

source

pub const fn is_quote(&self) -> bool

Returns true if self is of variant Quote.

source

pub fn as_quote(&self) -> Option<&Quote>

Returns Some if self is a reference of variant Quote, and None otherwise.

source

pub fn as_mut_quote(&mut self) -> Option<&mut Quote>

Returns Some if self is a mutable reference of variant Quote, and None otherwise.

source

pub fn expect_quote(self) -> Quote
where Self: Debug,

Unwraps the value, yielding the content of Quote.

§Panics

Panics if the value is not Quote, with a panic message including the content of self.

source

pub fn quote(self) -> Option<Quote>

Returns Some if self is of variant Quote, and None otherwise.

source

pub const fn is_comma(&self) -> bool

Returns true if self is of variant Comma.

source

pub const fn is_hyphen(&self) -> bool

Returns true if self is of variant Hyphen.

source

pub const fn is_open_square(&self) -> bool

Returns true if self is of variant OpenSquare.

source

pub const fn is_close_square(&self) -> bool

Returns true if self is of variant CloseSquare.

source

pub const fn is_open_round(&self) -> bool

Returns true if self is of variant OpenRound.

source

pub const fn is_close_round(&self) -> bool

Returns true if self is of variant CloseRound.

source

pub const fn is_hash(&self) -> bool

Returns true if self is of variant Hash.

source

pub const fn is_apostrophe(&self) -> bool

Returns true if self is of variant Apostrophe.

source

pub const fn is_percent(&self) -> bool

Returns true if self is of variant Percent.

source

pub const fn is_forward_slash(&self) -> bool

Returns true if self is of variant ForwardSlash.

source

pub const fn is_backslash(&self) -> bool

Returns true if self is of variant Backslash.

source

pub const fn is_less_than(&self) -> bool

Returns true if self is of variant LessThan.

source

pub const fn is_greater_than(&self) -> bool

Returns true if self is of variant GreaterThan.

source

pub const fn is_equal(&self) -> bool

Returns true if self is of variant Equal.

source

pub const fn is_star(&self) -> bool

Returns true if self is of variant Star.

Trait Implementations§

source§

impl Clone for Punctuation

source§

fn clone(&self) -> Punctuation

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Punctuation

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Punctuation

source§

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 PartialEq for Punctuation

source§

fn eq(&self, other: &Punctuation) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialOrd for Punctuation

source§

fn partial_cmp(&self, other: &Punctuation) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl Serialize for Punctuation

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Copy for Punctuation

source§

impl Eq for Punctuation

source§

impl StructuralPartialEq for Punctuation

Auto Trait Implementations§

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<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. 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<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

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

§

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>,

§

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> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,