pub struct FlakeReferenceParseFlags { /* private fields */ }Expand description
Flags that control how a flake reference string is parsed.
Create one with FlakeReferenceParseFlags::new then optionally call
set_base_directory before passing it to
FlakeReference::parse.
Implementations§
Source§impl FlakeReferenceParseFlags
impl FlakeReferenceParseFlags
Sourcepub fn new(
context: &Arc<Context>,
flake_settings: &FlakeSettings,
) -> Result<Self>
pub fn new( context: &Arc<Context>, flake_settings: &FlakeSettings, ) -> Result<Self>
Create new parse flags with default values.
§Errors
Returns an error if the underlying allocation fails.
Sourcepub fn set_base_directory(self, dir: &str) -> Result<Self>
pub fn set_base_directory(self, dir: &str) -> Result<Self>
Set the base directory used when resolving relative flake references.
§Errors
Returns an error if the C API call fails.
Trait Implementations§
Source§impl Drop for FlakeReferenceParseFlags
impl Drop for FlakeReferenceParseFlags
impl Send for FlakeReferenceParseFlags
Auto Trait Implementations§
impl Freeze for FlakeReferenceParseFlags
impl RefUnwindSafe for FlakeReferenceParseFlags
impl !Sync for FlakeReferenceParseFlags
impl Unpin for FlakeReferenceParseFlags
impl UnsafeUnpin for FlakeReferenceParseFlags
impl UnwindSafe for FlakeReferenceParseFlags
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