Enum swc_css_ast::ContainerQueryType
source · [−]pub enum ContainerQueryType {
Not(ContainerQueryNot),
And(ContainerQueryAnd),
Or(ContainerQueryOr),
QueryInParens(QueryInParens),
}
Variants
Not(ContainerQueryNot)
And(ContainerQueryAnd)
Or(ContainerQueryOr)
QueryInParens(QueryInParens)
Implementations
sourceimpl ContainerQueryType
impl ContainerQueryType
sourcepub fn as_not(&self) -> Option<&ContainerQueryNot>
pub fn as_not(&self) -> Option<&ContainerQueryNot>
Returns Some
if self
is a reference of variant Not
, and None
otherwise.
sourcepub fn as_mut_not(&mut self) -> Option<&mut ContainerQueryNot>
pub fn as_mut_not(&mut self) -> Option<&mut ContainerQueryNot>
Returns Some
if self
is a mutable reference of variant Not
, and None
otherwise.
sourcepub fn expect_not(self) -> ContainerQueryNotwhere
Self: Debug,
pub fn expect_not(self) -> ContainerQueryNotwhere
Self: Debug,
sourcepub fn not(self) -> Option<ContainerQueryNot>
pub fn not(self) -> Option<ContainerQueryNot>
Returns Some
if self
is of variant Not
, and None
otherwise.
sourcepub fn as_and(&self) -> Option<&ContainerQueryAnd>
pub fn as_and(&self) -> Option<&ContainerQueryAnd>
Returns Some
if self
is a reference of variant And
, and None
otherwise.
sourcepub fn as_mut_and(&mut self) -> Option<&mut ContainerQueryAnd>
pub fn as_mut_and(&mut self) -> Option<&mut ContainerQueryAnd>
Returns Some
if self
is a mutable reference of variant And
, and None
otherwise.
sourcepub fn expect_and(self) -> ContainerQueryAndwhere
Self: Debug,
pub fn expect_and(self) -> ContainerQueryAndwhere
Self: Debug,
sourcepub fn and(self) -> Option<ContainerQueryAnd>
pub fn and(self) -> Option<ContainerQueryAnd>
Returns Some
if self
is of variant And
, and None
otherwise.
sourcepub fn as_or(&self) -> Option<&ContainerQueryOr>
pub fn as_or(&self) -> Option<&ContainerQueryOr>
Returns Some
if self
is a reference of variant Or
, and None
otherwise.
sourcepub fn as_mut_or(&mut self) -> Option<&mut ContainerQueryOr>
pub fn as_mut_or(&mut self) -> Option<&mut ContainerQueryOr>
Returns Some
if self
is a mutable reference of variant Or
, and None
otherwise.
sourcepub fn expect_or(self) -> ContainerQueryOrwhere
Self: Debug,
pub fn expect_or(self) -> ContainerQueryOrwhere
Self: Debug,
sourcepub fn or(self) -> Option<ContainerQueryOr>
pub fn or(self) -> Option<ContainerQueryOr>
Returns Some
if self
is of variant Or
, and None
otherwise.
sourcepub fn is_query_in_parens(&self) -> bool
pub fn is_query_in_parens(&self) -> bool
Returns true
if self
is of variant QueryInParens
.
sourcepub fn as_query_in_parens(&self) -> Option<&QueryInParens>
pub fn as_query_in_parens(&self) -> Option<&QueryInParens>
Returns Some
if self
is a reference of variant QueryInParens
, and None
otherwise.
sourcepub fn as_mut_query_in_parens(&mut self) -> Option<&mut QueryInParens>
pub fn as_mut_query_in_parens(&mut self) -> Option<&mut QueryInParens>
Returns Some
if self
is a mutable reference of variant QueryInParens
, and None
otherwise.
sourcepub fn expect_query_in_parens(self) -> QueryInParenswhere
Self: Debug,
pub fn expect_query_in_parens(self) -> QueryInParenswhere
Self: Debug,
Unwraps the value, yielding the content of QueryInParens
.
Panics
Panics if the value is not QueryInParens
, with a panic message including the content of self
.
sourcepub fn query_in_parens(self) -> Option<QueryInParens>
pub fn query_in_parens(self) -> Option<QueryInParens>
Returns Some
if self
is of variant QueryInParens
, and None
otherwise.
Trait Implementations
sourceimpl Clone for ContainerQueryType
impl Clone for ContainerQueryType
sourcefn clone(&self) -> ContainerQueryType
fn clone(&self) -> ContainerQueryType
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more