pub struct UeSet<T: ContainerElement> { /* private fields */ }Expand description
A view into a UE TSet<T> property on a UObject.
Implementations§
Source§impl<T: ContainerElement> UeSet<T>
impl<T: ContainerElement> UeSet<T>
pub fn new(owner: UObjectHandle, prop: FPropertyHandle) -> Self
Sourcepub fn len(&self) -> UikaResult<usize>
pub fn len(&self) -> UikaResult<usize>
Returns the number of elements in the set.
pub fn is_empty(&self) -> UikaResult<bool>
Sourcepub fn contains(&self, val: &T) -> UikaResult<bool>
pub fn contains(&self, val: &T) -> UikaResult<bool>
Check if the set contains an element.
Sourcepub fn add(&self, val: &T) -> UikaResult<()>
pub fn add(&self, val: &T) -> UikaResult<()>
Add an element to the set.
Sourcepub fn remove(&self, val: &T) -> UikaResult<()>
pub fn remove(&self, val: &T) -> UikaResult<()>
Remove an element from the set.
Sourcepub fn clear(&self) -> UikaResult<()>
pub fn clear(&self) -> UikaResult<()>
Remove all elements from the set.
Sourcepub fn get_element(&self, logical_index: usize) -> UikaResult<T>
pub fn get_element(&self, logical_index: usize) -> UikaResult<T>
Get the element at logical index (for iteration).
Source§impl<T: ContainerElement> UeSet<T>
impl<T: ContainerElement> UeSet<T>
Sourcepub fn bulk_iter(&self) -> UikaResult<BulkSetIter<T>>
pub fn bulk_iter(&self) -> UikaResult<BulkSetIter<T>>
Bulk-fetch all elements as a lazy iterator (single FFI call).
Source§impl<T: ContainerElement + Hash + Eq> UeSet<T>
impl<T: ContainerElement + Hash + Eq> UeSet<T>
Sourcepub fn to_hash_set(&self) -> UikaResult<HashSet<T>>
pub fn to_hash_set(&self) -> UikaResult<HashSet<T>>
Bulk-copy all elements to a HashSet in a single FFI call.
Trait Implementations§
Source§impl<'a, T: ContainerElement> IntoIterator for &'a UeSet<T>
impl<'a, T: ContainerElement> IntoIterator for &'a UeSet<T>
impl<T: Copy + ContainerElement> Copy for UeSet<T>
Auto Trait Implementations§
impl<T> Freeze for UeSet<T>
impl<T> RefUnwindSafe for UeSet<T>where
T: RefUnwindSafe,
impl<T> Send for UeSet<T>where
T: Send,
impl<T> Sync for UeSet<T>where
T: Sync,
impl<T> Unpin for UeSet<T>where
T: Unpin,
impl<T> UnsafeUnpin for UeSet<T>
impl<T> UnwindSafe for UeSet<T>where
T: UnwindSafe,
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