pub struct PHPFunction {
pub name: String,
pub params: Vec<PHPParam>,
pub return_type: Option<PHPType>,
pub body: Vec<String>,
pub is_static: bool,
pub is_abstract: bool,
pub visibility: Option<PHPVisibility>,
pub doc_comment: Option<String>,
}Expand description
A PHP top-level function or method.
Fields§
§name: StringFunction name
params: Vec<PHPParam>Parameters
return_type: Option<PHPType>Optional return type
body: Vec<String>Body lines (raw PHP code)
is_static: boolWhether this is a static method
is_abstract: boolWhether this is abstract
visibility: Option<PHPVisibility>Visibility (for methods)
doc_comment: Option<String>Docblock comment
Implementations§
Trait Implementations§
Source§impl Clone for PHPFunction
impl Clone for PHPFunction
Source§fn clone(&self) -> PHPFunction
fn clone(&self) -> PHPFunction
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 PHPFunction
impl Debug for PHPFunction
Source§impl PartialEq for PHPFunction
impl PartialEq for PHPFunction
impl StructuralPartialEq for PHPFunction
Auto Trait Implementations§
impl Freeze for PHPFunction
impl RefUnwindSafe for PHPFunction
impl Send for PHPFunction
impl Sync for PHPFunction
impl Unpin for PHPFunction
impl UnsafeUnpin for PHPFunction
impl UnwindSafe for PHPFunction
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