#[non_exhaustive]pub struct AppState {
pub config: Arc<Config>,
pub renderers: Arc<RendererRegistry>,
pub access: Arc<dyn AccessControl>,
pub directory: Arc<dyn RendererDirectory>,
}Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.config: Arc<Config>§renderers: Arc<RendererRegistry>§access: Arc<dyn AccessControl>§directory: Arc<dyn RendererDirectory>Implementations§
Source§impl AppState
impl AppState
Sourcepub fn new(
config: Arc<Config>,
renderers: Arc<RendererRegistry>,
access: Arc<dyn AccessControl>,
) -> Self
pub fn new( config: Arc<Config>, renderers: Arc<RendererRegistry>, access: Arc<dyn AccessControl>, ) -> Self
With NoDirectory — see AppState::with_directory to list
renderers from a consumer’s own storage too.
pub fn with_directory(self, directory: Arc<dyn RendererDirectory>) -> Self
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for AppState
impl !UnwindSafe for AppState
impl Freeze for AppState
impl Send for AppState
impl Sync for AppState
impl Unpin for AppState
impl UnsafeUnpin for AppState
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