pub struct WhileLoop { /* private fields */ }Expand description
A while loops.
Trait Implementations§
Source§impl<E: 'static + Expression> From<E> for WhileLoop
impl<E: 'static + Expression> From<E> for WhileLoop
Source§impl Statement for WhileLoop
impl Statement for WhileLoop
Source§fn write(&self, b: &mut CodeBuffer, level: usize)
fn write(&self, b: &mut CodeBuffer, level: usize)
Writes the code to the buffer
b at the indent level.Source§impl WithStatements for WhileLoop
impl WithStatements for WhileLoop
Source§fn statements(&self) -> &[Box<dyn Statement>]
fn statements(&self) -> &[Box<dyn Statement>]
Gets the statements.
Source§fn add_boxed_statement(&mut self, statement: Box<dyn Statement>)
fn add_boxed_statement(&mut self, statement: Box<dyn Statement>)
Adds the boxed
statement.Source§fn with_boxed_statement(self, statement: Box<dyn Statement>) -> Self
fn with_boxed_statement(self, statement: Box<dyn Statement>) -> Self
Adds the boxed
statement.Source§fn add_statement<S>(&mut self, statement: S)where
S: 'static + Statement,
fn add_statement<S>(&mut self, statement: S)where
S: 'static + Statement,
Adds the
statement.Source§fn with_statement<S>(self, statement: S) -> Selfwhere
S: 'static + Statement,
fn with_statement<S>(self, statement: S) -> Selfwhere
S: 'static + Statement,
Adds the
statement.Source§fn add_literal<L>(&mut self, literal: L)
fn add_literal<L>(&mut self, literal: L)
Adds the
literal statement.Source§fn with_literal<L>(self, literal: L) -> Self
fn with_literal<L>(self, literal: L) -> Self
Adds the
literal statement.Source§fn add_expression_statement<E>(&mut self, expression: E)where
E: 'static + Expression,
fn add_expression_statement<E>(&mut self, expression: E)where
E: 'static + Expression,
Adds the
expression as a statement.Source§fn with_expression_statement<E>(self, expression: E) -> Selfwhere
E: 'static + Expression,
fn with_expression_statement<E>(self, expression: E) -> Selfwhere
E: 'static + Expression,
Adds the
expression as a statement.Source§fn write_statements(&self, b: &mut CodeBuffer, level: usize)
fn write_statements(&self, b: &mut CodeBuffer, level: usize)
Writes the statements.
Source§fn write_curly_statement_block(&self, b: &mut CodeBuffer, level: usize)
fn write_curly_statement_block(&self, b: &mut CodeBuffer, level: usize)
Writes the curly-bracketed statement block. (
level is the outer level)Auto Trait Implementations§
impl Freeze for WhileLoop
impl !RefUnwindSafe for WhileLoop
impl !Send for WhileLoop
impl !Sync for WhileLoop
impl Unpin for WhileLoop
impl !UnwindSafe for WhileLoop
Blanket Implementations§
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