pub struct Map {
pub settings: MapSettings,
/* private fields */
}Expand description
Struct that contains coordinates to help calculate nearest point in space
Fields§
§settings: MapSettingsImplementations§
Source§impl Map
impl Map
pub fn new() -> Self
pub fn add_hashmap_points(&mut self, hash_map: HashMap<usize, MapPoint>)
pub fn set_pos_from_nodeid(&mut self, node_id: usize)
pub fn set_pos(&mut self, position: [f32; 2])
pub fn get_pos(self) -> [f32; 2]
pub fn add_labels(&mut self, labels: Vec<MapLabel>)
pub fn add_lines(&mut self, lines: HashMap<String, MapLine>)
pub fn set_zoom(&mut self, value: f32)
pub fn get_zoom(&mut self) -> f32
pub fn notify(&mut self, id_node: usize, time: Instant) -> Result<bool, Error>
pub fn set_context_manager(&mut self, manager: Rc<dyn ContextMenuManager>)
pub fn set_node_template(&mut self, template: Rc<dyn NodeTemplate>)
pub fn update_marker(&mut self, id: usize, node_id: usize)
pub fn allocate_at_least(&mut self, width: Option<f32>, height: Option<f32>)
pub fn allocate_at_most(&mut self, width: Option<f32>, height: Option<f32>)
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Map
impl !Send for Map
impl !Sync for Map
impl !UnwindSafe for Map
impl Freeze for Map
impl Unpin for Map
impl UnsafeUnpin for Map
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
Converts
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>
Converts
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 more