pub enum SystemCommand {
Show 32 variants
ActivateApp(ApplicationId),
CloseApp(ApplicationId),
LoadDataSource(LogDataSource),
AddReceiver(LogReceiver),
AddRedapServer(Origin),
EditRedapServerModal(EditRedapServerModalCommand),
OpenSettings,
OpenChunkStoreBrowser {
store_id: Option<StoreId>,
selected_chunk: Option<ChunkId>,
},
SetRoute(Route),
ResetRoute,
ResetViewer,
ClearActiveBlueprint,
ClearActiveBlueprintAndEnableHeuristics,
CloseRecordingOrTable(RecordingOrTable),
CloseAllEntries,
AppendToStore(StoreId, Vec<Chunk>),
UndoBlueprint {
blueprint_id: StoreId,
},
RedoBlueprint {
blueprint_id: StoreId,
},
DropEntity(StoreId, EntityPath),
EnableInspectBlueprintTimeline(bool),
SetUrlFragment {
store_id: StoreId,
fragment: Fragment,
},
CopyViewerUrl(String),
SetSelection(SetSelection),
TimeControlCommands {
store_id: StoreId,
time_commands: Vec<TimeControlCommand>,
},
SetFocus(Item),
ShowNotification(Notification),
ReadbackAndSaveTexture(TextureReadbackId),
FileSaver(Box<dyn FnOnce() -> Result<PathBuf, Error> + Send>),
OnAuthChanged(Option<AuthContext>),
SetAuthCredentials {
access_token: String,
email: String,
},
Logout,
SaveScreenshot {
target: ScreenshotTarget,
view_id: Option<BlueprintId<ViewIdRegistry>>,
},
}Expand description
Commands used by internal system components
Variants§
ActivateApp(ApplicationId)
Make this the active application.
CloseApp(ApplicationId)
Close this app and all its recordings.
LoadDataSource(LogDataSource)
Load data from a given data source.
Will not load any new data if the source is already one of the active data sources.
AddReceiver(LogReceiver)
Add a new receiver for log messages.
AddRedapServer(Origin)
Add a new server to the redap browser.
EditRedapServerModal(EditRedapServerModalCommand)
Open a modal to edit this redap server.
OpenSettings
Activates the setting route.
OpenChunkStoreBrowser
Activates the chunk store route.
SetRoute(Route)
ResetRoute
Sets the route to what it is at startup.
ResetViewer
Reset the Viewer to the default state
ClearActiveBlueprint
Clear the active blueprint.
This may have two outcomes:
- If a default blueprint is set, it will be used.
- Otherwise, the heuristics will be enabled.
To force using the heuristics, use Self::ClearActiveBlueprintAndEnableHeuristics.
UI note: because of the above ambiguity, controls for this command should only be enabled if a default blueprint is set or the behavior is explicitly explained.
ClearActiveBlueprintAndEnableHeuristics
Clear the active blueprint and enable heuristics.
The final outcome of this is to set the active blueprint to the heuristics. This command does not affect the default blueprint if any was set.
CloseRecordingOrTable(RecordingOrTable)
Close an RecordingOrTable and free its memory.
CloseAllEntries
Close all stores and show the welcome screen again.
AppendToStore(StoreId, Vec<Chunk>)
Add more data to a store (blueprint or recording).
Edit recordings with case: we generally regard recordings as immutable.
For blueprints,the StoreId should generally be the currently selected blueprint.
Instead of using this directly, consider using save_blueprint_archetype or similar.
UndoBlueprint
RedoBlueprint
DropEntity(StoreId, EntityPath)
Drop a specific entity from a store.
Also drops all recursive children.
The StoreId should generally be the currently selected blueprint
but is tracked manually to ensure self-consistency if the blueprint
is both modified and changed in the same frame.
EnableInspectBlueprintTimeline(bool)
Show a timeline of the blueprint data.
SetUrlFragment
Navigate to time/entities/anchors/etc. that are set in a re_uri::Fragment.
CopyViewerUrl(String)
Copies the given url to the clipboard.
On web this adds the viewer url as the base url.
SetSelection(SetSelection)
Set the item selection.
TimeControlCommands
SetFocus(Item)
Sets the focus to the given item.
The focused item is cleared out every frame. Focusing is triggered either explicitly by ui-elements saying so or by double-clicking on a button representing an item.
Unlike item selection, item focusing is not global state. It may however have stateful effects in certain views, e.g. the 3D view may follow the last focused item as it moves, or a frame may be highlighted for a few frames.
Just like selection highlighting, the exact behavior of focusing is up to the receiving views.
ShowNotification(Notification)
Show a notification to the user
ReadbackAndSaveTexture(TextureReadbackId)
Start polling a texture we’re reading back from the gpu, and then prompt the user to save a png of the texture.
FileSaver(Box<dyn FnOnce() -> Result<PathBuf, Error> + Send>)
Add a task, run on a background thread, that saves something to disk.
OnAuthChanged(Option<AuthContext>)
Notify about authentication changes.
SetAuthCredentials
Set authentication credentials from an external source.
Logout
Logout from rerun cloud
SaveScreenshot
Save a screenshot to a file.
Fields
target: ScreenshotTargetWhere to save the screenshot.
view_id: Option<BlueprintId<ViewIdRegistry>>Optional view id to screenshot a specific view. If None, screenshots the entire viewer.
Implementations§
Source§impl SystemCommand
impl SystemCommand
pub fn clear_selection() -> SystemCommand
pub fn set_selection(selection: impl Into<SetSelection>) -> SystemCommand
Source§impl SystemCommand
impl SystemCommand
Sourcepub fn debug_name(&self) -> &'static str
pub fn debug_name(&self) -> &'static str
A short debug name for this command.
Trait Implementations§
Source§impl Debug for SystemCommand
impl Debug for SystemCommand
Source§impl<'_derivative_strum> From<&'_derivative_strum SystemCommand> for &'static str
impl<'_derivative_strum> From<&'_derivative_strum SystemCommand> for &'static str
Source§fn from(x: &'_derivative_strum SystemCommand) -> &'static str
fn from(x: &'_derivative_strum SystemCommand) -> &'static str
Source§impl From<SystemCommand> for &'static str
impl From<SystemCommand> for &'static str
Source§fn from(x: SystemCommand) -> &'static str
fn from(x: SystemCommand) -> &'static str
Auto Trait Implementations§
impl !Freeze for SystemCommand
impl !RefUnwindSafe for SystemCommand
impl Send for SystemCommand
impl !Sync for SystemCommand
impl Unpin for SystemCommand
impl UnsafeUnpin for SystemCommand
impl !UnwindSafe for SystemCommand
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
Source§impl<T> CheckedAs for T
impl<T> CheckedAs for T
Source§fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,
fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,
Source§impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,
impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,
Source§fn checked_cast_from(src: Src) -> Option<Dst>
fn checked_cast_from(src: Src) -> Option<Dst>
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
Source§fn with_current_context(self) -> WithContext<Self> ⓘ
fn with_current_context(self) -> WithContext<Self> ⓘ
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::RequestSource§impl<Src, Dst> LosslessTryInto<Dst> for Srcwhere
Dst: LosslessTryFrom<Src>,
impl<Src, Dst> LosslessTryInto<Dst> for Srcwhere
Dst: LosslessTryFrom<Src>,
Source§fn lossless_try_into(self) -> Option<Dst>
fn lossless_try_into(self) -> Option<Dst>
Source§impl<Src, Dst> LossyInto<Dst> for Srcwhere
Dst: LossyFrom<Src>,
impl<Src, Dst> LossyInto<Dst> for Srcwhere
Dst: LossyFrom<Src>,
Source§fn lossy_into(self) -> Dst
fn lossy_into(self) -> Dst
Source§impl<T> OverflowingAs for T
impl<T> OverflowingAs for T
Source§fn overflowing_as<Dst>(self) -> (Dst, bool)where
T: OverflowingCast<Dst>,
fn overflowing_as<Dst>(self) -> (Dst, bool)where
T: OverflowingCast<Dst>,
Source§impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere
Src: OverflowingCast<Dst>,
impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere
Src: OverflowingCast<Dst>,
Source§fn overflowing_cast_from(src: Src) -> (Dst, bool)
fn overflowing_cast_from(src: Src) -> (Dst, bool)
Source§impl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
Source§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
Source§fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
self and passes that borrow into the pipe function. Read moreSource§fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
self and passes that borrow into the pipe function. Read moreSource§fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
Source§fn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R,
) -> R
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
Source§fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
self, then passes self.as_ref() into the pipe function.Source§fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
self, then passes self.as_mut() into the pipe
function.Source§fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
self, then passes self.deref() into the pipe function.Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> SaturatingAs for T
impl<T> SaturatingAs for T
Source§fn saturating_as<Dst>(self) -> Dstwhere
T: SaturatingCast<Dst>,
fn saturating_as<Dst>(self) -> Dstwhere
T: SaturatingCast<Dst>,
Source§impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere
Src: SaturatingCast<Dst>,
impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere
Src: SaturatingCast<Dst>,
Source§fn saturating_cast_from(src: Src) -> Dst
fn saturating_cast_from(src: Src) -> Dst
Source§impl<T> StrictAs for T
impl<T> StrictAs for T
Source§fn strict_as<Dst>(self) -> Dstwhere
T: StrictCast<Dst>,
fn strict_as<Dst>(self) -> Dstwhere
T: StrictCast<Dst>,
Source§impl<Src, Dst> StrictCastFrom<Src> for Dstwhere
Src: StrictCast<Dst>,
impl<Src, Dst> StrictCastFrom<Src> for Dstwhere
Src: StrictCast<Dst>,
Source§fn strict_cast_from(src: Src) -> Dst
fn strict_cast_from(src: Src) -> Dst
Source§impl<T> Tap for T
impl<T> Tap for T
Source§fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Borrow<B> of a value. Read moreSource§fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
BorrowMut<B> of a value. Read moreSource§fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
AsRef<R> view of a value. Read moreSource§fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
AsMut<R> view of a value. Read moreSource§fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Deref::Target of a value. Read moreSource§fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Deref::Target of a value. Read moreSource§fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
.tap() only in debug builds, and is erased in release builds.Source§fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
.tap_mut() only in debug builds, and is erased in release
builds.Source§fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
.tap_borrow() only in debug builds, and is erased in release
builds.Source§fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
.tap_borrow_mut() only in debug builds, and is erased in release
builds.Source§fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
.tap_ref() only in debug builds, and is erased in release
builds.Source§fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
.tap_ref_mut() only in debug builds, and is erased in release
builds.Source§fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
.tap_deref() only in debug builds, and is erased in release
builds.