pub struct Module { /* private fields */ }
Expand description
主模块,用于统筹资源
Implementations§
Source§impl Module
impl Module
Sourcepub fn add_way(
&mut self,
id: i32,
way_type: Type,
cost_time: i32,
start_time: i32,
start_city_index: usize,
end_city_index: usize,
) -> Result<(), ModuleErr>
pub fn add_way( &mut self, id: i32, way_type: Type, cost_time: i32, start_time: i32, start_city_index: usize, end_city_index: usize, ) -> Result<(), ModuleErr>
添加一个交通方式
Trait Implementations§
Source§impl FromWasmAbi for Module
impl FromWasmAbi for Module
Source§impl IntoWasmAbi for Module
impl IntoWasmAbi for Module
Source§impl LongRefFromWasmAbi for Module
impl LongRefFromWasmAbi for Module
Source§impl OptionFromWasmAbi for Module
impl OptionFromWasmAbi for Module
Source§impl OptionIntoWasmAbi for Module
impl OptionIntoWasmAbi for Module
Source§impl RefFromWasmAbi for Module
impl RefFromWasmAbi for Module
Source§impl RefMutFromWasmAbi for Module
impl RefMutFromWasmAbi for Module
Source§impl TryFromJsValue for Module
impl TryFromJsValue for Module
Source§impl VectorFromWasmAbi for Module
impl VectorFromWasmAbi for Module
Source§impl VectorIntoWasmAbi for Module
impl VectorIntoWasmAbi for Module
impl SupportsConstructor for Module
impl SupportsInstanceProperty for Module
impl SupportsStaticProperty for Module
Auto Trait Implementations§
impl Freeze for Module
impl RefUnwindSafe for Module
impl !Send for Module
impl !Sync for Module
impl Unpin for Module
impl UnwindSafe for Module
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
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 moreSource§impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
Source§type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
Same as
IntoWasmAbi::Abi
Source§fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
Same as
IntoWasmAbi::into_abi
, except that it may throw and never
return in the case of Err
.