pub struct Plan {
pub ops: Vec<FileOp>,
}Expand description
An ordered collection of FileOps produced by a generator.
Fields§
§ops: Vec<FileOp>Implementations§
Source§impl Plan
impl Plan
pub fn new() -> Self
pub fn create( self, path: impl Into<PathBuf>, contents: impl Into<String>, ) -> Self
pub fn mkdir(self, path: impl Into<PathBuf>) -> Self
Sourcepub fn extend(self, other: Plan) -> Self
pub fn extend(self, other: Plan) -> Self
Append every operation from other, preserving order. Used to compose a base plan
with an optional add-on (e.g. gize new’s built-in users slice).
pub fn is_empty(&self) -> bool
Trait Implementations§
impl Eq for Plan
impl StructuralPartialEq for Plan
Auto Trait Implementations§
impl Freeze for Plan
impl RefUnwindSafe for Plan
impl Send for Plan
impl Sync for Plan
impl Unpin for Plan
impl UnsafeUnpin for Plan
impl UnwindSafe for Plan
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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.