Tag/Cloud.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-2014 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
Zend_Tag  
Subpackage
Cloud  
Version
$Id$  

\Zend_Tag_Cloud

Package: Zend_Tag
Category
Zend  
Copyright
Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  

Properties

>VPropertyprotected\Zend_Tag_Cloud_Decorator_Cloud $_cloudDecorator = null
Decorator for the cloud
Default valuenullDetails
Type
\Zend_Tag_Cloud_Decorator_Cloud
>VPropertyprotected\Zend_Loader_PluginLoader $_pluginLoader = null
Plugin loader for decorators
Default valuenullDetails
Type
\Zend_Loader_PluginLoader
>VPropertyprotectedarray $_skipOptions = array('options', 'config')
Option keys to skip when calling setOptions()
Default valuearray('options', 'config')Details
Type
array
>VPropertyprotected\Zend_Tag_Cloud_Decorator_Tag $_tagDecorator = null
Decorator for the tags
Default valuenullDetails
Type
\Zend_Tag_Cloud_Decorator_Tag
>VPropertyprotected\Zend_Tag_ItemList $_tags = null
List of all tags
Default valuenullDetails
Type
\Zend_Tag_ItemList

Methods

methodpublic__construct(mixed $options = null) : void

Create a new tag cloud with options

Parameters
NameTypeDescription
$optionsmixed
methodpublic__toString() : string

Render the tag cloud

Returns
TypeDescription
string
methodpublicaddPrefixPath(string $prefix, string $path) : \Zend_Tag_Cloud

Add prefix path for plugin loader

Parameters
NameTypeDescription
$prefixstring
$pathstring
Returns
TypeDescription
\Zend_Tag_Cloud
methodpublicaddPrefixPaths(array $paths) : \Zend_Tag_Cloud

Add many prefix paths at once

Parameters
NameTypeDescription
$pathsarray
Returns
TypeDescription
\Zend_Tag_Cloud
methodpublicappendTag(\Zend_Tag_Taggable | array $tag) : \Zend_Tag_Cloud

Append a single tag to the cloud

Parameters
NameTypeDescription
$tag\Zend_Tag_Taggable | array
Returns
TypeDescription
\Zend_Tag_Cloud
methodpublicgetCloudDecorator() : \Zend_Tag_Cloud_Decorator_Cloud

Get the decorator for the cloud

Returns
TypeDescription
\Zend_Tag_Cloud_Decorator_Cloud
methodpublicgetItemList() : \Zend_Tag_ItemList

Retrieve the item list

If item list is undefined, creates one.
Returns
TypeDescription
\Zend_Tag_ItemList
methodpublicgetPluginLoader() : \Zend_Loader_PluginLoader

Get the plugin loader for decorators

Returns
TypeDescription
\Zend_Loader_PluginLoader
methodpublicgetTagDecorator() : \Zend_Tag_Cloud_Decorator_Tag

Get the decorator for the tags

Returns
TypeDescription
\Zend_Tag_Cloud_Decorator_Tag
methodpublicrender() : string

Render the tag cloud

Returns
TypeDescription
string
methodpublicsetCloudDecorator(mixed $decorator) : \Zend_Tag_Cloud

Set the decorator for the cloud

Parameters
NameTypeDescription
$decoratormixed
Returns
TypeDescription
\Zend_Tag_Cloud
methodpublicsetConfig(\Zend_Config $config) : \Zend_Tag_Cloud

Set options from Zend_Config

Parameters
NameTypeDescription
$config\Zend_Config
Returns
TypeDescription
\Zend_Tag_Cloud
methodpublicsetItemList(\Zend_Tag_ItemList $itemList) : \Zend_Tag_Cloud

Set the item list

Parameters
NameTypeDescription
$itemList\Zend_Tag_ItemList
Returns
TypeDescription
\Zend_Tag_Cloud
methodpublicsetOptions(array $options) : \Zend_Tag_Cloud

Set options from array

Parameters
NameTypeDescription
$optionsarray

Configuration for Zend_Tag_Cloud

Returns
TypeDescription
\Zend_Tag_Cloud
methodpublicsetPluginLoader(\Zend_Loader_PluginLoader_Interface $loader) : \Zend_Tag_Cloud

Set plugin loaders for use with decorators

Parameters
NameTypeDescription
$loader\Zend_Loader_PluginLoader_Interface
Returns
TypeDescription
\Zend_Tag_Cloud
methodpublicsetTagDecorator(mixed $decorator) : \Zend_Tag_Cloud

Set the decorator for the tags

Parameters
NameTypeDescription
$decoratormixed
Returns
TypeDescription
\Zend_Tag_Cloud
methodpublicsetTags(array $tags) : \Zend_Tag_Cloud

Set the tags for the tag cloud.

$tags should be an array containing single tags as array. Each tag array should at least contain the keys 'title' and 'weight'. Optionally you may supply the key 'url', to which the tag links to. Any additional parameter in the array is silently ignored and can be used by custom decorators.
Parameters
NameTypeDescription
$tagsarray
Returns
TypeDescription
\Zend_Tag_Cloud
Documentation was generated by phpDocumentor 2.2.0 .