Struct libil2cpp::Il2CppArray
source · [−]#[repr(transparent)]pub struct Il2CppArray<T: Type>(_, _);
Expand description
An il2cpp array
Implementations
sourceimpl<T: Type> Il2CppArray<T>
impl<T: Type> Il2CppArray<T>
sourcepub fn new<'a, I>(items: I) -> &'a mut Self where
I: IntoIterator<Item = T::Held<'a>>,
I::IntoIter: ExactSizeIterator<Item = T::Held<'a>>,
pub fn new<'a, I>(items: I) -> &'a mut Self where
I: IntoIterator<Item = T::Held<'a>>,
I::IntoIter: ExactSizeIterator<Item = T::Held<'a>>,
Creates an array from an iterator
sourcepub fn as_mut_slice(&mut self) -> &mut [T::Held<'_>]
pub fn as_mut_slice(&mut self) -> &mut [T::Held<'_>]
Mutable slice of values in the array
Methods from Deref<Target = Il2CppObject>
sourcepub fn class(&self) -> &'static Il2CppClass
pub fn class(&self) -> &'static Il2CppClass
Il2CppClass
of the object
sourcepub fn invoke<A, R, const N: usize>(
&mut self,
name: &str,
args: A
) -> Result<R, &mut Il2CppException> where
A: Arguments<N>,
R: Returned,
pub fn invoke<A, R, const N: usize>(
&mut self,
name: &str,
args: A
) -> Result<R, &mut Il2CppException> where
A: Arguments<N>,
R: Returned,
Invokes the method with the given name on self
using the given
arguments, with type checking
Panics
This method will panic if a matching method can’t be found.
sourcepub fn invoke_void<A, const N: usize>(
&mut self,
name: &str,
args: A
) -> Result<(), &mut Il2CppException> where
A: Arguments<N>,
pub fn invoke_void<A, const N: usize>(
&mut self,
name: &str,
args: A
) -> Result<(), &mut Il2CppException> where
A: Arguments<N>,
Invokes the void
method with the given name on self
using the
given arguments, with type checking
Panics
This method will panic if a matching method can’t be found.
Trait Implementations
sourceimpl<T: Type> Deref for Il2CppArray<T>
impl<T: Type> Deref for Il2CppArray<T>
type Target = Il2CppObject
type Target = Il2CppObject
The resulting type after dereferencing.
sourceimpl<T: Type> DerefMut for Il2CppArray<T>
impl<T: Type> DerefMut for Il2CppArray<T>
sourceimpl<'de, T: Type> Deserialize<'de> for &'de mut Il2CppArray<T> where
T::Held<'de>: Deserialize<'de>,
impl<'de, T: Type> Deserialize<'de> for &'de mut Il2CppArray<T> where
T::Held<'de>: Deserialize<'de>,
sourcefn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl<T: Type> Type for Il2CppArray<T>
impl<T: Type> Type for Il2CppArray<T>
type Held<'a> = Option<&'a mut Il2CppArray<T>>
type Held<'a> = Option<&'a mut Il2CppArray<T>>
Type of the values held in variables of the type
type HeldRaw = *mut Il2CppArray<T>
type HeldRaw = *mut Il2CppArray<T>
Non-generic version of [Held
].
sourceconst CLASS_NAME: &'static str = "Array"
const CLASS_NAME: &'static str = "Array"
Name of the class the type represents
sourcefn class() -> &'static Il2CppClass
fn class() -> &'static Il2CppClass
Il2CppClass
of the type
sourcefn matches_reference_argument(ty: &Il2CppType) -> bool
fn matches_reference_argument(ty: &Il2CppType) -> bool
Whether a reference to the type can be used as an argument of the given
Il2CppType
Read more
sourcefn matches_value_argument(_: &Il2CppType) -> bool
fn matches_value_argument(_: &Il2CppType) -> bool
Whether a value of the type can be used as an argument of the given
Il2CppType
Read more
sourcefn matches_reference_parameter(ty: &Il2CppType) -> bool
fn matches_reference_parameter(ty: &Il2CppType) -> bool
Whether a reference to the type can be used as a parameter of the given
Il2CppType
Read more
sourcefn matches_value_parameter(_: &Il2CppType) -> bool
fn matches_value_parameter(_: &Il2CppType) -> bool
Whether a value of the type can be used as a parameter of the given
Il2CppType
Read more
sourcefn matches_this_argument(method: &MethodInfo) -> bool
fn matches_this_argument(method: &MethodInfo) -> bool
Whether the type can be used as a this
argument for the given
MethodInfo
Read more
sourcefn matches_this_parameter(method: &MethodInfo) -> bool
fn matches_this_parameter(method: &MethodInfo) -> bool
Whether the type can be used as a this
parameter for the given
MethodInfo
Read more
sourcefn matches_returned(ty: &Il2CppType) -> bool
fn matches_returned(ty: &Il2CppType) -> bool
Whether the type can be used as the value of the given Il2CppType
returned from a C# method Read more
sourcefn matches_return(ty: &Il2CppType) -> bool
fn matches_return(ty: &Il2CppType) -> bool
Whether the type can be used as the return value of the given
Il2CppType
for a C# method Read more
sourceimpl<T: Type> WrapRaw for Il2CppArray<T>
impl<T: Type> WrapRaw for Il2CppArray<T>
type Raw = Il2CppArray
type Raw = Il2CppArray
Raw il2cpp type
sourceunsafe fn raw_mut(&mut self) -> &mut Self::Raw
unsafe fn raw_mut(&mut self) -> &mut Self::Raw
Returns a mutable reference to the underlying raw il2cpp type Read more
sourceunsafe fn wrap_mut(raw: &mut Self::Raw) -> &mut Self
unsafe fn wrap_mut(raw: &mut Self::Raw) -> &mut Self
Wraps a mutable reference to the raw il2cpp type Read more
Auto Trait Implementations
impl<T> RefUnwindSafe for Il2CppArray<T> where
T: RefUnwindSafe,
impl<T> !Send for Il2CppArray<T>
impl<T> !Sync for Il2CppArray<T>
impl<T> Unpin for Il2CppArray<T> where
T: Unpin,
impl<T> UnwindSafe for Il2CppArray<T> where
T: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more