pub struct CollectionDomain { /* private fields */ }Implementations§
Source§impl CollectionDomain
impl CollectionDomain
pub fn new(workspace_root: impl AsRef<Path>) -> Self
pub fn list(&self) -> Vec<CollectionSummary>
pub fn get(&self, id: &str) -> Result<CollectionRecord, ApiError>
pub fn create( &mut self, params: CollectionCreateParams, ) -> Result<CollectionRecord, ApiError>
pub fn update( &mut self, params: CollectionUpdateParams, ) -> Result<CollectionRecord, ApiError>
pub fn delete(&mut self, id: &str) -> Result<(), ApiError>
pub fn import( &mut self, params: CollectionImportParams, ) -> Result<CollectionRecord, ApiError>
pub fn export(&self, id: &str) -> Result<String, ApiError>
Sourcepub fn run(
&self,
params: CollectionRunParams,
ralph_command: &str,
workspace_root: &Path,
) -> Result<CollectionRunResult, ApiError>
pub fn run( &self, params: CollectionRunParams, ralph_command: &str, workspace_root: &Path, ) -> Result<CollectionRunResult, ApiError>
Export the collection’s hats to a temp YAML file and spawn ralph run
with it via the -H flag. The user’s existing ralph.yml provides
core config (backend, max_iterations, backpressure). The collection
only provides hats and events.
Returns the PID so the frontend can track the process.
Auto Trait Implementations§
impl Freeze for CollectionDomain
impl RefUnwindSafe for CollectionDomain
impl Send for CollectionDomain
impl Sync for CollectionDomain
impl Unpin for CollectionDomain
impl UnsafeUnpin for CollectionDomain
impl UnwindSafe for CollectionDomain
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