Enum bevy_asset::io::AssetSourceEvent
source · pub enum AssetSourceEvent {
AddedAsset(PathBuf),
ModifiedAsset(PathBuf),
RemovedAsset(PathBuf),
RenamedAsset {
old: PathBuf,
new: PathBuf,
},
AddedMeta(PathBuf),
ModifiedMeta(PathBuf),
RemovedMeta(PathBuf),
RenamedMeta {
old: PathBuf,
new: PathBuf,
},
AddedFolder(PathBuf),
RemovedFolder(PathBuf),
RenamedFolder {
old: PathBuf,
new: PathBuf,
},
RemovedUnknown {
path: PathBuf,
is_meta: bool,
},
}
Expand description
An “asset source change event” that occurs whenever asset (or asset metadata) is created/added/removed
Variants§
AddedAsset(PathBuf)
An asset at this path was added.
ModifiedAsset(PathBuf)
An asset at this path was modified.
RemovedAsset(PathBuf)
An asset at this path was removed.
RenamedAsset
An asset at this path was renamed.
AddedMeta(PathBuf)
Asset metadata at this path was added.
ModifiedMeta(PathBuf)
Asset metadata at this path was modified.
RemovedMeta(PathBuf)
Asset metadata at this path was removed.
RenamedMeta
Asset metadata at this path was renamed.
AddedFolder(PathBuf)
A folder at the given path was added.
RemovedFolder(PathBuf)
A folder at the given path was removed.
RenamedFolder
A folder at the given path was renamed.
RemovedUnknown
Fields
Something of unknown type was removed. It is the job of the event handler to determine the type. This exists because notify-rs produces “untyped” rename events without destination paths for unwatched folders, so we can’t determine the type of the rename.
Trait Implementations§
source§impl Clone for AssetSourceEvent
impl Clone for AssetSourceEvent
source§fn clone(&self) -> AssetSourceEvent
fn clone(&self) -> AssetSourceEvent
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for AssetSourceEvent
impl Debug for AssetSourceEvent
source§impl PartialEq for AssetSourceEvent
impl PartialEq for AssetSourceEvent
source§fn eq(&self, other: &AssetSourceEvent) -> bool
fn eq(&self, other: &AssetSourceEvent) -> bool
self
and other
values to be equal, and is used
by ==
.impl Eq for AssetSourceEvent
impl StructuralEq for AssetSourceEvent
impl StructuralPartialEq for AssetSourceEvent
Auto Trait Implementations§
impl RefUnwindSafe for AssetSourceEvent
impl Send for AssetSourceEvent
impl Sync for AssetSourceEvent
impl Unpin for AssetSourceEvent
impl UnwindSafe for AssetSourceEvent
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> 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> DowncastSync for T
impl<T> DowncastSync for T
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.