Skip to main content

ExecuteData

Struct ExecuteData 

Source
pub struct ExecuteData { /* private fields */ }
Expand description

Wrapper of zend_execute_data.

Implementations§

Source§

impl ExecuteData

Source

pub unsafe fn from_ptr<'a>(ptr: *const zend_execute_data) -> &'a Self

Wraps a raw pointer.

§Safety

Create from raw pointer.

§Panics

Panics if pointer is null.

Source

pub unsafe fn try_from_ptr<'a>( ptr: *const zend_execute_data, ) -> Option<&'a Self>

Wraps a raw pointer, return None if pointer is null.

§Safety

Create from raw pointer.

Source

pub unsafe fn from_mut_ptr<'a>(ptr: *mut zend_execute_data) -> &'a mut Self

Wraps a raw pointer.

§Safety

Create from raw pointer.

§Panics

Panics if pointer is null.

Source

pub unsafe fn try_from_mut_ptr<'a>( ptr: *mut zend_execute_data, ) -> Option<&'a mut Self>

Wraps a raw pointer, return None if pointer is null.

§Safety

Create from raw pointer.

Source

pub const fn as_ptr(&self) -> *const zend_execute_data

Returns a raw pointer wrapped.

Source

pub fn as_mut_ptr(&mut self) -> *mut zend_execute_data

Returns a raw pointer wrapped.

Source

pub fn common_num_args(&self) -> u32

Gets common arguments count.

Source

pub fn common_required_num_args(&self) -> usize

Gets common required arguments count.

Source

pub fn common_arg_info(&self) -> *mut zend_arg_info

Gets first common argument info.

Source

pub fn num_args(&self) -> usize

Gets arguments count.

Source

pub fn func(&self) -> &ZFunc

Gets associated function.

Source

pub fn get_opline_lineno(&self) -> Option<u32>

Gets the current opline line number if available. This represents the line number in the source code where the current operation is being executed.

Source

pub fn get_return_value(&self) -> Option<&ZVal>

Gets associated return value.

Source

pub fn get_return_value_mut(&mut self) -> Option<&mut ZVal>

Gets mutable reference to associated return value.

Source

pub fn get_return_value_mut_ptr(&mut self) -> *mut ZVal

Gets associated return value pointer.

Source

pub fn get_return_value_ptr(&self) -> *const ZVal

Gets immutable pointer to associated return value.

Source

pub fn get_this(&mut self) -> Option<&ZObj>

Gets associated $this object if exists.

Source

pub fn get_this_mut(&mut self) -> Option<&mut ZObj>

Gets associated mutable $this object if exists.

Source

pub fn get_called_scope(&mut self) -> Option<&ClassEntry>

Gets associated called scope if it exists

Source

pub fn get_parameter(&self, index: usize) -> &ZVal

Gets parameter by index.

Source

pub fn get_mut_parameter(&mut self, index: usize) -> &mut ZVal

Gets mutable parameter by index.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.