pub struct DashboardLayoutManager { /* private fields */ }Expand description
Dashboard layout manager
Implementations§
Source§impl DashboardLayoutManager
impl DashboardLayoutManager
Sourcepub fn save_layout(&self, layout: &DashboardLayout) -> Result<()>
pub fn save_layout(&self, layout: &DashboardLayout) -> Result<()>
Save a dashboard layout
Sourcepub fn load_layout(&self, layout_id: &str) -> Result<DashboardLayout>
pub fn load_layout(&self, layout_id: &str) -> Result<DashboardLayout>
Load a dashboard layout
Sourcepub fn list_layouts(&self) -> Result<Vec<DashboardLayoutInfo>>
pub fn list_layouts(&self) -> Result<Vec<DashboardLayoutInfo>>
List all dashboard layouts
Sourcepub fn delete_layout(&self, layout_id: &str) -> Result<()>
pub fn delete_layout(&self, layout_id: &str) -> Result<()>
Delete a dashboard layout
Sourcepub fn clone_layout(
&self,
source_id: &str,
new_name: &str,
new_author: &str,
) -> Result<DashboardLayout>
pub fn clone_layout( &self, source_id: &str, new_name: &str, new_author: &str, ) -> Result<DashboardLayout>
Clone a dashboard layout with a new ID
Sourcepub fn export_layout(&self, layout_id: &str) -> Result<String>
pub fn export_layout(&self, layout_id: &str) -> Result<String>
Export layout to JSON string
Sourcepub fn import_layout(&self, json: &str) -> Result<DashboardLayout>
pub fn import_layout(&self, json: &str) -> Result<DashboardLayout>
Import layout from JSON string
Auto Trait Implementations§
impl Freeze for DashboardLayoutManager
impl RefUnwindSafe for DashboardLayoutManager
impl Send for DashboardLayoutManager
impl Sync for DashboardLayoutManager
impl Unpin for DashboardLayoutManager
impl UnwindSafe for DashboardLayoutManager
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