Enum twig::operator::OperatorKind [] [src]

pub enum OperatorKind {
    Unary {
        value: &'static str,
    },
    Binary {
        value: &'static str,
        associativity: Associativity,
    },
    Other,
}

Operator kind.

Variants

Unary

Single argument operator, i.e negation.

Fields

value
Binary

Two argument operator, i.e sum.

Fields

value
associativity
Other

Any operator handled by extension (i.e. the "=" operator).

Methods

impl OperatorKind

fn new_binary(value: &'static str, associativity: Associativity) -> OperatorKind

fn new_binary_left(value: &'static str) -> OperatorKind

fn new_binary_right(value: &'static str) -> OperatorKind

fn new_unary(value: &'static str) -> OperatorKind

fn new_other() -> OperatorKind

Trait Implementations

Derived Implementations

impl Clone for OperatorKind

fn clone(&self) -> OperatorKind

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

impl Copy for OperatorKind

impl Debug for OperatorKind

fn fmt(&self, __arg_0: &mut Formatter) -> Result

impl PartialEq for OperatorKind

fn eq(&self, __arg_0: &OperatorKind) -> bool

fn ne(&self, __arg_0: &OperatorKind) -> bool