pub struct InstalledApps { /* private fields */ }Implementations§
Source§impl InstalledApps
impl InstalledApps
pub fn new() -> Self
pub fn add<M: AppModule>(self, module: M) -> Self
pub fn iter(&self) -> impl Iterator<Item = &dyn AppModule>
pub fn find(&self, name: &str) -> Option<&dyn AppModule>
pub fn names(&self) -> impl Iterator<Item = &'static str> + '_
Sourcepub fn migration_state(&self) -> Result<ProjectState, MigrationError>
pub fn migration_state(&self) -> Result<ProjectState, MigrationError>
Collects a migration-state snapshot without starting the server or connecting to the database.
Sourcepub fn migration_diff(
&self,
history: &ProjectState,
) -> Result<Vec<StateChange>, MigrationError>
pub fn migration_diff( &self, history: &ProjectState, ) -> Result<Vec<StateChange>, MigrationError>
Compares compiled migration history with the current installed models.
It is side-effect free and is the input to makemigrations.
Sourcepub fn library_migrations(&self) -> Vec<Migration>
pub fn library_migrations(&self) -> Vec<Migration>
Collects migrations owned by all installed applications. The name is retained for compatibility with the original library-only API.
pub fn api_endpoints(&self, state: AppState) -> Vec<ApiEndpoint>
pub fn api_signals(&self, state: AppState) -> Vec<ApiSignal>
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for InstalledApps
impl !UnwindSafe for InstalledApps
impl Forget for InstalledApps
impl Freeze for InstalledApps
impl Move for InstalledApps
impl Send for InstalledApps
impl Sync for InstalledApps
impl Unpin for InstalledApps
impl UnsafeUnpin for InstalledApps
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