CodeGenerator/Php/Class.php

Show: inherited
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 [email protected] 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

Constant  LINE_FEED = "\n"
inherited

Line feed to use in place of EOL

Inherited from: \Zend_CodeGenerator_Php_Abstract::LINE_FEED

Properties

Propertyprotectedarray $_constants = null

<p>Array of constants</p>
Default valuenullDetails
Type
array
Propertyprotected\Zend_CodeGenerator_Php_Docblock $_docblock = null

Default valuenullDetails
Type
\Zend_CodeGenerator_Php_Docblock
Propertyprotectedstring $_extendedClass = null

Default valuenullDetails
Type
string
Propertyprotectedarray $_implementedInterfaces = array()

<p>Array of string names</p>
Default valuearray()Details
Type
array
Propertyprotectedint|string $_indentation = ' '
Default value' 'Details
Type
int | string
Inherited_from
\Zend_CodeGenerator_Php_Abstract::$$_indentation  
Propertyprotectedbool $_isAbstract = false

Default valuefalseDetails
Type
bool
Propertyprotectedbool $_isSourceDirty = true
Default valuetrueDetails
Type
bool
Inherited_from
\Zend_CodeGenerator_Php_Abstract::$$_isSourceDirty  
Propertyprotectedarray $_methods = null

<p>Array of methods</p>
Default valuenullDetails
Type
array
Propertyprotectedstring $_name = null

Default valuenullDetails
Type
string
Propertyprotectedarray $_properties = null

<p>Array of properties</p>
Default valuenullDetails
Type
array
Propertyprotectedstring $_sourceContent = null
Default valuenullDetails
Type
string
Inherited_from
\Zend_CodeGenerator_Abstract::$$_sourceContent  
Inherited_from
\Zend_CodeGenerator_Php_Abstract::$$_sourceContent  

Methods

methodpublic__construct(array $options = array()) : void
Parameters
Name Type Description
$options array
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
Type Description
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
Name Type Description
$reflectionClass \Zend_Reflection_Class
Returns
Type Description
\Zend_CodeGenerator_Php_Class
methodpublicgenerate() : string

generate()

Returns
Type Description
string
methodpublicgetConstant(string $constName) : \Zend_CodeGenerator_Php_Property

getConstant()

Parameters
Name Type Description
$constName string
Returns
Type Description
\Zend_CodeGenerator_Php_Property
methodpublicgetConstants() : array

getConstants()

Returns
Type Description
array
methodpublicgetDocblock() : \Zend_CodeGenerator_Php_Docblock

getDocblock()

Returns
Type Description
\Zend_CodeGenerator_Php_Docblock
methodpublicgetExtendedClass() : string

getExtendedClass()

Returns
Type Description
string
methodpublicgetImplementedInterfaces() : array

getImplementedInterfaces

Returns
Type Description
array
methodpublicgetIndentation() : string | int
inherited

getIndentation()

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

getMethod()

Parameters
Name Type Description
$methodName string
Returns
Type Description
\Zend_CodeGenerator_Php_Method
methodpublicgetMethods() : array

getMethods()

Returns
Type Description
array
methodpublicgetName() : string

getName()

Returns
Type Description
string
methodpublicgetProperties() : array

getProperties()

Returns
Type Description
array
methodpublicgetProperty(string $propertyName) : \Zend_CodeGenerator_Php_Property

getProperty()

Parameters
Name Type Description
$propertyName string
Returns
Type Description
\Zend_CodeGenerator_Php_Property
methodpublicgetSourceContent() : string
Returns
Type Description
string
methodpublichasConstant(string $constName) : bool

hasConstant()

Parameters
Name Type Description
$constName string
Returns
Type Description
bool
methodpublichasMethod(string $methodName) : bool

hasMethod()

Parameters
Name Type Description
$methodName string
Returns
Type Description
bool
methodpublichasProperty(string $propertyName) : bool

hasProperty()

Parameters
Name Type Description
$propertyName string
Returns
Type Description
bool
methodpublicisAbstract() : bool

isAbstract()

Returns
Type Description
bool
methodpublicisSourceDirty() : bool

isSourceDirty()

Returns
Type Description
bool
methodpublicsetAbstract(bool $isAbstract) : \Zend_CodeGenerator_Php_Class

setAbstract()

Parameters
Name Type Description
$isAbstract bool
Returns
Type Description
\Zend_CodeGenerator_Php_Class
methodpublicsetConfig(\Zend_Config $config) : \Zend_CodeGenerator_Abstract
Parameters
Name Type Description
$config \Zend_Config
Returns
Type Description
\Zend_CodeGenerator_Abstract
methodpublicsetConstant(array | \Zend_CodeGenerator_Php_Property $const) : \Zend_CodeGenerator_Php_Class

setConstant()

Parameters
Name Type Description
$const array | \Zend_CodeGenerator_Php_Property
Returns
Type Description
\Zend_CodeGenerator_Php_Class
methodpublicsetConstants(array $constants) : \Zend_CodeGenerator_Php_Class

setConstants()

Parameters
Name Type Description
$constants array
Returns
Type Description
\Zend_CodeGenerator_Php_Class
methodpublicsetDocblock(\Zend_CodeGenerator_Php_Docblock | array | string $docblock) : \Zend_CodeGenerator_Php_File

setDocblock() Set the docblock

Parameters
Name Type Description
$docblock \Zend_CodeGenerator_Php_Docblock | array | string
Returns
Type Description
\Zend_CodeGenerator_Php_File
methodpublicsetExtendedClass(string $extendedClass) : \Zend_CodeGenerator_Php_Class

setExtendedClass()

Parameters
Name Type Description
$extendedClass string
Returns
Type Description
\Zend_CodeGenerator_Php_Class
methodpublicsetImplementedInterfaces(array $implementedInterfaces) : \Zend_CodeGenerator_Php_Class

setImplementedInterfaces()

Parameters
Name Type Description
$implementedInterfaces array
Returns
Type Description
\Zend_CodeGenerator_Php_Class
methodpublicsetIndentation(string | int $indentation) : \Zend_CodeGenerator_Php_Abstract
inherited

setIndentation()

Inherited from: \Zend_CodeGenerator_Php_Abstract::setIndentation()
Parameters
Name Type Description
$indentation string | int
Returns
Type Description
\Zend_CodeGenerator_Php_Abstract
methodpublicsetMethod(array | \Zend_CodeGenerator_Php_Method $method) : \Zend_CodeGenerator_Php_Class

setMethod()

Parameters
Name Type Description
$method array | \Zend_CodeGenerator_Php_Method
Returns
Type Description
\Zend_CodeGenerator_Php_Class
methodpublicsetMethods(array $methods) : \Zend_CodeGenerator_Php_Class

setMethods()

Parameters
Name Type Description
$methods array
Returns
Type Description
\Zend_CodeGenerator_Php_Class
methodpublicsetName(string $name) : \Zend_CodeGenerator_Php_Class

setName()

Parameters
Name Type Description
$name string
Returns
Type Description
\Zend_CodeGenerator_Php_Class
methodpublicsetOptions(array $options) : \Zend_CodeGenerator_Abstract
Parameters
Name Type Description
$options array
Returns
Type Description
\Zend_CodeGenerator_Abstract
methodpublicsetProperties(array $properties) : \Zend_CodeGenerator_Php_Class

setProperties()

Parameters
Name Type Description
$properties array
Returns
Type Description
\Zend_CodeGenerator_Php_Class
methodpublicsetProperty(array | \Zend_CodeGenerator_Php_Property $property) : \Zend_CodeGenerator_Php_Class

setProperty()

Parameters
Name Type Description
$property array | \Zend_CodeGenerator_Php_Property
Returns
Type Description
\Zend_CodeGenerator_Php_Class
methodpublicsetSourceContent(string $sourceContent) : void
Parameters
Name Type Description
$sourceContent string
methodpublicsetSourceDirty(bool $isSourceDirty = true) : \Zend_CodeGenerator_Php_Abstract
inherited

setSourceDirty()

Inherited from: \Zend_CodeGenerator_Php_Abstract::setSourceDirty()
Parameters
Name Type Description
$isSourceDirty bool
Returns
Type Description
\Zend_CodeGenerator_Php_Abstract
Documentation was generated by phpDocumentor 2.0.0a8.