Trait AddInternalDependency

Source
pub trait AddInternalDependency<P, H>
where P: for<'async_trait> Debug + for<'async_trait> Clone + for<'async_trait> From<PathBuf> + for<'async_trait> AsRef<Path> + for<'async_trait> Send + for<'async_trait> Sync + 'async_trait, H: CrateHandleInterface<P> + Debug + Send + Sync,
{ type Error; // Required method fn add_internal_dependency<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, target_crate: &'life1 H, dep_crate: &'life2 H, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>> where 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, Self: 'async_trait; }
Expand description

A trait for adding an internal dep from one crate to another.

Required Associated Types§

Required Methods§

Source

fn add_internal_dependency<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, target_crate: &'life1 H, dep_crate: &'life2 H, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>
where 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, Self: 'async_trait,

Attempt to add a dependency on dep_crate to the target_crate.

  • Edits the target crate’s Cargo.toml to add [dependencies] dep_name = { path=... }
  • Updates src/imports.rs with a pub(crate) use target_crate::*; statement

Implementors§

Source§

impl<P, H> AddInternalDependency<P, H> for Workspace<P, H>
where P: for<'async_trait> Debug + for<'async_trait> Clone + for<'async_trait> From<PathBuf> + for<'async_trait> AsRef<Path> + for<'async_trait> Send + for<'async_trait> Sync + 'async_trait, H: CrateHandleInterface<P> + Debug + Send + Sync,