PHP Класс Pop\Code\Generator\PropertyGenerator

Автор: Nick Sagona, III ([email protected])
Наследование: implements Pop\Code\Generator\GeneratorInterface
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$docblock DocblockGenerator Docblock generator object
$indent string Property indent
$name string Property name
$output string Property output
$static boolean Property static flag
$type string Property type
$value mixed Property value
$visibility string Property visibility

Открытые методы

Метод Описание
__construct ( string $name, string $type, mixed $value = null, string $visibility = 'public' ) : PropertyGenerator Constructor
__toString ( ) : string Print property
factory ( string $name, string $type, mixed $value = null, string $visibility = 'public' ) : PropertyGenerator Static method to instantiate the property generator object and return itself to facilitate chaining methods together.
getDesc ( ) : string Get the property description
getDocblock ( ) : DocblockGenerator Access the docblock generator object
getIndent ( ) : string Get the property indent
getName ( ) : string Get the property name
getType ( ) : string Get the property type
getValue ( ) : mixed Get the property value
getVisibility ( ) : string Get the property visibility
isStatic ( ) : boolean Get the property static flag
render ( boolean $ret = false ) : mixed Render property
setDesc ( string $desc = null ) : PropertyGenerator Set the property description
setDocblock ( DocblockGenerator $docblock ) : PropertyGenerator Set the docblock generator object
setIndent ( string $indent = null ) : PropertyGenerator Set the property indent
setName ( string $name ) : PropertyGenerator Set the property name
setStatic ( boolean $static = false ) : PropertyGenerator Set the property static flag
setType ( string $type ) : PropertyGenerator Set the property type
setValue ( mixed $value = null ) : PropertyGenerator Set the property value
setVisibility ( string $visibility = 'public' ) : PropertyGenerator Set the property visibility

Защищенные методы

Метод Описание
formatArrayValues ( ) : string Format array value

Описание методов

__construct() публичный Метод

Instantiate the property generator object
public __construct ( string $name, string $type, mixed $value = null, string $visibility = 'public' ) : PropertyGenerator
$name string
$type string
$value mixed
$visibility string
Результат PropertyGenerator

__toString() публичный Метод

Print property
public __toString ( ) : string
Результат string

factory() публичный статический Метод

Static method to instantiate the property generator object and return itself to facilitate chaining methods together.
public static factory ( string $name, string $type, mixed $value = null, string $visibility = 'public' ) : PropertyGenerator
$name string
$type string
$value mixed
$visibility string
Результат PropertyGenerator

formatArrayValues() защищенный Метод

Format array value
protected formatArrayValues ( ) : string
Результат string

getDesc() публичный Метод

Get the property description
public getDesc ( ) : string
Результат string

getDocblock() публичный Метод

Access the docblock generator object
public getDocblock ( ) : DocblockGenerator
Результат DocblockGenerator

getIndent() публичный Метод

Get the property indent
public getIndent ( ) : string
Результат string

getName() публичный Метод

Get the property name
public getName ( ) : string
Результат string

getType() публичный Метод

Get the property type
public getType ( ) : string
Результат string

getValue() публичный Метод

Get the property value
public getValue ( ) : mixed
Результат mixed

getVisibility() публичный Метод

Get the property visibility
public getVisibility ( ) : string
Результат string

isStatic() публичный Метод

Get the property static flag
public isStatic ( ) : boolean
Результат boolean

render() публичный Метод

Render property
public render ( boolean $ret = false ) : mixed
$ret boolean
Результат mixed

setDesc() публичный Метод

Set the property description
public setDesc ( string $desc = null ) : PropertyGenerator
$desc string
Результат PropertyGenerator

setDocblock() публичный Метод

Set the docblock generator object
public setDocblock ( DocblockGenerator $docblock ) : PropertyGenerator
$docblock DocblockGenerator
Результат PropertyGenerator

setIndent() публичный Метод

Set the property indent
public setIndent ( string $indent = null ) : PropertyGenerator
$indent string
Результат PropertyGenerator

setName() публичный Метод

Set the property name
public setName ( string $name ) : PropertyGenerator
$name string
Результат PropertyGenerator

setStatic() публичный Метод

Set the property static flag
public setStatic ( boolean $static = false ) : PropertyGenerator
$static boolean
Результат PropertyGenerator

setType() публичный Метод

Set the property type
public setType ( string $type ) : PropertyGenerator
$type string
Результат PropertyGenerator

setValue() публичный Метод

Set the property value
public setValue ( mixed $value = null ) : PropertyGenerator
$value mixed
Результат PropertyGenerator

setVisibility() публичный Метод

Set the property visibility
public setVisibility ( string $visibility = 'public' ) : PropertyGenerator
$visibility string
Результат PropertyGenerator

Описание свойств

$docblock защищенное свойство

Docblock generator object
protected DocblockGenerator,Pop\Code\Generator $docblock
Результат DocblockGenerator

$indent защищенное свойство

Property indent
protected string $indent
Результат string

$name защищенное свойство

Property name
protected string $name
Результат string

$output защищенное свойство

Property output
protected string $output
Результат string

$static защищенное свойство

Property static flag
protected bool $static
Результат boolean

$type защищенное свойство

Property type
protected string $type
Результат string

$value защищенное свойство

Property value
protected mixed $value
Результат mixed

$visibility защищенное свойство

Property visibility
protected string $visibility
Результат string