pub struct VariablesValidator { /* private fields */ }Implementations§
Source§impl VariablesValidator
impl VariablesValidator
pub fn new() -> Self
pub fn load_env_files(&mut self, env_files: &[PathBuf]) -> ComposerResult<()>
Sourcepub fn load_env_file(&mut self, project_dir: &Path) -> ComposerResult<()>
pub fn load_env_file(&mut self, project_dir: &Path) -> ComposerResult<()>
Load variables from .env file if it exists
Sourcepub fn validate_variables(
&self,
variables: &[ComposerVariables],
) -> ComposerResult<ValidationResult>
pub fn validate_variables( &self, variables: &[ComposerVariables], ) -> ComposerResult<ValidationResult>
Validate variables against current environment and .env file
pub fn has_env_file_variable(&self, name: &str) -> bool
pub fn get_env_file_variables(&self) -> &HashMap<String, String>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for VariablesValidator
impl RefUnwindSafe for VariablesValidator
impl Send for VariablesValidator
impl Sync for VariablesValidator
impl Unpin for VariablesValidator
impl UnwindSafe for VariablesValidator
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