pub trait LifecycleApi {
// Required methods
async fn open_project(
&self,
project: ProjectId,
files: Vec<File>,
open_file: FileId,
) -> Result<()>;
async fn add_file(&self, project: ProjectId, file: File) -> Result<()>;
async fn remove_file(&self, project: ProjectId, file: FileId) -> Result<()>;
async fn update_file(
&self,
project: ProjectId,
file: FileId,
text: String,
) -> Result<()>;
async fn switch_file(&self, project: ProjectId, file: FileId) -> Result<()>;
async fn refresh(&self, project: ProjectId) -> Result<()>;
}
Required Methods§
async fn open_project( &self, project: ProjectId, files: Vec<File>, open_file: FileId, ) -> Result<()>
async fn add_file(&self, project: ProjectId, file: File) -> Result<()>
async fn remove_file(&self, project: ProjectId, file: FileId) -> Result<()>
async fn update_file( &self, project: ProjectId, file: FileId, text: String, ) -> Result<()>
async fn switch_file(&self, project: ProjectId, file: FileId) -> Result<()>
async fn refresh(&self, project: ProjectId) -> Result<()>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.