Abstract class representing container for placeholder values

package Zend_View
subpackage Helper
copyright Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
license New BSD License

 Methods

Constructor - This is needed so that we can attach a class member as the ArrayObject container

__construct() : \Zend_View_Helper_Placeholder_Container_Abstract

Returns

\Zend_View_Helper_Placeholder_Container_Abstract

Serialize object to string

__toString() : string

Returns

string

End content capture

captureEnd() : void

Start capturing content to push into placeholder

captureStart(integer|string $type = \Zend_View_Helper_Placeholder_Container_Abstract::APPEND, null $key = null) : void

Parameters

$type

integerstring

How to capture content into placeholder; append, prepend, or set

$key

null

Exceptions

\Zend_View_Helper_Placeholder_Container_Exception

Retrieve indentation

getIndent() : string

Returns

string

Get keys

getKeys() : array

Returns

array

Retrieve postfix

getPostfix() : string

Returns

string

Retrieve prefix

getPrefix() : string

Returns

string

Retrieve separator

getSeparator() : string

Returns

string

Retrieve container value

getValue() : mixed

If single element registered, returns that element; otherwise, serializes to array.

Returns

mixed

Retrieve whitespace representation of $indent

getWhitespace(integer|string $indent) : string

Parameters

$indent

integerstring

Returns

string

Next Index

nextIndex() : integer

as defined by the PHP manual

Returns

integer

Prepend a value to the top of the container

prepend(mixed $value) : void

Parameters

$value

mixed

Set a single value

set(mixed $value) : void

Parameters

$value

mixed

Set the indentation string for __toString() serialization, optionally, if a number is passed, it will be the number of spaces

setIndent(string|integer $indent) : \Zend_View_Helper_Placeholder_Container_Abstract

Parameters

$indent

stringinteger

Returns

\Zend_View_Helper_Placeholder_Container_Abstract

Set postfix for __toString() serialization

setPostfix(string $postfix) : \Zend_View_Helper_Placeholder_Container

Parameters

$postfix

string

Returns

\Zend_View_Helper_Placeholder_Container

Set prefix for __toString() serialization

setPrefix(string $prefix) : \Zend_View_Helper_Placeholder_Container

Parameters

$prefix

string

Returns

\Zend_View_Helper_Placeholder_Container

Set separator for __toString() serialization

setSeparator(string $separator) : \Zend_View_Helper_Placeholder_Container

Used to implode elements in container

Parameters

$separator

string

Returns

\Zend_View_Helper_Placeholder_Container

Render the placeholder

toString(null $indent = null) : string

Parameters

$indent

null

Returns

string

 Properties

 

Key to which to capture content

$_captureKey : string

Default

 

Whether or not we're already capturing for this given container

$_captureLock : boolean

Default

false
 

What type of capture (overwrite (set), append, prepend) to use

$_captureType : string

Default

 

What string to use as the indentation of output, this will typically be spaces. Eg: ' '

$_indent : string

Default

''
 

What text to append the placeholder with when rendering

$_postfix : string

Default

''
 

What text to prefix the placeholder with when rendering

$_prefix : string

Default

''
 

What string to use between individual items in the placeholder when rendering

$_separator : string

Default

''

 Constants

 

Whether or not to append contents to placeholder

APPEND = 'APPEND' 
const string
 

Whether or not to prepend contents to placeholder

PREPEND = 'PREPEND' 
const string
 

Whether or not to override all contents of placeholder

SET = 'SET' 
const string