CodeGenerator/Php/Class.php

Show: PublicProtectedPrivateinherited
Table of Contents
Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Category
Zend  
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
Zend_CodeGenerator  
Subpackage
PHP  
Version
$Id: Class.php 24593 2012-01-05 20:35:02Z matthew $  

\Zend_CodeGenerator_Php_Class

Package: Zend\CodeGenerator
Parent(s)
\Zend_CodeGenerator_Php_Abstract < \Zend_CodeGenerator_Abstract
Category
Zend  
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  

Constants

>VConstant  LINE_FEED = "\n"
inherited
Line feed to use in place of EOL
Inherited from: \Zend_CodeGenerator_Php_Abstract::LINE_FEED

Properties

>VPropertyprotectedarray $_constants = null

Array of constants

Default valuenullDetails
Type
array
>VPropertyprotected\Zend_CodeGenerator_Php_Docblock $_docblock = null
Default valuenullDetails
Type
\Zend_CodeGenerator_Php_Docblock
>VPropertyprotectedstring $_extendedClass = null
Default valuenullDetails
Type
string
>VPropertyprotectedarray $_implementedInterfaces = array()

Array of string names

Default valuearray()Details
Type
array
>VPropertyprotectedint|string $_indentation = ' '
Default value' 'Details
Type
int | string
Inherited_from
\Zend_CodeGenerator_Php_Abstract::$$_indentation  
>VPropertyprotectedbool $_isAbstract = false
Default valuefalseDetails
Type
bool
>VPropertyprotectedbool $_isSourceDirty = true
Default valuetrueDetails
Type
bool
Inherited_from
\Zend_CodeGenerator_Php_Abstract::$$_isSourceDirty  
>VPropertyprotectedarray $_methods = null

Array of methods

Default valuenullDetails
Type
array
>VPropertyprotectedstring $_name = null
Default valuenullDetails
Type
string
>VPropertyprotectedarray $_properties = null

Array of properties

Default valuenullDetails
Type
array

Methods

methodpublic__construct(array $options = array()) : void
Parameters
NameTypeDescription
$optionsarray
methodpublic__toString() : string
finalinherited

__toString() - casting to a string will in turn call generate()

Inherited from: \Zend_CodeGenerator_Abstract::__toString()\Zend_CodeGenerator_Php_Abstract::__toString()
Returns
TypeDescription
string
methodprotected_init() : void

_init() - is called at construction time

methodprotected_prepare() : void
inherited

_prepare() - this is called at construction completion

Inherited from: \Zend_CodeGenerator_Abstract::_prepare()\Zend_CodeGenerator_Php_Abstract::_prepare()
methodpublicfromReflection(\Zend_Reflection_Class $reflectionClass) : \Zend_CodeGenerator_Php_Class
static

fromReflection() - build a Code Generation PHP Object from a Class Reflection

Parameters
NameTypeDescription
$reflectionClass\Zend_Reflection_Class
Returns
TypeDescription
\Zend_CodeGenerator_Php_Class
methodpublicgenerate() : string

generate()

Returns
TypeDescription
string
methodpublicgetConstant(string $constName) : \Zend_CodeGenerator_Php_Property

getConstant()

Parameters
NameTypeDescription
$constNamestring
Returns
TypeDescription
\Zend_CodeGenerator_Php_Property
methodpublicgetConstants() : array

getConstants()

Returns
TypeDescription
array
methodpublicgetDocblock() : \Zend_CodeGenerator_Php_Docblock

getDocblock()

Returns
TypeDescription
\Zend_CodeGenerator_Php_Docblock
methodpublicgetExtendedClass() : string

getExtendedClass()

Returns
TypeDescription
string
methodpublicgetImplementedInterfaces() : array

getImplementedInterfaces

Returns
TypeDescription
array
methodpublicgetIndentation() : string | int
inherited

getIndentation()

Inherited from: \Zend_CodeGenerator_Php_Abstract::getIndentation()
Returns
TypeDescription
string | int
methodpublicgetMethod(string $methodName) : \Zend_CodeGenerator_Php_Method

getMethod()

Parameters
NameTypeDescription
$methodNamestring
Returns
TypeDescription
\Zend_CodeGenerator_Php_Method
methodpublicgetMethods() : array

getMethods()

Returns
TypeDescription
array
methodpublicgetName() : string

getName()

Returns
TypeDescription
string
methodpublicgetProperties() : array

getProperties()

Returns
TypeDescription
array
methodpublicgetProperty(string $propertyName) : \Zend_CodeGenerator_Php_Property

getProperty()

Parameters
NameTypeDescription
$propertyNamestring
Returns
TypeDescription
\Zend_CodeGenerator_Php_Property
methodpublicgetSourceContent() : string
Returns
TypeDescription
string
methodpublichasConstant(string $constName) : bool

hasConstant()

Parameters
NameTypeDescription
$constNamestring
Returns
TypeDescription
bool
methodpublichasMethod(string $methodName) : bool

hasMethod()

Parameters
NameTypeDescription
$methodNamestring
Returns
TypeDescription
bool
methodpublichasProperty(string $propertyName) : bool

hasProperty()

Parameters
NameTypeDescription
$propertyNamestring
Returns
TypeDescription
bool
methodpublicisAbstract() : bool

isAbstract()

Returns
TypeDescription
bool
methodpublicisSourceDirty() : bool

isSourceDirty()

Returns
TypeDescription
bool
methodpublicsetAbstract(bool $isAbstract) : \Zend_CodeGenerator_Php_Class

setAbstract()

Parameters
NameTypeDescription
$isAbstractbool
Returns
TypeDescription
\Zend_CodeGenerator_Php_Class
methodpublicsetConfig(\Zend_Config $config) : \Zend_CodeGenerator_Abstract
Parameters
NameTypeDescription
$config\Zend_Config
Returns
TypeDescription
\Zend_CodeGenerator_Abstract
methodpublicsetConstant(array | \Zend_CodeGenerator_Php_Property $const) : \Zend_CodeGenerator_Php_Class

setConstant()

Parameters
NameTypeDescription
$constarray | \Zend_CodeGenerator_Php_Property
Returns
TypeDescription
\Zend_CodeGenerator_Php_Class
methodpublicsetConstants(array $constants) : \Zend_CodeGenerator_Php_Class

setConstants()

Parameters
NameTypeDescription
$constantsarray
Returns
TypeDescription
\Zend_CodeGenerator_Php_Class
methodpublicsetDocblock(\Zend_CodeGenerator_Php_Docblock | array | string $docblock) : \Zend_CodeGenerator_Php_File

setDocblock() Set the docblock

Parameters
NameTypeDescription
$docblock\Zend_CodeGenerator_Php_Docblock | array | string
Returns
TypeDescription
\Zend_CodeGenerator_Php_File
methodpublicsetExtendedClass(string $extendedClass) : \Zend_CodeGenerator_Php_Class

setExtendedClass()

Parameters
NameTypeDescription
$extendedClassstring
Returns
TypeDescription
\Zend_CodeGenerator_Php_Class
methodpublicsetImplementedInterfaces(array $implementedInterfaces) : \Zend_CodeGenerator_Php_Class

setImplementedInterfaces()

Parameters
NameTypeDescription
$implementedInterfacesarray
Returns
TypeDescription
\Zend_CodeGenerator_Php_Class
methodpublicsetIndentation(string | int $indentation) : \Zend_CodeGenerator_Php_Abstract
inherited

setIndentation()

Inherited from: \Zend_CodeGenerator_Php_Abstract::setIndentation()
Parameters
NameTypeDescription
$indentationstring | int
Returns
TypeDescription
\Zend_CodeGenerator_Php_Abstract
methodpublicsetMethod(array | \Zend_CodeGenerator_Php_Method $method) : \Zend_CodeGenerator_Php_Class

setMethod()

Parameters
NameTypeDescription
$methodarray | \Zend_CodeGenerator_Php_Method
Returns
TypeDescription
\Zend_CodeGenerator_Php_Class
methodpublicsetMethods(array $methods) : \Zend_CodeGenerator_Php_Class

setMethods()

Parameters
NameTypeDescription
$methodsarray
Returns
TypeDescription
\Zend_CodeGenerator_Php_Class
methodpublicsetName(string $name) : \Zend_CodeGenerator_Php_Class

setName()

Parameters
NameTypeDescription
$namestring
Returns
TypeDescription
\Zend_CodeGenerator_Php_Class
methodpublicsetOptions(array $options) : \Zend_CodeGenerator_Abstract
Parameters
NameTypeDescription
$optionsarray
Returns
TypeDescription
\Zend_CodeGenerator_Abstract
methodpublicsetProperties(array $properties) : \Zend_CodeGenerator_Php_Class

setProperties()

Parameters
NameTypeDescription
$propertiesarray
Returns
TypeDescription
\Zend_CodeGenerator_Php_Class
methodpublicsetProperty(array | \Zend_CodeGenerator_Php_Property $property) : \Zend_CodeGenerator_Php_Class

setProperty()

Parameters
NameTypeDescription
$propertyarray | \Zend_CodeGenerator_Php_Property
Returns
TypeDescription
\Zend_CodeGenerator_Php_Class
methodpublicsetSourceContent(string $sourceContent) : void
Parameters
NameTypeDescription
$sourceContentstring
methodpublicsetSourceDirty(bool $isSourceDirty = true) : \Zend_CodeGenerator_Php_Abstract
inherited

setSourceDirty()

Inherited from: \Zend_CodeGenerator_Php_Abstract::setSourceDirty()
Parameters
NameTypeDescription
$isSourceDirtybool
Returns
TypeDescription
\Zend_CodeGenerator_Php_Abstract
Documentation was generated by phpDocumentor 2.0.0a12.