#[repr(C)]
pub struct _sapi_globals_struct {
Show 17 fields pub server_context: *mut c_void, pub request_info: sapi_request_info, pub sapi_headers: sapi_headers_struct, pub read_post_bytes: i64, pub post_read: c_uchar, pub headers_sent: c_uchar, pub global_stat: zend_stat_t, pub default_mimetype: *mut c_char, pub default_charset: *mut c_char, pub rfc1867_uploaded_files: *mut HashTable, pub post_max_size: zend_long, pub options: c_int, pub sapi_started: bool, pub global_request_time: f64, pub known_post_content_types: HashTable, pub callback_func: zval, pub fci_cache: zend_fcall_info_cache,
}

Fields§

§server_context: *mut c_void§request_info: sapi_request_info§sapi_headers: sapi_headers_struct§read_post_bytes: i64§post_read: c_uchar§headers_sent: c_uchar§global_stat: zend_stat_t§default_mimetype: *mut c_char§default_charset: *mut c_char§rfc1867_uploaded_files: *mut HashTable§post_max_size: zend_long§options: c_int§sapi_started: bool§global_request_time: f64§known_post_content_types: HashTable§callback_func: zval§fci_cache: zend_fcall_info_cache

Implementations§

source§

impl _sapi_globals_struct

source

pub fn get() -> GlobalReadGuard<Self>

Returns a reference to the PHP process globals.

The process globals are guarded by a RwLock. There can be multiple immutable references at one time but only ever one mutable reference. Attempting to retrieve the globals while already holding the global guard will lead to a deadlock. Dropping the globals guard will release the lock.

source

pub fn get_mut() -> GlobalWriteGuard<Self>

Returns a mutable reference to the PHP executor globals.

The executor globals are guarded by a RwLock. There can be multiple immutable references at one time but only ever one mutable reference. Attempting to retrieve the globals while already holding the global guard will lead to a deadlock. Dropping the globals guard will release the lock.

source

pub fn request_info(&self) -> &sapi_request_info

source

pub fn sapi_headers(&self) -> &sapi_headers_struct

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>,

§

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>,

§

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.