pub struct ContainerOpenRequestEvent {
pub inventory_type: InventoryType,
pub backing: ContainerBacking,
pub title: String,
pub cancelled: bool,
}Expand description
Fires BEFORE a container window opens.
Cancellable – plugins can deny the open (e.g., permission checks). Fires during the Validate stage of the game bus.
Fields§
§inventory_type: InventoryTypeThe inventory type being requested.
backing: ContainerBackingHow the container is backed (block or virtual).
title: StringTitle that will be shown to the player.
cancelled: boolWhether the event has been cancelled.
Trait Implementations§
Source§impl Clone for ContainerOpenRequestEvent
impl Clone for ContainerOpenRequestEvent
Source§fn clone(&self) -> ContainerOpenRequestEvent
fn clone(&self) -> ContainerOpenRequestEvent
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ContainerOpenRequestEvent
impl Debug for ContainerOpenRequestEvent
Source§impl Event for ContainerOpenRequestEvent
impl Event for ContainerOpenRequestEvent
Source§fn is_cancelled(&self) -> bool
fn is_cancelled(&self) -> bool
Whether this event has been cancelled by a Validate handler.
Source§fn as_any_mut(&mut self) -> &mut dyn Any
fn as_any_mut(&mut self) -> &mut dyn Any
Upcasts to
&mut dyn Any for mutable type-erased dispatch.Auto Trait Implementations§
impl Freeze for ContainerOpenRequestEvent
impl RefUnwindSafe for ContainerOpenRequestEvent
impl Send for ContainerOpenRequestEvent
impl Sync for ContainerOpenRequestEvent
impl Unpin for ContainerOpenRequestEvent
impl UnsafeUnpin for ContainerOpenRequestEvent
impl UnwindSafe for ContainerOpenRequestEvent
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