Function fifteen_min::run
source · [−]pub(crate) fn run(settings: Settings)
diff --git a/rustdoc/fifteen_min/fn.run.html b/rustdoc/fifteen_min/fn.run.html index 87426a8048..8bcca68689 100644 --- a/rustdoc/fifteen_min/fn.run.html +++ b/rustdoc/fifteen_min/fn.run.html @@ -1 +1 @@ -
pub(crate) fn run(settings: Settings)
pub(crate) fn run(settings: Settings)
pub fn draw_star(ctx: &mut EventCtx<'_>, b: &Building) -> GeomBatch
pub fn draw_star(ctx: &mut EventCtx<'_>, b: &Building) -> GeomBatch
fn options_from_controls(panel: &Panel) -> MovementOptions
fn options_from_controls(panel: &Panel) -> MovementOptions
fn options_to_controls(ctx: &mut EventCtx<'_>, opts: &Options) -> Widget
fn options_to_controls(ctx: &mut EventCtx<'_>, opts: &Options) -> Widget
This is a tool to experiment with the concept of 15-minute neighborhoods. Can you access your +
This is a tool to experiment with the concept of 15-minute neighborhoods. Can you access your daily needs (like groceries, a cafe, a library) within a 15-minute walk, bike ride, or public transit ride of your home?
See https://github.com/a-b-street/abstreet/issues/393 for more context.
diff --git a/rustdoc/fifteen_min/viewer/struct.Entry.html b/rustdoc/fifteen_min/viewer/struct.Entry.html index 625fe405e9..e4d8a03ffe 100644 --- a/rustdoc/fifteen_min/viewer/struct.Entry.html +++ b/rustdoc/fifteen_min/viewer/struct.Entry.html @@ -1,4 +1,4 @@ -struct Entry {
+Entry in fifteen_min::viewer - Rust Struct fifteen_min::viewer::Entry
source · [−]struct Entry {
bldg: BuildingID,
amenity_idx: usize,
name: String,
diff --git a/rustdoc/fifteen_min/viewer/struct.ExploreAmenities.html b/rustdoc/fifteen_min/viewer/struct.ExploreAmenities.html
index d2c3d22586..065b1b220d 100644
--- a/rustdoc/fifteen_min/viewer/struct.ExploreAmenities.html
+++ b/rustdoc/fifteen_min/viewer/struct.ExploreAmenities.html
@@ -1,8 +1,8 @@
-ExploreAmenities in fifteen_min::viewer - Rust Struct fifteen_min::viewer::ExploreAmenities
source · [−]struct ExploreAmenities {
+ExploreAmenities in fifteen_min::viewer - Rust Struct fifteen_min::viewer::ExploreAmenities
source · [−]Fields
table: Table<SimpleApp<()>, Entry, ()>
panel: Panel
draw: Drawable
Implementations
Trait Implementations
sourceimpl State<SimpleApp<()>> for ExploreAmenities
sourcefn event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<()>
) -> Transition<SimpleApp<()>>
Respond to a UI event, such as input or time passing.fn draw_baselayer(&self) -> DrawBaselayer
Specifies what to draw before draw()fn on_destroy(&mut self, &mut EventCtx<'_>, &mut A)
Before this state is popped or replaced, call this.fn recreate(
&mut self,
&mut EventCtx<'_>,
&mut A
) -> Box<dyn State<A> + 'static, Global>
Respond to Transition::Recreate
by assuming state in the app has changed, but preserving
+}Fields
table: Table<SimpleApp<()>, Entry, ()>
panel: Panel
draw: Drawable
Implementations
Trait Implementations
sourceimpl State<SimpleApp<()>> for ExploreAmenities
sourcefn event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<()>
) -> Transition<SimpleApp<()>>
Respond to a UI event, such as input or time passing.fn draw_baselayer(&self) -> DrawBaselayer
Specifies what to draw before draw()fn on_destroy(&mut self, &mut EventCtx<'_>, &mut A)
Before this state is popped or replaced, call this.Auto Trait Implementations
impl !RefUnwindSafe for ExploreAmenities
impl !Send for ExploreAmenities
impl !Sync for ExploreAmenities
impl Unpin for ExploreAmenities
impl !UnwindSafe for ExploreAmenities
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
diff --git a/rustdoc/fifteen_min/viewer/struct.HoverOnBuilding.html b/rustdoc/fifteen_min/viewer/struct.HoverOnBuilding.html
index bc7a7394b5..fabfb26549 100644
--- a/rustdoc/fifteen_min/viewer/struct.HoverOnBuilding.html
+++ b/rustdoc/fifteen_min/viewer/struct.HoverOnBuilding.html
@@ -1,7 +1,7 @@
-HoverOnBuilding in fifteen_min::viewer - Rust Struct fifteen_min::viewer::HoverOnBuilding
source · [−]pub struct HoverOnBuilding {
+HoverOnBuilding in fifteen_min::viewer - Rust Struct fifteen_min::viewer::HoverOnBuilding
source · [−]pub struct HoverOnBuilding {
pub tooltip: Text,
pub drawn_route: Drawable,
-}
Fields
tooltip: Text
drawn_route: Drawable
Implementations
Auto Trait Implementations
impl RefUnwindSafe for HoverOnBuilding
impl !Send for HoverOnBuilding
impl !Sync for HoverOnBuilding
impl Unpin for HoverOnBuilding
impl UnwindSafe for HoverOnBuilding
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
+}Fields
tooltip: Text
drawn_route: Drawable
Implementations
Auto Trait Implementations
impl RefUnwindSafe for HoverOnBuilding
impl !Send for HoverOnBuilding
impl !Sync for HoverOnBuilding
impl Unpin for HoverOnBuilding
impl UnwindSafe for HoverOnBuilding
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read morefn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert &mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
diff --git a/rustdoc/fifteen_min/viewer/struct.Viewer.html b/rustdoc/fifteen_min/viewer/struct.Viewer.html
index 6d6051221e..0f822cb391 100644
--- a/rustdoc/fifteen_min/viewer/struct.Viewer.html
+++ b/rustdoc/fifteen_min/viewer/struct.Viewer.html
@@ -7,7 +7,7 @@
draw_unwalkable_roads: Drawable,
}Expand description
This is the UI state for exploring the isochrone/walkshed from a single building.
Fields
panel: Panel
highlight_start: Drawable
isochrone: Isochrone
hovering_on_bldg: Cached<(BuildingID, f64), HoverOnBuilding>
hovering_on_category: Option<(AmenityType, Drawable)>
draw_unwalkable_roads: Drawable
Implementations
Trait Implementations
sourceimpl State<SimpleApp<()>> for Viewer
sourcefn event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<()>
) -> Transition<SimpleApp<()>>
Respond to a UI event, such as input or time passing.fn draw_baselayer(&self) -> DrawBaselayer
Specifies what to draw before draw()fn on_destroy(&mut self, &mut EventCtx<'_>, &mut A)
Before this state is popped or replaced, call this.fn recreate(
&mut self,
&mut EventCtx<'_>,
&mut A
) -> Box<dyn State<A> + 'static, Global>
Respond to Transition::Recreate
by assuming state in the app has changed, but preserving
+sourcepub fn new_state(
ctx: &mut EventCtx<'_>,
app: &SimpleApp<()>,
start: BuildingID
) -> Box<dyn State<SimpleApp<()>>>
Trait Implementations
sourceimpl State<SimpleApp<()>> for Viewer
sourcefn event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<()>
) -> Transition<SimpleApp<()>>
Respond to a UI event, such as input or time passing.fn draw_baselayer(&self) -> DrawBaselayer
Specifies what to draw before draw()fn on_destroy(&mut self, &mut EventCtx<'_>, &mut A)
Before this state is popped or replaced, call this.Auto Trait Implementations
impl !RefUnwindSafe for Viewer
impl !Send for Viewer
impl !Sync for Viewer
impl Unpin for Viewer
impl !UnwindSafe for Viewer
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
diff --git a/rustdoc/fifteen_min/viewer/type.HoverKey.html b/rustdoc/fifteen_min/viewer/type.HoverKey.html
index 5a57594120..02ee43fa18 100644
--- a/rustdoc/fifteen_min/viewer/type.HoverKey.html
+++ b/rustdoc/fifteen_min/viewer/type.HoverKey.html
@@ -1,2 +1,2 @@
-HoverKey in fifteen_min::viewer - Rust Type Definition fifteen_min::viewer::HoverKey
source · [−]pub type HoverKey = (BuildingID, f64);
Expand description
(building, scale factor)
+HoverKey in fifteen_min::viewer - Rust
\ No newline at end of file
diff --git a/rustdoc/ltn/fn.is_driveable.html b/rustdoc/ltn/fn.is_driveable.html
index da1fd07b36..3505a6febb 100644
--- a/rustdoc/ltn/fn.is_driveable.html
+++ b/rustdoc/ltn/fn.is_driveable.html
@@ -1 +1 @@
-is_driveable in ltn - Rust Function ltn::is_driveable
source · [−]pub(crate) fn is_driveable(road: &Road, map: &Map) -> bool
\ No newline at end of file
+is_driveable in ltn - Rust Function ltn::is_driveable
source · [−]pub(crate) fn is_driveable(road: &Road, map: &Map) -> bool
\ No newline at end of file
diff --git a/rustdoc/ltn/fn.is_private.html b/rustdoc/ltn/fn.is_private.html
index b870d488df..e90edbe4f0 100644
--- a/rustdoc/ltn/fn.is_private.html
+++ b/rustdoc/ltn/fn.is_private.html
@@ -1 +1 @@
-is_private in ltn - Rust Function ltn::is_private
source · [−]pub(crate) fn is_private(road: &Road) -> bool
\ No newline at end of file
+is_private in ltn - Rust Function ltn::is_private
source · [−]pub(crate) fn is_private(road: &Road) -> bool
\ No newline at end of file
diff --git a/rustdoc/ltn/fn.load_remote.html b/rustdoc/ltn/fn.load_remote.html
index b7bf0963db..4993fb2842 100644
--- a/rustdoc/ltn/fn.load_remote.html
+++ b/rustdoc/ltn/fn.load_remote.html
@@ -1 +1 @@
-load_remote in ltn - Rust
\ No newline at end of file
+load_remote in ltn - Rust
\ No newline at end of file
diff --git a/rustdoc/ltn/fn.redraw_all_filters.html b/rustdoc/ltn/fn.redraw_all_filters.html
index 0e89f4e9c1..29a03610ae 100644
--- a/rustdoc/ltn/fn.redraw_all_filters.html
+++ b/rustdoc/ltn/fn.redraw_all_filters.html
@@ -1 +1 @@
-redraw_all_filters in ltn - Rust Function ltn::redraw_all_filters
source · [−]pub fn redraw_all_filters(ctx: &EventCtx<'_>, app: &mut App)
\ No newline at end of file
+redraw_all_filters in ltn - Rust Function ltn::redraw_all_filters
source · [−]pub fn redraw_all_filters(ctx: &EventCtx<'_>, app: &mut App)
\ No newline at end of file
diff --git a/rustdoc/ltn/fn.setup_initial_states.html b/rustdoc/ltn/fn.setup_initial_states.html
index 3a3d07d3a6..8b4d4e9848 100644
--- a/rustdoc/ltn/fn.setup_initial_states.html
+++ b/rustdoc/ltn/fn.setup_initial_states.html
@@ -1 +1 @@
-setup_initial_states in ltn - Rust
\ No newline at end of file
+setup_initial_states in ltn - Rust
\ No newline at end of file
diff --git a/rustdoc/ltn/index.html b/rustdoc/ltn/index.html
index f00719790a..5d1345b0b9 100644
--- a/rustdoc/ltn/index.html
+++ b/rustdoc/ltn/index.html
@@ -1,4 +1,4 @@
-ltn - Rust Modules
Macros
Structs
Args 🔒 A partitioning of the interior of a neighbourhood based on driving design_ltnA diagonal filter exists in an intersection. It’s defined by two roads (the order is
+ltn - Rust Modules
Macros
Structs
Args 🔒 A partitioning of the interior of a neighbourhood based on driving design_ltnA diagonal filter exists in an intersection. It’s defined by two roads (the order is
arbitrary). When all of the intersection’s roads are sorted in clockwise order, this pair of
roads splits the ordering into two groups. Turns in each group are still possible, but not
across groups.An interval along a road’s length, with start < end.Stored in App per-map state. Before making any changes, call before_edit
.An opaque ID, won’t be contiguous as we adjust boundariesA filter placed somewhere along a roadEnums
Just determines the icon, has no semantics yetConstants
Functions
Type Definitions
\ No newline at end of file
diff --git a/rustdoc/ltn/macro.mut_edits.html b/rustdoc/ltn/macro.mut_edits.html
index 943725c86e..066e3b344c 100644
--- a/rustdoc/ltn/macro.mut_edits.html
+++ b/rustdoc/ltn/macro.mut_edits.html
@@ -1,4 +1,4 @@
-mut_edits in ltn - Rust macro_rules! mut_edits {
+mut_edits in ltn - Rust
\ No newline at end of file
diff --git a/rustdoc/ltn/macro.mut_partitioning.html b/rustdoc/ltn/macro.mut_partitioning.html
index f781b5efa3..9dcc14cf9f 100644
--- a/rustdoc/ltn/macro.mut_partitioning.html
+++ b/rustdoc/ltn/macro.mut_partitioning.html
@@ -1,4 +1,4 @@
-mut_partitioning in ltn - Rust Macro ltn::mut_partitioning
source · [−]macro_rules! mut_partitioning {
+mut_partitioning in ltn - Rust Macro ltn::mut_partitioning
source · [−]macro_rules! mut_partitioning {
($app:ident) => { ... };
}
\ No newline at end of file
diff --git a/rustdoc/map_gui/tools/title_screen/built_info/constant.BUILT_TIME_UTC.html b/rustdoc/map_gui/tools/title_screen/built_info/constant.BUILT_TIME_UTC.html
index ed65c26c3f..8da1f046bb 100644
--- a/rustdoc/map_gui/tools/title_screen/built_info/constant.BUILT_TIME_UTC.html
+++ b/rustdoc/map_gui/tools/title_screen/built_info/constant.BUILT_TIME_UTC.html
@@ -1,2 +1,2 @@
-BUILT_TIME_UTC in map_gui::tools::title_screen::built_info - Rust Constant map_gui::tools::title_screen::built_info::BUILT_TIME_UTC
source · [−]pub const BUILT_TIME_UTC: &'static str = r"Mon, 12 Dec 2022 10:47:10 +0000";
Expand description
The build time in RFC2822, UTC.
+BUILT_TIME_UTC in map_gui::tools::title_screen::built_info - Rust Constant map_gui::tools::title_screen::built_info::BUILT_TIME_UTC
source · [−]pub const BUILT_TIME_UTC: &'static str = r"Mon, 12 Dec 2022 11:46:39 +0000";
Expand description
The build time in RFC2822, UTC.
\ No newline at end of file
diff --git a/rustdoc/osm_viewer/fn.run.html b/rustdoc/osm_viewer/fn.run.html
index faa0fb025e..ac5bb4ce55 100644
--- a/rustdoc/osm_viewer/fn.run.html
+++ b/rustdoc/osm_viewer/fn.run.html
@@ -1 +1 @@
-run in osm_viewer - Rust Function osm_viewer::run
source · [−]pub fn run(settings: Settings)
\ No newline at end of file
+run in osm_viewer - Rust Function osm_viewer::run
source · [−]pub fn run(settings: Settings)
\ No newline at end of file
diff --git a/rustdoc/osm_viewer/index.html b/rustdoc/osm_viewer/index.html
index 5b113c872f..2ddcfa2202 100644
--- a/rustdoc/osm_viewer/index.html
+++ b/rustdoc/osm_viewer/index.html
@@ -1 +1 @@
-osm_viewer - Rust
\ No newline at end of file
+osm_viewer - Rust
\ No newline at end of file
diff --git a/rustdoc/osm_viewer/viewer/index.html b/rustdoc/osm_viewer/viewer/index.html
index e97bb901be..377ded2744 100644
--- a/rustdoc/osm_viewer/viewer/index.html
+++ b/rustdoc/osm_viewer/viewer/index.html
@@ -1 +1 @@
-osm_viewer::viewer - Rust
\ No newline at end of file
+osm_viewer::viewer - Rust
\ No newline at end of file
diff --git a/rustdoc/osm_viewer/viewer/struct.BusinessSearch.html b/rustdoc/osm_viewer/viewer/struct.BusinessSearch.html
index f3fc36df86..49cb95b782 100644
--- a/rustdoc/osm_viewer/viewer/struct.BusinessSearch.html
+++ b/rustdoc/osm_viewer/viewer/struct.BusinessSearch.html
@@ -1,9 +1,9 @@
-BusinessSearch in osm_viewer::viewer - Rust Struct osm_viewer::viewer::BusinessSearch
source · [−]struct BusinessSearch {
+BusinessSearch in osm_viewer::viewer - Rust Struct osm_viewer::viewer::BusinessSearch
source · [−]struct BusinessSearch {
counts: Counter<String>,
show: BTreeSet<String>,
highlight: Drawable,
hovering_on_amenity: Option<(String, Drawable)>,
-}
Fields
counts: Counter<String>
show: BTreeSet<String>
highlight: Drawable
hovering_on_amenity: Option<(String, Drawable)>
Implementations
sourceimpl BusinessSearch
sourcefn new(ctx: &mut EventCtx<'_>, app: &SimpleApp<()>) -> BusinessSearch
sourcefn update(&mut self, ctx: &mut EventCtx<'_>, app: &SimpleApp<()>)
sourcefn hovering_on_amenity(
&mut self,
ctx: &mut EventCtx<'_>,
app: &SimpleApp<()>,
amenity: Option<String>
)
sourcefn render(&self, ctx: &mut EventCtx<'_>) -> Widget
Auto Trait Implementations
impl RefUnwindSafe for BusinessSearch
impl !Send for BusinessSearch
impl !Sync for BusinessSearch
impl Unpin for BusinessSearch
impl UnwindSafe for BusinessSearch
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
+}Fields
counts: Counter<String>
show: BTreeSet<String>
highlight: Drawable
hovering_on_amenity: Option<(String, Drawable)>
Implementations
sourceimpl BusinessSearch
sourcefn new(ctx: &mut EventCtx<'_>, app: &SimpleApp<()>) -> BusinessSearch
sourcefn update(&mut self, ctx: &mut EventCtx<'_>, app: &SimpleApp<()>)
sourcefn hovering_on_amenity(
&mut self,
ctx: &mut EventCtx<'_>,
app: &SimpleApp<()>,
amenity: Option<String>
)
sourcefn render(&self, ctx: &mut EventCtx<'_>) -> Widget
Auto Trait Implementations
impl RefUnwindSafe for BusinessSearch
impl !Send for BusinessSearch
impl !Sync for BusinessSearch
impl Unpin for BusinessSearch
impl UnwindSafe for BusinessSearch
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read morefn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert &mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
diff --git a/rustdoc/osm_viewer/viewer/struct.MinimapController.html b/rustdoc/osm_viewer/viewer/struct.MinimapController.html
index c9a971420b..2e8e5ad607 100644
--- a/rustdoc/osm_viewer/viewer/struct.MinimapController.html
+++ b/rustdoc/osm_viewer/viewer/struct.MinimapController.html
@@ -1,5 +1,5 @@
-MinimapController in osm_viewer::viewer - Rust Struct osm_viewer::viewer::MinimapController
source · [−]struct MinimapController;
Trait Implementations
sourceimpl MinimapControls<SimpleApp<()>> for MinimapController
sourcefn has_zorder(&self, _: &SimpleApp<()>) -> bool
Should the user be able to control the z-order visible? The control is only present when
-zoomed in, placed beneath the zoom column. Read moresourcefn make_legend(&self, _: &mut EventCtx<'_>, _: &SimpleApp<()>) -> Widget
A row beneath the minimap in the zoomed view, usually used as a legend for things on the
+MinimapController in osm_viewer::viewer - Rust Struct osm_viewer::viewer::MinimapController
source · [−]struct MinimapController;
Trait Implementations
sourceimpl MinimapControls<SimpleApp<()>> for MinimapController
sourcefn has_zorder(&self, _: &SimpleApp<()>) -> bool
Should the user be able to control the z-order visible? The control is only present when
+zoomed in, placed beneath the zoom column. Read moresourcefn make_legend(&self, _: &mut EventCtx<'_>, _: &SimpleApp<()>) -> Widget
A row beneath the minimap in the zoomed view, usually used as a legend for things on the
minimap. Read morefn has_layer(&self, &A) -> bool
Is there some additional layer displayed on the minimap? If this changes, the panel gets
recalculated. Read morefn draw_extra(&self, &mut GfxCtx<'_>, &A)
Draw extra stuff on the minimap, just pulling from the app.fn make_unzoomed_panel(&self, ctx: &mut EventCtx<'_>, &A) -> Panel
When unzoomed, display this panel. By default, no controls when unzoomed.fn make_zoomed_side_panel(&self, &mut EventCtx<'_>, &A) -> Widget
Controls to be placed to the left to the zoomed-in panelfn panel_clicked(&self, &mut EventCtx<'_>, &mut A, &str) -> Option<Transition<A>>
If a button is clicked that was produced by some method in this trait, respond to it here.fn panel_changed(&self, &mut EventCtx<'_>, &mut A, &Panel)
Called for Outcome::Changed
on the panel.Auto Trait Implementations
impl RefUnwindSafe for MinimapController
impl Send for MinimapController
impl Sync for MinimapController
impl Unpin for MinimapController
impl UnwindSafe for MinimapController
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
diff --git a/rustdoc/osm_viewer/viewer/struct.Viewer.html b/rustdoc/osm_viewer/viewer/struct.Viewer.html
index 899092f83e..dcacf97352 100644
--- a/rustdoc/osm_viewer/viewer/struct.Viewer.html
+++ b/rustdoc/osm_viewer/viewer/struct.Viewer.html
@@ -3,7 +3,7 @@
fixed_object_outline: Option<Drawable>,
minimap: Minimap<SimpleApp<()>, MinimapController>,
businesses: Option<BusinessSearch>,
-}Fields
top_panel: Panel
fixed_object_outline: Option<Drawable>
minimap: Minimap<SimpleApp<()>, MinimapController>
businesses: Option<BusinessSearch>
Implementations
Trait Implementations
sourceimpl State<SimpleApp<()>> for Viewer
sourcefn event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<()>
) -> Transition<SimpleApp<()>>
Respond to a UI event, such as input or time passing.sourcefn draw_baselayer(&self) -> DrawBaselayer
Specifies what to draw before draw()fn on_destroy(&mut self, &mut EventCtx<'_>, &mut A)
Before this state is popped or replaced, call this.fn recreate(
&mut self,
&mut EventCtx<'_>,
&mut A
) -> Box<dyn State<A> + 'static, Global>
Respond to Transition::Recreate
by assuming state in the app has changed, but preserving
+}Fields
top_panel: Panel
fixed_object_outline: Option<Drawable>
minimap: Minimap<SimpleApp<()>, MinimapController>
businesses: Option<BusinessSearch>
Implementations
Trait Implementations
sourceimpl State<SimpleApp<()>> for Viewer
sourcefn event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<()>
) -> Transition<SimpleApp<()>>
Respond to a UI event, such as input or time passing.sourcefn draw_baselayer(&self) -> DrawBaselayer
Specifies what to draw before draw()fn on_destroy(&mut self, &mut EventCtx<'_>, &mut A)
Before this state is popped or replaced, call this.Auto Trait Implementations
impl !RefUnwindSafe for Viewer
impl !Send for Viewer
impl !Sync for Viewer
impl Unpin for Viewer
impl !UnwindSafe for Viewer
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
diff --git a/rustdoc/parking_mapper/fn.main.html b/rustdoc/parking_mapper/fn.main.html
index 98df881e89..f41db37d70 100644
--- a/rustdoc/parking_mapper/fn.main.html
+++ b/rustdoc/parking_mapper/fn.main.html
@@ -1 +1 @@
-main in parking_mapper - Rust Function parking_mapper::main
source · [−]pub(crate) fn main()
\ No newline at end of file
+main in parking_mapper - Rust Function parking_mapper::main
source · [−]pub(crate) fn main()
\ No newline at end of file
diff --git a/rustdoc/parking_mapper/index.html b/rustdoc/parking_mapper/index.html
index b57503ca87..372afeb3bc 100644
--- a/rustdoc/parking_mapper/index.html
+++ b/rustdoc/parking_mapper/index.html
@@ -1 +1 @@
-parking_mapper - Rust
\ No newline at end of file
+parking_mapper - Rust
\ No newline at end of file
diff --git a/rustdoc/parking_mapper/mapper/fn.find_divided_highways.html b/rustdoc/parking_mapper/mapper/fn.find_divided_highways.html
index be0f4cc0ea..7a3a3c0752 100644
--- a/rustdoc/parking_mapper/mapper/fn.find_divided_highways.html
+++ b/rustdoc/parking_mapper/mapper/fn.find_divided_highways.html
@@ -1 +1 @@
-find_divided_highways in parking_mapper::mapper - Rust Function parking_mapper::mapper::find_divided_highways
source · [−]
\ No newline at end of file
+find_divided_highways in parking_mapper::mapper - Rust Function parking_mapper::mapper::find_divided_highways
source · [−]
\ No newline at end of file
diff --git a/rustdoc/parking_mapper/mapper/fn.find_overlapping_stuff.html b/rustdoc/parking_mapper/mapper/fn.find_overlapping_stuff.html
index 357da8094a..edb4bca6cf 100644
--- a/rustdoc/parking_mapper/mapper/fn.find_overlapping_stuff.html
+++ b/rustdoc/parking_mapper/mapper/fn.find_overlapping_stuff.html
@@ -1 +1 @@
-find_overlapping_stuff in parking_mapper::mapper - Rust
\ No newline at end of file
+find_overlapping_stuff in parking_mapper::mapper - Rust
\ No newline at end of file
diff --git a/rustdoc/parking_mapper/mapper/fn.generate_osmc.html b/rustdoc/parking_mapper/mapper/fn.generate_osmc.html
index 1dc54e8f26..c58c183bc1 100644
--- a/rustdoc/parking_mapper/mapper/fn.generate_osmc.html
+++ b/rustdoc/parking_mapper/mapper/fn.generate_osmc.html
@@ -1 +1 @@
-generate_osmc in parking_mapper::mapper - Rust Function parking_mapper::mapper::generate_osmc
source · [−]
\ No newline at end of file
+generate_osmc in parking_mapper::mapper - Rust Function parking_mapper::mapper::generate_osmc
source · [−]
\ No newline at end of file
diff --git a/rustdoc/parking_mapper/mapper/index.html b/rustdoc/parking_mapper/mapper/index.html
index d9dbb5a843..a250ad3851 100644
--- a/rustdoc/parking_mapper/mapper/index.html
+++ b/rustdoc/parking_mapper/mapper/index.html
@@ -1 +1 @@
-parking_mapper::mapper - Rust
\ No newline at end of file
+parking_mapper::mapper - Rust
\ No newline at end of file
diff --git a/rustdoc/parking_mapper/mapper/struct.ChangeWay.html b/rustdoc/parking_mapper/mapper/struct.ChangeWay.html
index d523ab008b..aed9dc1864 100644
--- a/rustdoc/parking_mapper/mapper/struct.ChangeWay.html
+++ b/rustdoc/parking_mapper/mapper/struct.ChangeWay.html
@@ -1,10 +1,10 @@
-ChangeWay in parking_mapper::mapper - Rust Struct parking_mapper::mapper::ChangeWay
source · [−]struct ChangeWay {
+ChangeWay in parking_mapper::mapper - Rust Struct parking_mapper::mapper::ChangeWay
source · [−]struct ChangeWay {
panel: Panel,
draw: Drawable,
osm_way_id: WayID,
data: BTreeMap<WayID, Value>,
show: Show,
-}
Fields
panel: Panel
draw: Drawable
osm_way_id: WayID
data: BTreeMap<WayID, Value>
show: Show
Implementations
Trait Implementations
sourceimpl State<SimpleApp<()>> for ChangeWay
sourcefn event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<()>
) -> Transition<SimpleApp<()>>
Respond to a UI event, such as input or time passing.fn draw_baselayer(&self) -> DrawBaselayer
Specifies what to draw before draw()fn on_destroy(&mut self, &mut EventCtx<'_>, &mut A)
Before this state is popped or replaced, call this.fn recreate(
&mut self,
&mut EventCtx<'_>,
&mut A
) -> Box<dyn State<A> + 'static, Global>
Respond to Transition::Recreate
by assuming state in the app has changed, but preserving
+}Fields
panel: Panel
draw: Drawable
osm_way_id: WayID
data: BTreeMap<WayID, Value>
show: Show
Implementations
Trait Implementations
sourceimpl State<SimpleApp<()>> for ChangeWay
sourcefn event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<()>
) -> Transition<SimpleApp<()>>
Respond to a UI event, such as input or time passing.fn draw_baselayer(&self) -> DrawBaselayer
Specifies what to draw before draw()fn on_destroy(&mut self, &mut EventCtx<'_>, &mut A)
Before this state is popped or replaced, call this.Auto Trait Implementations
impl !RefUnwindSafe for ChangeWay
impl !Send for ChangeWay
impl !Sync for ChangeWay
impl Unpin for ChangeWay
impl !UnwindSafe for ChangeWay
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
diff --git a/rustdoc/parking_mapper/mapper/struct.ParkingMapper.html b/rustdoc/parking_mapper/mapper/struct.ParkingMapper.html
index f36f723c03..72e7781029 100644
--- a/rustdoc/parking_mapper/mapper/struct.ParkingMapper.html
+++ b/rustdoc/parking_mapper/mapper/struct.ParkingMapper.html
@@ -4,7 +4,7 @@
show: Show,
selected: Option<(HashSet<RoadID>, Drawable)>,
data: BTreeMap<WayID, Value>,
-}Fields
panel: Panel
draw_layer: Drawable
show: Show
selected: Option<(HashSet<RoadID>, Drawable)>
data: BTreeMap<WayID, Value>
Implementations
Trait Implementations
sourceimpl State<SimpleApp<()>> for ParkingMapper
sourcefn event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<()>
) -> Transition<SimpleApp<()>>
Respond to a UI event, such as input or time passing.fn draw_baselayer(&self) -> DrawBaselayer
Specifies what to draw before draw()fn on_destroy(&mut self, &mut EventCtx<'_>, &mut A)
Before this state is popped or replaced, call this.fn recreate(
&mut self,
&mut EventCtx<'_>,
&mut A
) -> Box<dyn State<A> + 'static, Global>
Respond to Transition::Recreate
by assuming state in the app has changed, but preserving
+}Fields
panel: Panel
draw_layer: Drawable
show: Show
selected: Option<(HashSet<RoadID>, Drawable)>
data: BTreeMap<WayID, Value>
Implementations
Trait Implementations
sourceimpl State<SimpleApp<()>> for ParkingMapper
sourcefn event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<()>
) -> Transition<SimpleApp<()>>
Respond to a UI event, such as input or time passing.fn draw_baselayer(&self) -> DrawBaselayer
Specifies what to draw before draw()fn on_destroy(&mut self, &mut EventCtx<'_>, &mut A)
Before this state is popped or replaced, call this.Auto Trait Implementations
impl !RefUnwindSafe for ParkingMapper
impl !Send for ParkingMapper
impl !Sync for ParkingMapper
impl Unpin for ParkingMapper
impl !UnwindSafe for ParkingMapper
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
diff --git a/rustdoc/santa/fn.run.html b/rustdoc/santa/fn.run.html
index a77d8f8be7..113fd6d3f1 100644
--- a/rustdoc/santa/fn.run.html
+++ b/rustdoc/santa/fn.run.html
@@ -1 +1 @@
-run in santa - Rust
\ No newline at end of file
+run in santa - Rust
\ No newline at end of file
diff --git a/rustdoc/santa/index.html b/rustdoc/santa/index.html
index 95fea0d643..08f96086fb 100644
--- a/rustdoc/santa/index.html
+++ b/rustdoc/santa/index.html
@@ -1 +1 @@
-santa - Rust
\ No newline at end of file
+santa - Rust
\ No newline at end of file
diff --git a/rustdoc/santa/title/fn.level_btn.html b/rustdoc/santa/title/fn.level_btn.html
index 9116a36fdf..04a9bcf87e 100644
--- a/rustdoc/santa/title/fn.level_btn.html
+++ b/rustdoc/santa/title/fn.level_btn.html
@@ -1 +1 @@
-level_btn in santa::title - Rust
\ No newline at end of file
+level_btn in santa::title - Rust
\ No newline at end of file
diff --git a/rustdoc/santa/title/fn.link.html b/rustdoc/santa/title/fn.link.html
index 248aad766d..7b13e38ea6 100644
--- a/rustdoc/santa/title/fn.link.html
+++ b/rustdoc/santa/title/fn.link.html
@@ -1 +1 @@
-link in santa::title - Rust
\ No newline at end of file
+link in santa::title - Rust
\ No newline at end of file
diff --git a/rustdoc/santa/title/fn.locked_level.html b/rustdoc/santa/title/fn.locked_level.html
index 324d899fd2..ff5af96f69 100644
--- a/rustdoc/santa/title/fn.locked_level.html
+++ b/rustdoc/santa/title/fn.locked_level.html
@@ -1 +1 @@
-locked_level in santa::title - Rust
\ No newline at end of file
+locked_level in santa::title - Rust
\ No newline at end of file
diff --git a/rustdoc/santa/title/fn.unlocked_level.html b/rustdoc/santa/title/fn.unlocked_level.html
index 44df15af75..d6a01fd491 100644
--- a/rustdoc/santa/title/fn.unlocked_level.html
+++ b/rustdoc/santa/title/fn.unlocked_level.html
@@ -1 +1 @@
-unlocked_level in santa::title - Rust
\ No newline at end of file
+unlocked_level in santa::title - Rust
\ No newline at end of file
diff --git a/rustdoc/santa/title/index.html b/rustdoc/santa/title/index.html
index 789a0fcaaa..15b834e206 100644
--- a/rustdoc/santa/title/index.html
+++ b/rustdoc/santa/title/index.html
@@ -1 +1 @@
-santa::title - Rust
\ No newline at end of file
+santa::title - Rust
\ No newline at end of file
diff --git a/rustdoc/santa/title/struct.Credits.html b/rustdoc/santa/title/struct.Credits.html
index 73a9c4c822..11bd2d3e2e 100644
--- a/rustdoc/santa/title/struct.Credits.html
+++ b/rustdoc/santa/title/struct.Credits.html
@@ -1,6 +1,6 @@
-Credits in santa::title - Rust struct Credits;
Implementations
Trait Implementations
sourceimpl SimpleState<SimpleApp<Session>> for Credits
sourcefn on_click(
&mut self,
_: &mut EventCtx<'_>,
_: &mut SimpleApp<Session>,
x: &str,
_: &mut Panel
) -> Transition<SimpleApp<Session>>
Called when something on the panel has been clicked. Since the action is just a string,
-the fallback case can just use unreachable!()
. Read moresourcefn other_event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<Session>
) -> Transition<SimpleApp<Session>>
If a panel on_click
event didn’t occur and panel_changed
didn’t return transition, then
-call this to handle all other events. Read moresourcefn draw(&self, g: &mut GfxCtx<'_>, app: &SimpleApp<Session>)
fn on_click_custom(
&mut self,
_ctx: &mut EventCtx<'_>,
_app: &mut A,
_action: Box<dyn CloneableAny + 'static, Global>,
_panel: &mut Panel
) -> Transition<A>
Called when something on the panel has been clicked.fn panel_changed(
&mut self,
&mut EventCtx<'_>,
&mut A,
&mut Panel
) -> Option<Transition<A>>
Called when something on the panel has changed. If a transition is returned, stop handling
+Credits in santa::title - Rust struct Credits;
Implementations
Trait Implementations
sourceimpl SimpleState<SimpleApp<Session>> for Credits
sourcefn on_click(
&mut self,
_: &mut EventCtx<'_>,
_: &mut SimpleApp<Session>,
x: &str,
_: &mut Panel
) -> Transition<SimpleApp<Session>>
Called when something on the panel has been clicked. Since the action is just a string,
+the fallback case can just use unreachable!()
. Read moresourcefn other_event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<Session>
) -> Transition<SimpleApp<Session>>
If a panel on_click
event didn’t occur and panel_changed
didn’t return transition, then
+call this to handle all other events. Read moresourcefn draw(&self, g: &mut GfxCtx<'_>, app: &SimpleApp<Session>)
fn on_click_custom(
&mut self,
_ctx: &mut EventCtx<'_>,
_app: &mut A,
_action: Box<dyn CloneableAny + 'static, Global>,
_panel: &mut Panel
) -> Transition<A>
Called when something on the panel has been clicked.fn panel_changed(
&mut self,
&mut EventCtx<'_>,
&mut A,
&mut Panel
) -> Option<Transition<A>>
Called when something on the panel has changed. If a transition is returned, stop handling
the event and immediately apply the transition. Read morefn on_mouseover(&mut self, &mut EventCtx<'_>, &mut A)
Called when the mouse has moved.fn draw_baselayer(&self) -> DrawBaselayer
Auto Trait Implementations
impl RefUnwindSafe for Credits
impl Send for Credits
impl Sync for Credits
impl Unpin for Credits
impl UnwindSafe for Credits
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
diff --git a/rustdoc/santa/title/struct.TitleScreen.html b/rustdoc/santa/title/struct.TitleScreen.html
index 3195520a62..94b86e0829 100644
--- a/rustdoc/santa/title/struct.TitleScreen.html
+++ b/rustdoc/santa/title/struct.TitleScreen.html
@@ -1,6 +1,6 @@
-TitleScreen in santa::title - Rust Struct santa::title::TitleScreen
source · [−]pub struct TitleScreen;
Implementations
Trait Implementations
sourceimpl SimpleState<SimpleApp<Session>> for TitleScreen
sourcefn on_click(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<Session>,
x: &str,
_: &mut Panel
) -> Transition<SimpleApp<Session>>
Called when something on the panel has been clicked. Since the action is just a string,
-the fallback case can just use unreachable!()
. Read moresourcefn other_event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<Session>
) -> Transition<SimpleApp<Session>>
If a panel on_click
event didn’t occur and panel_changed
didn’t return transition, then
-call this to handle all other events. Read moresourcefn draw(&self, g: &mut GfxCtx<'_>, app: &SimpleApp<Session>)
fn on_click_custom(
&mut self,
_ctx: &mut EventCtx<'_>,
_app: &mut A,
_action: Box<dyn CloneableAny + 'static, Global>,
_panel: &mut Panel
) -> Transition<A>
Called when something on the panel has been clicked.fn panel_changed(
&mut self,
&mut EventCtx<'_>,
&mut A,
&mut Panel
) -> Option<Transition<A>>
Called when something on the panel has changed. If a transition is returned, stop handling
+TitleScreen in santa::title - Rust Struct santa::title::TitleScreen
source · [−]pub struct TitleScreen;
Implementations
Trait Implementations
sourceimpl SimpleState<SimpleApp<Session>> for TitleScreen
sourcefn on_click(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<Session>,
x: &str,
_: &mut Panel
) -> Transition<SimpleApp<Session>>
Called when something on the panel has been clicked. Since the action is just a string,
+the fallback case can just use unreachable!()
. Read moresourcefn other_event(
&mut self,
ctx: &mut EventCtx<'_>,
app: &mut SimpleApp<Session>
) -> Transition<SimpleApp<Session>>
If a panel on_click
event didn’t occur and panel_changed
didn’t return transition, then
+call this to handle all other events. Read moresourcefn draw(&self, g: &mut GfxCtx<'_>, app: &SimpleApp<Session>)
fn on_click_custom(
&mut self,
_ctx: &mut EventCtx<'_>,
_app: &mut A,
_action: Box<dyn CloneableAny + 'static, Global>,
_panel: &mut Panel
) -> Transition<A>
Called when something on the panel has been clicked.fn panel_changed(
&mut self,
&mut EventCtx<'_>,
&mut A,
&mut Panel
) -> Option<Transition<A>>
Called when something on the panel has changed. If a transition is returned, stop handling
the event and immediately apply the transition. Read morefn on_mouseover(&mut self, &mut EventCtx<'_>, &mut A)
Called when the mouse has moved.fn draw_baselayer(&self) -> DrawBaselayer
Auto Trait Implementations
impl RefUnwindSafe for TitleScreen
impl Send for TitleScreen
impl Sync for TitleScreen
impl Unpin for TitleScreen
impl UnwindSafe for TitleScreen
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
diff --git a/rustdoc/sim/analytics/struct.Analytics.html b/rustdoc/sim/analytics/struct.Analytics.html
index e8755b5ab0..14334fd296 100644
--- a/rustdoc/sim/analytics/struct.Analytics.html
+++ b/rustdoc/sim/analytics/struct.Analytics.html
@@ -7,7 +7,7 @@
pub passengers_boarding: BTreeMap<TransitStopID, Vec<(Time, TransitRouteID, Duration)>>,
pub passengers_alighting: BTreeMap<TransitStopID, Vec<(Time, TransitRouteID)>>,
pub started_trips: BTreeMap<TripID, Time>,
- pub finished_trips: Vec<(Time, TripID, TripMode, Option<Duration>)>,
+ pub finished_trips: Vec<(Time, TripID, TripMode, Option<Duration>)>,
pub problems_per_trip: BTreeMap<TripID, Vec<(Time, Problem)>>,
pub trip_log: Vec<(Time, TripID, Option<PathRequest>, TripPhaseType)>,
pub intersection_delays: BTreeMap<IntersectionID, Vec<(u8, Time, Duration, AgentType)>>,
@@ -25,13 +25,13 @@ running the simulation, and compare the live Analytics to the prebaked baseline
Fields
road_thruput: TimeSeriesCount<RoadID>
intersection_thruput: TimeSeriesCount<IntersectionID>
traffic_signal_thruput: TimeSeriesCount<CompressedMovementID>
demand: BTreeMap<MovementID, usize>
Most fields in Analytics are cumulative over time, but this is just for the current moment
in time.
bus_arrivals: Vec<(Time, CarID, TransitRouteID, TransitStopID)>
passengers_boarding: BTreeMap<TransitStopID, Vec<(Time, TransitRouteID, Duration)>>
For each passenger boarding, how long did they wait at the stop?
-passengers_alighting: BTreeMap<TransitStopID, Vec<(Time, TransitRouteID)>>
started_trips: BTreeMap<TripID, Time>
finished_trips: Vec<(Time, TripID, TripMode, Option<Duration>)>
Finish time, ID, mode, trip duration if successful (or None if cancelled)
+passengers_alighting: BTreeMap<TransitStopID, Vec<(Time, TransitRouteID)>>
started_trips: BTreeMap<TripID, Time>
finished_trips: Vec<(Time, TripID, TripMode, Option<Duration>)>
Finish time, ID, mode, trip duration if successful (or None if cancelled)
problems_per_trip: BTreeMap<TripID, Vec<(Time, Problem)>>
Record different problems that each trip encounters.
trip_log: Vec<(Time, TripID, Option<PathRequest>, TripPhaseType)>
intersection_delays: BTreeMap<IntersectionID, Vec<(u8, Time, Duration, AgentType)>>
Only for traffic signals. The u8 is the movement index from a CompressedMovementID.
parking_lane_changes: BTreeMap<LaneID, Vec<(Time, bool)>>
Per parking lane or lot, when does a spot become filled (true) or free (false)
parking_lot_changes: BTreeMap<ParkingLotID, Vec<(Time, bool)>>
alerts: Vec<(Time, AlertLocation, String)>
record_anything: bool
For benchmarking, we may want to disable collecting data.
Implementations
sourceimpl Analytics
sourcepub fn new(record_anything: bool) -> Analytics
sourcepub fn event(&mut self, ev: Event, time: Time, map: &Map)
sourcepub fn record_demand(&mut self, path: &Path, map: &Map)
sourcepub fn finished_trip_time(&self, trip: TripID) -> Option<Duration>
Ignores the current time. Returns None for cancelled trips.
-sourcepub fn both_finished_trips(
&self,
now: Time,
before: &Analytics
) -> Vec<(TripID, Duration, Duration, TripMode)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
Returns pairs of trip times for finished trips in both worlds. (ID, before, after, mode)
+sourcepub fn both_finished_trips(
&self,
now: Time,
before: &Analytics
) -> Vec<(TripID, Duration, Duration, TripMode)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
Returns pairs of trip times for finished trips in both worlds. (ID, before, after, mode)
sourcepub fn get_trip_phases(&self, trip: TripID, map: &Map) -> Vec<TripPhase>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
If calling on prebaked Analytics, be careful to pass in an unedited map, to match how the
simulation was originally run. Otherwise the paths may be nonsense.
sourcepub fn get_all_trip_phases(&self) -> BTreeMap<TripID, Vec<TripPhase>>
sourcepub fn active_agents(&self, now: Time) -> Vec<(Time, usize)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn parking_lane_availability(
&self,
now: Time,
l: LaneID,
capacity: usize
) -> Vec<(Time, usize)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
Returns the free spots over time
diff --git a/rustdoc/sim/events/enum.Event.html b/rustdoc/sim/events/enum.Event.html
index cd6484ae3b..a3a9c13b1b 100644
--- a/rustdoc/sim/events/enum.Event.html
+++ b/rustdoc/sim/events/enum.Event.html
@@ -16,11 +16,11 @@
IntersectionDelayMeasured(TripID, TurnID, AgentID, Duration),
TripFinished {
trip: TripID,
- mode: TripMode,
+ mode: TripMode,
total_time: Duration,
blocked_time: Duration,
},
- TripCancelled(TripID, TripMode),
+ TripCancelled(TripID, TripMode),
TripPhaseStarting(TripID, PersonID, Option<PathRequest>, TripPhaseType),
PathAmended(Path),
Alert(AlertLocation, String),
@@ -35,7 +35,7 @@ has no performance impact.
PersonEntersMap(PersonID, AgentID, IntersectionID)
PedReachedParkingSpot(PedestrianID, ParkingSpot)
BikeStoppedAtSidewalk(CarID, LaneID)
ProblemEncountered(TripID, Problem)
AgentEntersTraversable(AgentID, Option<TripID>, Traversable, Option<usize>)
If the agent is a transit vehicle, then include a count of how many passengers are on
board.
IntersectionDelayMeasured(TripID, TurnID, AgentID, Duration)
TripID, TurnID (Where the delay was encountered), Time spent waiting at that turn
-TripFinished
TripCancelled(TripID, TripMode)
TripPhaseStarting(TripID, PersonID, Option<PathRequest>, TripPhaseType)
PathAmended(Path)
Just use for parking replanning. Not happy about copying the full path in here, but the way
+
TripFinished
TripCancelled(TripID, TripMode)
TripPhaseStarting(TripID, PersonID, Option<PathRequest>, TripPhaseType)
PathAmended(Path)
Just use for parking replanning. Not happy about copying the full path in here, but the way
to plumb info into Analytics is Event.
Alert(AlertLocation, String)
Trait Implementations
sourceimpl<'de> Deserialize<'de> for Event
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read moresourceimpl PartialEq<Event> for Event
1.0.0 · sourcefn ne(&self, other: &Rhs) -> bool
This method tests for !=
. The default implementation is almost always
diff --git a/rustdoc/sim/fn.count_parked_cars_per_bldg.html b/rustdoc/sim/fn.count_parked_cars_per_bldg.html
index bc672ac510..62cd7c2de0 100644
--- a/rustdoc/sim/fn.count_parked_cars_per_bldg.html
+++ b/rustdoc/sim/fn.count_parked_cars_per_bldg.html
@@ -1 +1 @@
-count_parked_cars_per_bldg in sim - Rust Function sim::count_parked_cars_per_bldg
source · [−]pub fn count_parked_cars_per_bldg(scenario: &Scenario) -> Counter<BuildingID>
\ No newline at end of file
+count_parked_cars_per_bldg in sim - Rust Function sim::count_parked_cars_per_bldg
source · [−]pub fn count_parked_cars_per_bldg(scenario: &Scenario) -> Counter<BuildingID>
\ No newline at end of file
diff --git a/rustdoc/sim/fn.fork_rng.html b/rustdoc/sim/fn.fork_rng.html
index 745ae18240..f468b42e6f 100644
--- a/rustdoc/sim/fn.fork_rng.html
+++ b/rustdoc/sim/fn.fork_rng.html
@@ -1,3 +1,3 @@
-fork_rng in sim - Rust pub fn fork_rng(base_rng: &mut XorShiftRng) -> XorShiftRng
Expand description
Need to explain this trick – basically keeps consistency between two different simulations when
+
fork_rng in sim - Rust pub fn fork_rng(base_rng: &mut XorShiftRng) -> XorShiftRng
Expand description
Need to explain this trick – basically keeps consistency between two different simulations when
each one might make slightly different sequences of calls to the RNG.
\ No newline at end of file
diff --git a/rustdoc/sim/make/load/fn.parse_modifiers.html b/rustdoc/sim/make/load/fn.parse_modifiers.html
index c2887e3809..b4c969a01c 100644
--- a/rustdoc/sim/make/load/fn.parse_modifiers.html
+++ b/rustdoc/sim/make/load/fn.parse_modifiers.html
@@ -1 +1 @@
-parse_modifiers in sim::make::load - Rust fn parse_modifiers(x: &str) -> Result<Vec<ScenarioModifier>>
\ No newline at end of file
+parse_modifiers in sim::make::load - Rust
\ No newline at end of file
diff --git a/rustdoc/sim/make/load/struct.SimFlags.html b/rustdoc/sim/make/load/struct.SimFlags.html
index a8122a2416..8e3a8a688b 100644
--- a/rustdoc/sim/make/load/struct.SimFlags.html
+++ b/rustdoc/sim/make/load/struct.SimFlags.html
@@ -1,7 +1,7 @@
SimFlags in sim::make::load - Rust pub struct SimFlags {
load_path: Option<String>,
pub load: String,
- pub scenario_modifiers: Vec<ScenarioModifier>,
+ pub scenario_modifiers: Vec<ScenarioModifier>,
pub rng_seed: u64,
pub opts: SimOptions,
}
Expand description
SimFlags specifies a simulation to setup. After parsing from structopt, you must call
@@ -14,7 +14,7 @@
load: String
The same as load_path
, but with a default value filled out. Call initialize
to set this
up.
-scenario_modifiers: Vec<ScenarioModifier>
A JSON list of modifiers to transform the scenario. These can be generated with the GUI.
+scenario_modifiers: Vec<ScenarioModifier>
A JSON list of modifiers to transform the scenario. These can be generated with the GUI.
rng_seed: u64
An arbitrary number to seed the random number generator. This is input to the deterministic
simulation, so different values affect results.
opts: SimOptions
Implementations
sourceimpl SimFlags
sourcepub const RNG_SEED: u64 = 42u64
sourcepub fn initialize(&mut self)
sourcepub fn for_test(run_name: &str) -> SimFlags
sourcepub fn make_rng(&self) -> XorShiftRng
sourcepub fn load_synchronously(
&self,
timer: &mut Timer<'_>
) -> (Map, Sim, XorShiftRng)
Loads a map and simulation. Not appropriate for use in the UI or on web.
diff --git a/rustdoc/sim/make/load/type.ModifierList.html b/rustdoc/sim/make/load/type.ModifierList.html
index 800244ef58..b4150eb6bf 100644
--- a/rustdoc/sim/make/load/type.ModifierList.html
+++ b/rustdoc/sim/make/load/type.ModifierList.html
@@ -1 +1 @@
-ModifierList in sim::make::load - Rust type ModifierList = Vec<ScenarioModifier>;
\ No newline at end of file
+ModifierList in sim::make::load - Rust
\ No newline at end of file
diff --git a/rustdoc/sim/make/spawner/enum.TripSpec.html b/rustdoc/sim/make/spawner/enum.TripSpec.html
index a06aca70c8..14193d833f 100644
--- a/rustdoc/sim/make/spawner/enum.TripSpec.html
+++ b/rustdoc/sim/make/spawner/enum.TripSpec.html
@@ -34,7 +34,7 @@
retry_if_no_room: bool
Can be used to spawn from a border or anywhere for interactive debugging.
SpawningFailure
Something went wrong spawning the trip.
UsingParkedCar
JustWalking
UsingBike
UsingTransit
Implementations
sourceimpl TripSpec
sourcepub fn into_plan(self, map: &Map) -> (TripSpec, Vec<TripLeg>)
sourcepub fn maybe_new(
from: TripEndpoint,
to: TripEndpoint,
mode: TripMode,
use_vehicle: Option<CarID>,
retry_if_no_room: bool,
map: &Map
) -> Result<TripSpec>
Turn an origin/destination pair and mode into a specific plan for instantiating a trip.
+
goal: DrivingGoal
JustWalking
UsingBike
UsingTransit
Implementations
sourceimpl TripSpec
sourcepub fn into_plan(self, map: &Map) -> (TripSpec, Vec<TripLeg>)
sourcepub fn maybe_new(
from: TripEndpoint,
to: TripEndpoint,
mode: TripMode,
use_vehicle: Option<CarID>,
retry_if_no_room: bool,
map: &Map
) -> Result<TripSpec>
Turn an origin/destination pair and mode into a specific plan for instantiating a trip.
Decisions like how to use public transit happen here.
Trait Implementations
sourceimpl<'de> Deserialize<'de> for TripSpec
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read moresourceimpl PartialEq<TripSpec> for TripSpec
1.0.0 · sourcefn ne(&self, other: &Rhs) -> bool
This method tests for !=
. The default implementation is almost always
diff --git a/rustdoc/sim/make/spawner/fn.driving_goal.html b/rustdoc/sim/make/spawner/fn.driving_goal.html
index 8b9af64b8f..43b0f08f94 100644
--- a/rustdoc/sim/make/spawner/fn.driving_goal.html
+++ b/rustdoc/sim/make/spawner/fn.driving_goal.html
@@ -1 +1 @@
-driving_goal in sim::make::spawner - Rust fn driving_goal(
endpt: TripEndpoint,
constraints: PathConstraints,
map: &Map
) -> Result<DrivingGoal>
\ No newline at end of file
+driving_goal in sim::make::spawner - Rust fn driving_goal(
endpt: TripEndpoint,
constraints: PathConstraints,
map: &Map
) -> Result<DrivingGoal>
\ No newline at end of file
diff --git a/rustdoc/sim/make/spawner/fn.end_sidewalk_spot.html b/rustdoc/sim/make/spawner/fn.end_sidewalk_spot.html
index fd50ed8704..d10d935901 100644
--- a/rustdoc/sim/make/spawner/fn.end_sidewalk_spot.html
+++ b/rustdoc/sim/make/spawner/fn.end_sidewalk_spot.html
@@ -1 +1 @@
-end_sidewalk_spot in sim::make::spawner - Rust fn end_sidewalk_spot(endpt: TripEndpoint, map: &Map) -> Result<SidewalkSpot>
\ No newline at end of file
+end_sidewalk_spot in sim::make::spawner - Rust fn end_sidewalk_spot(endpt: TripEndpoint, map: &Map) -> Result<SidewalkSpot>
\ No newline at end of file
diff --git a/rustdoc/sim/make/spawner/fn.start_sidewalk_spot.html b/rustdoc/sim/make/spawner/fn.start_sidewalk_spot.html
index e8e8323a13..b658d302e8 100644
--- a/rustdoc/sim/make/spawner/fn.start_sidewalk_spot.html
+++ b/rustdoc/sim/make/spawner/fn.start_sidewalk_spot.html
@@ -1 +1 @@
-start_sidewalk_spot in sim::make::spawner - Rust fn start_sidewalk_spot(endpt: TripEndpoint, map: &Map) -> Result<SidewalkSpot>
\ No newline at end of file
+start_sidewalk_spot in sim::make::spawner - Rust fn start_sidewalk_spot(endpt: TripEndpoint, map: &Map) -> Result<SidewalkSpot>
\ No newline at end of file
diff --git a/rustdoc/sim/prebake/fn.prebake.html b/rustdoc/sim/prebake/fn.prebake.html
index d348be4a38..1efd95e6b4 100644
--- a/rustdoc/sim/prebake/fn.prebake.html
+++ b/rustdoc/sim/prebake/fn.prebake.html
@@ -1,3 +1,3 @@
-prebake in sim::prebake - Rust pub fn prebake(
map: &Map,
scenario: Scenario,
timer: &mut Timer<'_>
) -> PrebakeSummary
Expand description
Simulate a curated list of scenarios to completion, and save the analytics as “prebaked
+
prebake in sim::prebake - Rust pub fn prebake(
map: &Map,
scenario: Scenario,
timer: &mut Timer<'_>
) -> PrebakeSummary
Expand description
Simulate a curated list of scenarios to completion, and save the analytics as “prebaked
results,” to later compare simulation metrics against the baseline without map edits.
\ No newline at end of file
diff --git a/rustdoc/sim/prebake/struct.PrebakeSummary.html b/rustdoc/sim/prebake/struct.PrebakeSummary.html
index 954297cf2a..3610c147f8 100644
--- a/rustdoc/sim/prebake/struct.PrebakeSummary.html
+++ b/rustdoc/sim/prebake/struct.PrebakeSummary.html
@@ -4,7 +4,7 @@
pub finished_trips: usize,
pub cancelled_trips: usize,
pub total_trip_duration_seconds: f64,
-}Fields
map: String
scenario: String
finished_trips: usize
cancelled_trips: usize
total_trip_duration_seconds: f64
Implementations
Trait Implementations
sourceimpl Debug for PrebakeSummary
sourceimpl Serialize for PrebakeSummary
Auto Trait Implementations
impl RefUnwindSafe for PrebakeSummary
impl Send for PrebakeSummary
impl Sync for PrebakeSummary
impl Unpin for PrebakeSummary
impl UnwindSafe for PrebakeSummary
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
+}Fields
map: String
scenario: String
finished_trips: usize
cancelled_trips: usize
total_trip_duration_seconds: f64
Implementations
sourceimpl PrebakeSummary
Trait Implementations
sourceimpl Debug for PrebakeSummary
sourceimpl Serialize for PrebakeSummary
Auto Trait Implementations
impl RefUnwindSafe for PrebakeSummary
impl Send for PrebakeSummary
impl Sync for PrebakeSummary
impl Unpin for PrebakeSummary
impl UnwindSafe for PrebakeSummary
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read morefn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert &mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
diff --git a/rustdoc/sim/recorder/struct.TrafficRecorder.html b/rustdoc/sim/recorder/struct.TrafficRecorder.html
index f5cc2efb4e..bb78ba1f18 100644
--- a/rustdoc/sim/recorder/struct.TrafficRecorder.html
+++ b/rustdoc/sim/recorder/struct.TrafficRecorder.html
@@ -1,11 +1,11 @@
TrafficRecorder in sim::recorder - Rust Struct sim::recorder::TrafficRecorder
source · [−]pub(crate) struct TrafficRecorder {
capture_points: BTreeSet<IntersectionID>,
- trips: Vec<IndividTrip>,
+ trips: Vec<IndividTrip>,
seen_trips: BTreeSet<TripID>,
}
Expand description
Records trips beginning and ending at a specified set of intersections. This can be used to
capture and reproduce behavior in a gridlock-prone chunk of the map, without simulating
everything.
-Fields
capture_points: BTreeSet<IntersectionID>
trips: Vec<IndividTrip>
seen_trips: BTreeSet<TripID>
Implementations
sourceimpl TrafficRecorder
sourcepub fn new(capture_points: BTreeSet<IntersectionID>) -> TrafficRecorder
sourcepub fn handle_event(
&mut self,
time: Time,
ev: &Event,
map: &Map,
driving: &DrivingSimState
)
sourcefn on_car_enters_traversable(
&mut self,
time: Time,
car: CarID,
trip: TripID,
on: Traversable,
map: &Map,
driving: &DrivingSimState
)
sourcefn on_car_enters_lane(
&mut self,
time: Time,
car: CarID,
trip: TripID,
lane: LaneID,
map: &Map,
driving: &DrivingSimState
)
sourcepub fn num_recorded_trips(&self) -> usize
sourcepub fn save(self, map: &Map)
Trait Implementations
sourceimpl Clone for TrafficRecorder
sourcefn clone(&self) -> TrafficRecorder
Returns a copy of the value. Read more1.0.0 · sourcefn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read moreAuto Trait Implementations
impl RefUnwindSafe for TrafficRecorder
impl Send for TrafficRecorder
impl Sync for TrafficRecorder
impl Unpin for TrafficRecorder
impl UnwindSafe for TrafficRecorder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
+Fields
capture_points: BTreeSet<IntersectionID>
trips: Vec<IndividTrip>
seen_trips: BTreeSet<TripID>
Implementations
sourceimpl TrafficRecorder
sourcepub fn new(capture_points: BTreeSet<IntersectionID>) -> TrafficRecorder
sourcepub fn handle_event(
&mut self,
time: Time,
ev: &Event,
map: &Map,
driving: &DrivingSimState
)
sourcefn on_car_enters_traversable(
&mut self,
time: Time,
car: CarID,
trip: TripID,
on: Traversable,
map: &Map,
driving: &DrivingSimState
)
sourcefn on_car_enters_lane(
&mut self,
time: Time,
car: CarID,
trip: TripID,
lane: LaneID,
map: &Map,
driving: &DrivingSimState
)
sourcepub fn num_recorded_trips(&self) -> usize
sourcepub fn save(self, map: &Map)
Trait Implementations
sourceimpl Clone for TrafficRecorder
sourcefn clone(&self) -> TrafficRecorder
Returns a copy of the value. Read more1.0.0 · sourcefn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read moreAuto Trait Implementations
impl RefUnwindSafe for TrafficRecorder
impl Send for TrafficRecorder
impl Sync for TrafficRecorder
impl Unpin for TrafficRecorder
impl UnwindSafe for TrafficRecorder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read moreimpl<T> Downcast for Twhere
T: Any,
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert 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
. Read morefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read morefn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read morefn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert &mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
diff --git a/rustdoc/sim/sim/scenario/fn.count_parked_cars_per_bldg.html b/rustdoc/sim/sim/scenario/fn.count_parked_cars_per_bldg.html
index 64ae9dae9d..1dcf43785a 100644
--- a/rustdoc/sim/sim/scenario/fn.count_parked_cars_per_bldg.html
+++ b/rustdoc/sim/sim/scenario/fn.count_parked_cars_per_bldg.html
@@ -1 +1 @@
-count_parked_cars_per_bldg in sim::sim::scenario - Rust
\ No newline at end of file
+count_parked_cars_per_bldg in sim::sim::scenario - Rust
\ No newline at end of file
diff --git a/rustdoc/sim/sim/scenario/fn.get_vehicles.html b/rustdoc/sim/sim/scenario/fn.get_vehicles.html
index 4f07089fbb..20a9b3bec0 100644
--- a/rustdoc/sim/sim/scenario/fn.get_vehicles.html
+++ b/rustdoc/sim/sim/scenario/fn.get_vehicles.html
@@ -1 +1 @@
-get_vehicles in sim::sim::scenario - Rust fn get_vehicles(
person: &PersonSpec,
rng: &mut XorShiftRng
) -> (Vec<VehicleSpec>, Vec<(usize, BuildingID)>, Vec<Option<usize>>)
\ No newline at end of file
+get_vehicles in sim::sim::scenario - Rust fn get_vehicles(
person: &PersonSpec,
rng: &mut XorShiftRng
) -> (Vec<VehicleSpec>, Vec<(usize, BuildingID)>, Vec<Option<usize>>)
\ No newline at end of file
diff --git a/rustdoc/sim/sim/struct.Sim.html b/rustdoc/sim/sim/struct.Sim.html
index 5aa2aac44e..ab30831211 100644
--- a/rustdoc/sim/sim/struct.Sim.html
+++ b/rustdoc/sim/sim/struct.Sim.html
@@ -23,23 +23,23 @@
sourcepub fn debug_agent_json(&self, id: AgentID) -> String
sourcepub fn debug_intersection_json(&self, id: IntersectionID, map: &Map) -> String
sourcepub fn debug_lane(&self, id: LaneID)
sourcepub fn agent_properties(&self, map: &Map, id: AgentID) -> AgentProperties
Only call for active agents, will panic otherwise
sourcepub fn num_transit_passengers(&self, car: CarID) -> usize
sourcepub fn bus_route_id(&self, maybe_bus: CarID) -> Option<TransitRouteID>
sourcepub fn active_agents(&self) -> Vec<AgentID>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn num_active_agents(&self) -> usize
sourcepub fn agent_to_trip(&self, id: AgentID) -> Option<TripID>
sourcepub fn trip_to_agent(&self, id: TripID) -> TripResult<AgentID>
sourcepub fn trip_info(&self, id: TripID) -> TripInfo
sourcepub fn all_trip_info(&self) -> Vec<(TripID, TripInfo)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn finished_trip_details(
&self,
id: TripID
) -> Option<(Duration, Duration, Distance)>
If trip is finished, returns (total time, total waiting time, total distance)
sourcepub fn trip_blocked_time(&self, id: TripID) -> Duration
sourcepub fn trip_to_person(&self, id: TripID) -> Option<PersonID>
sourcepub fn agent_to_person(&self, id: AgentID) -> Option<PersonID>
sourcepub fn person_to_agent(&self, id: PersonID) -> Option<AgentID>
sourcepub fn get_owner_of_car(&self, id: CarID) -> Option<PersonID>
sourcepub fn lookup_parked_car(&self, id: CarID) -> Option<&ParkedCar>
sourcepub fn all_parked_car_positions(&self, map: &Map) -> Vec<(Position, Position)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
For every parked car, (position of parking spot, position of owner)
-sourcepub fn lookup_person(&self, id: PersonID) -> Option<&Person>
sourcepub fn get_person(&self, id: PersonID) -> &Person
sourcepub fn find_person_by_orig_id(&self, id: OrigPersonID) -> Option<PersonID>
sourcepub fn get_all_people(&self) -> &Vec<Person>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn lookup_car_id(&self, idx: usize) -> Option<CarID>
sourcepub fn get_path(&self, id: AgentID) -> Option<&Path>
sourcepub fn get_all_driving_paths(&self) -> Vec<&Path>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn trace_route(&self, id: AgentID, map: &Map) -> Option<PolyLine>
sourcepub fn get_canonical_pt_per_trip(
&self,
trip: TripID,
map: &Map
) -> TripResult<Pt2D>
sourcepub fn get_canonical_pt_per_person(&self, p: PersonID, map: &Map) -> Option<Pt2D>
sourcepub fn canonical_pt_for_agent(&self, id: AgentID, map: &Map) -> Option<Pt2D>
sourcepub fn get_accepted_agents(&self, id: IntersectionID) -> Vec<(AgentID, TurnID)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn get_waiting_agents(
&self,
id: IntersectionID
) -> Vec<(AgentID, TurnID, Time)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn get_blocked_by_graph(
&self,
map: &Map
) -> BTreeMap<AgentID, (Duration, DelayCause)>
For every agent that’s currently not moving, figure out how long they’ve been waiting and
+
sourcepub fn lookup_person(&self, id: PersonID) -> Option<&Person>
sourcepub fn get_person(&self, id: PersonID) -> &Person
sourcepub fn find_person_by_orig_id(&self, id: OrigPersonID) -> Option<PersonID>
sourcepub fn get_all_people(&self) -> &Vec<Person>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn lookup_car_id(&self, idx: usize) -> Option<CarID>
sourcepub fn get_path(&self, id: AgentID) -> Option<&Path>
sourcepub fn get_all_driving_paths(&self) -> Vec<&Path>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn trace_route(&self, id: AgentID, map: &Map) -> Option<PolyLine>
sourcepub fn get_canonical_pt_per_trip(
&self,
trip: TripID,
map: &Map
) -> TripResult<Pt2D>
sourcepub fn get_canonical_pt_per_person(&self, p: PersonID, map: &Map) -> Option<Pt2D>
sourcepub fn canonical_pt_for_agent(&self, id: AgentID, map: &Map) -> Option<Pt2D>
sourcepub fn get_accepted_agents(&self, id: IntersectionID) -> Vec<(AgentID, TurnID)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn get_waiting_agents(
&self,
id: IntersectionID
) -> Vec<(AgentID, TurnID, Time)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn get_blocked_by_graph(
&self,
map: &Map
) -> BTreeMap<AgentID, (Duration, DelayCause)>
For every agent that’s currently not moving, figure out how long they’ve been waiting and
why they’re blocked.
sourcepub fn status_of_buses(
&self,
route: TransitRouteID,
map: &Map
) -> Vec<(CarID, Option<usize>, f64, Pt2D)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
(bus, stop index it’s coming from, percent to next stop, location)
sourcepub fn get_analytics(&self) -> &Analytics
sourcepub fn delayed_intersections(
&self,
threshold: Duration
) -> Vec<(IntersectionID, Time)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
For intersections with an agent waiting beyond some threshold, return when they started
waiting. Sorted by earliest waiting (likely the root cause of gridlock).
sourcepub fn bldg_to_people(&self, b: BuildingID) -> Vec<PersonID>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn get_pandemic_model(&self) -> Option<&PandemicModel>
sourcepub fn get_end_of_day(&self) -> Time
sourcepub fn current_stage_and_remaining_time(
&self,
i: IntersectionID
) -> (usize, Duration)
sourcepub fn all_arrivals_at_border(
&self,
i: IntersectionID
) -> Vec<(AgentType, Vec<(Time, usize)>)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn target_lane_penalty(&self, lane: &Lane) -> (usize, usize)
(number of vehicles in the lane, penalty if a bike or other slow vehicle is present)
-sourcepub fn get_people_waiting_at_stop(
&self,
at: TransitStopID
) -> &Vec<(PedestrianID, TransitRouteID, Option<TransitStopID>, Time)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn generate_scenario(&self, map: &Map, name: String) -> Scenario
sourcepub fn infinite_parking(&self) -> bool
sourcepub fn all_waiting_people(&self) -> BTreeMap<PersonID, Duration>
sourcepub fn describe_internal_stats(&self) -> Vec<String>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn debug_queue_lengths(&self, l: LaneID) -> Option<(Distance, Distance)>
sourcepub fn get_trip_time_lower_bound(&self, map: &Map, id: TripID) -> Result<Duration>
Returns the best-case time for a trip in a world with no traffic or intersection delays.
+
sourcepub fn get_people_waiting_at_stop(
&self,
at: TransitStopID
) -> &Vec<(PedestrianID, TransitRouteID, Option<TransitStopID>, Time)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn generate_scenario(&self, map: &Map, name: String) -> Scenario
sourcepub fn infinite_parking(&self) -> bool
sourcepub fn all_waiting_people(&self) -> BTreeMap<PersonID, Duration>
sourcepub fn describe_internal_stats(&self) -> Vec<String>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn debug_queue_lengths(&self, l: LaneID) -> Option<(Distance, Distance)>
sourcepub fn get_trip_time_lower_bound(&self, map: &Map, id: TripID) -> Result<Duration>
Returns the best-case time for a trip in a world with no traffic or intersection delays.
Might fail in some cases where the real trip succeeds, but the single-mode path can’t be
found. Assumes the TripID exists.
sourcepub fn get_highlighted_people(&self) -> &Option<BTreeSet<PersonID>>
sourceimpl Sim
sourcepub fn step_count(&self) -> usize
sourcepub fn get_draw_car(&self, id: CarID, map: &Map) -> Option<DrawCarInput>
sourcepub fn get_draw_ped(
&self,
id: PedestrianID,
map: &Map
) -> Option<DrawPedestrianInput>
sourcepub fn get_draw_cars(&self, on: Traversable, map: &Map) -> Vec<DrawCarInput>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn get_draw_peds(
&self,
on: Traversable,
map: &Map
) -> (Vec<DrawPedestrianInput>, Vec<DrawPedCrowdInput>)
sourcepub fn get_all_draw_cars(&self, map: &Map) -> Vec<DrawCarInput>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn get_all_draw_peds(&self, map: &Map) -> Vec<DrawPedestrianInput>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn get_unzoomed_agents(&self, map: &Map) -> Vec<UnzoomedAgent>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
This does not include transit riders. Some callers need those in addition, but the
rendering ones don’t.
-sourcepub fn get_unzoomed_transit_riders(&self, map: &Map) -> Vec<UnzoomedAgent>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourceimpl Sim
sourcepub fn instantiate(
&mut self,
scenario: &Scenario,
map: &Map,
rng: &mut XorShiftRng,
timer: &mut Timer<'_>
)
sourcepub fn instantiate_without_retries(
&mut self,
scenario: &Scenario,
map: &Map,
rng: &mut XorShiftRng,
retry_if_no_room: bool,
timer: &mut Timer<'_>
)
If retry_if_no_room is false, any vehicles that fail to spawn because of something else in
+
sourcepub fn get_unzoomed_transit_riders(&self, map: &Map) -> Vec<UnzoomedAgent>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourceimpl Sim
sourcepub fn instantiate(
&mut self,
scenario: &Scenario,
map: &Map,
rng: &mut XorShiftRng,
timer: &mut Timer<'_>
)
sourcepub fn instantiate_without_retries(
&mut self,
scenario: &Scenario,
map: &Map,
rng: &mut XorShiftRng,
retry_if_no_room: bool,
timer: &mut Timer<'_>
)
If retry_if_no_room is false, any vehicles that fail to spawn because of something else in
the way will just wind up as cancelled trips.
sourceimpl Sim
sourcepub fn new(map: &Map, opts: SimOptions) -> Sim
sourcepub(crate) fn spawn_trips(
&mut self,
input: Vec<(PersonID, TripInfo, StartTripArgs)>,
map: &Map,
timer: &mut Timer<'_>
)
sourcepub fn get_free_onstreet_spots(&self, l: LaneID) -> Vec<ParkingSpot>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn get_free_offstreet_spots(&self, b: BuildingID) -> Vec<ParkingSpot>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn get_free_lot_spots(&self, pl: ParkingLotID) -> Vec<ParkingSpot>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn get_all_parking_spots(&self) -> (Vec<ParkingSpot>, Vec<ParkingSpot>)
(Filled, available)
-sourcepub fn bldg_to_parked_cars(&self, b: BuildingID) -> Vec<CarID>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn walking_path_to_nearest_parking_spot(
&self,
map: &Map,
b: BuildingID
) -> Option<Path>
sourcepub(crate) fn new_person(
&mut self,
orig_id: Option<OrigPersonID>,
ped_speed: Speed,
vehicle_specs: Vec<VehicleSpec>
) -> &Person
sourcepub(crate) fn seed_parked_car(&mut self, vehicle: Vehicle, spot: ParkingSpot)
sourcepub(crate) fn seed_bus_route(&mut self, route: &TransitRoute)
sourcefn start_bus(&mut self, route: &TransitRoute, map: &Map)
sourcepub fn set_run_name(&mut self, name: String)
sourcepub fn get_run_name(&self) -> &String
sourceimpl Sim
sourcefn minimal_step(
&mut self,
map: &Map,
max_dt: Duration,
maybe_cb: &mut Option<Box<dyn SimCallback>>
) -> bool
sourcefn do_step(
&mut self,
map: &Map,
time: Time,
cmd: Command,
maybe_cb: &mut Option<Box<dyn SimCallback>>
) -> bool
sourcefn dispatch_events(&mut self, events: Vec<Event>, map: &Map)
sourcepub fn timed_step(
&mut self,
map: &Map,
dt: Duration,
maybe_cb: &mut Option<Box<dyn SimCallback>>,
timer: &mut Timer<'_>
)
sourcepub fn tiny_step(
&mut self,
map: &Map,
maybe_cb: &mut Option<Box<dyn SimCallback>>
)
sourcepub fn time_limited_step(
&mut self,
map: &Map,
dt: Duration,
real_time_limit: Duration,
maybe_cb: &mut Option<Box<dyn SimCallback>>
)
sourcepub fn dump_before_abort(&self)
sourceimpl Sim
sourcepub fn save_dir(&self) -> String
sourcefn save_path(&self, base_time: Time) -> String
sourcepub fn save(&mut self) -> String
sourcepub fn find_previous_savestate(&self, base_time: Time) -> Option<String>
sourcepub fn find_next_savestate(&self, base_time: Time) -> Option<String>
sourcepub fn load_savestate(path: String, timer: &mut Timer<'_>) -> Result<Sim>
sourceimpl Sim
sourcepub fn handle_live_edited_traffic_signals(&mut self, map: &Map)
sourcepub fn handle_live_edits(
&mut self,
map: &Map,
timer: &mut Timer<'_>
) -> (usize, usize)
Respond to arbitrary map edits without resetting the simulation. Returns the number of
+
sourcepub fn bldg_to_parked_cars(&self, b: BuildingID) -> Vec<CarID>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourcepub fn walking_path_to_nearest_parking_spot(
&self,
map: &Map,
b: BuildingID
) -> Option<Path>
sourcepub(crate) fn new_person(
&mut self,
orig_id: Option<OrigPersonID>,
ped_speed: Speed,
vehicle_specs: Vec<VehicleSpec>
) -> &Person
sourcepub(crate) fn seed_parked_car(&mut self, vehicle: Vehicle, spot: ParkingSpot)
sourcepub(crate) fn seed_bus_route(&mut self, route: &TransitRoute)
sourcefn start_bus(&mut self, route: &TransitRoute, map: &Map)
sourcepub fn set_run_name(&mut self, name: String)
sourcepub fn get_run_name(&self) -> &String
sourceimpl Sim
sourcefn minimal_step(
&mut self,
map: &Map,
max_dt: Duration,
maybe_cb: &mut Option<Box<dyn SimCallback>>
) -> bool
sourcefn do_step(
&mut self,
map: &Map,
time: Time,
cmd: Command,
maybe_cb: &mut Option<Box<dyn SimCallback>>
) -> bool
sourcefn dispatch_events(&mut self, events: Vec<Event>, map: &Map)
sourcepub fn timed_step(
&mut self,
map: &Map,
dt: Duration,
maybe_cb: &mut Option<Box<dyn SimCallback>>,
timer: &mut Timer<'_>
)
sourcepub fn tiny_step(
&mut self,
map: &Map,
maybe_cb: &mut Option<Box<dyn SimCallback>>
)
sourcepub fn time_limited_step(
&mut self,
map: &Map,
dt: Duration,
real_time_limit: Duration,
maybe_cb: &mut Option<Box<dyn SimCallback>>
)
sourcepub fn dump_before_abort(&self)
sourceimpl Sim
sourcepub fn save_dir(&self) -> String
sourcefn save_path(&self, base_time: Time) -> String
sourcepub fn save(&mut self) -> String
sourcepub fn find_previous_savestate(&self, base_time: Time) -> Option<String>
sourcepub fn find_next_savestate(&self, base_time: Time) -> Option<String>
sourcepub fn load_savestate(path: String, timer: &mut Timer<'_>) -> Result<Sim>
sourceimpl Sim
sourcepub fn handle_live_edited_traffic_signals(&mut self, map: &Map)
sourcepub fn handle_live_edits(
&mut self,
map: &Map,
timer: &mut Timer<'_>
) -> (usize, usize)
Respond to arbitrary map edits without resetting the simulation. Returns the number of
(trips cancelled, parked cars displaced).
sourceimpl Sim
sourcepub fn delete_car(&mut self, id: CarID, map: &Map)
sourcepub fn clear_alerts(&mut self) -> Vec<(Time, AlertLocation, String)>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
sourceimpl Sim
sourcepub fn set_periodic_callback(&mut self, frequency: Duration)
Only one at a time supported.
diff --git a/rustdoc/sim/struct.Analytics.html b/rustdoc/sim/struct.Analytics.html
index 10d62b6911..567ef4ce8b 100644
--- a/rustdoc/sim/struct.Analytics.html
+++ b/rustdoc/sim/struct.Analytics.html
@@ -7,7 +7,7 @@
pub passengers_boarding: BTreeMap<TransitStopID, Vec<(Time, TransitRouteID, Duration)>>,
pub passengers_alighting: BTreeMap<TransitStopID, Vec<(Time, TransitRouteID)>>,
pub started_trips: BTreeMap<TripID, Time>,
- pub finished_trips: Vec<(Time, TripID, TripMode, Option<Duration>)>,
+ pub finished_trips: Vec<(Time, TripID, TripMode, Option<Duration>)>,
pub problems_per_trip: BTreeMap<TripID, Vec<(Time, Problem)>>,
pub trip_log: Vec<(Time, TripID, Option<PathRequest>, TripPhaseType)>,
pub intersection_delays: BTreeMap<IntersectionID, Vec<(u8, Time, Duration, AgentType)>>,
@@ -25,13 +25,13 @@ running the simulation, and compare the live Analytics to the prebaked baseline
Fields
road_thruput: TimeSeriesCount<RoadID>
intersection_thruput: TimeSeriesCount<IntersectionID>
traffic_signal_thruput: TimeSeriesCount<CompressedMovementID>
demand: BTreeMap<MovementID, usize>
Most fields in Analytics are cumulative over time, but this is just for the current moment
in time.
bus_arrivals: Vec<(Time, CarID, TransitRouteID, TransitStopID)>
passengers_boarding: BTreeMap<TransitStopID, Vec<(Time, TransitRouteID, Duration)>>
For each passenger boarding, how long did they wait at the stop?
-passengers_alighting: BTreeMap<TransitStopID, Vec<(Time, TransitRouteID)>>
started_trips: BTreeMap<TripID, Time>
finished_trips: Vec<(Time, TripID, TripMode, Option<Duration>)>
Finish time, ID, mode, trip duration if successful (or None if cancelled)
+passengers_alighting: BTreeMap<TransitStopID, Vec<(Time, TransitRouteID)>>
started_trips: BTreeMap<TripID, Time>
finished_trips: Vec<(Time, TripID, TripMode, Option<Duration>)>
Finish time, ID, mode, trip duration if successful (or None if cancelled)
problems_per_trip: BTreeMap<TripID, Vec<(Time, Problem)>>
Record different problems that each trip encounters.
trip_log: Vec<(Time, TripID, Option<PathRequest>, TripPhaseType)>
intersection_delays: BTreeMap<IntersectionID, Vec<(u8, Time, Duration, AgentType)>>
Only for traffic signals. The u8 is the movement index from a CompressedMovementID.
parking_lane_changes: BTreeMap<LaneID, Vec<(Time, bool)>>
Per parking lane or lot, when does a spot become filled (true) or free (false)
parking_lot_changes: BTreeMap<ParkingLotID, Vec<(Time, bool)>>
alerts: Vec<(Time, AlertLocation, String)>
record_anything: bool
For benchmarking, we may want to disable collecting data.
Implementations
sourceimpl Analytics
sourcepub fn new(record_anything: bool) -> Analytics
sourcepub fn event(&mut self, ev: Event, time: Time, map: &Map)
sourcepub fn record_demand(&mut self, path: &Path, map: &Map)
sourcepub fn finished_trip_time(&self, trip: TripID) -> Option<Duration>
Ignores the current time. Returns None for cancelled trips.
-