PHP 클래스 Horde_Core_Ui_TagCloud, horde

Based on a striped down version of Pear's HTML_TagCloud Copyright 2009-2016 Horde LLC (http://www.horde.org/) See the enclosed file COPYING for license information (LGPL). If you did not receive this file, see http://www.horde.org/licenses/lgpl21.
파일 보기 프로젝트 열기: horde/horde 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$basefontsize integer
$css_class string
$epoc_level array
$factor integer
$fontsizerange integer
$size_suffix string mm,cm,in,pt,pc,px,em

보호된 프로퍼티들

프로퍼티 타입 설명
$_elements array
$_map array
$_max integer
$_max_epoc integer
$_min integer
$_min_epoc integer

공개 메소드들

메소드 설명
__construct ( integer $basefontsize = 24, integer $fontsizerange = 12 ) Constructor
addElement ( string $name, string $url = '', integer $count, integer $timestamp = null, string $onclick = null ) Add a Tag Element to build Tag Cloud.
addElements ( array $tags ) Add a Tag Element to build Tag Cloud.
buildHTML ( array $param = [] ) : string Build HTML part.
clearElements ( ) Clear Tag Elements.
cmpElementsName ( $a, $b ) : integer Using for usort().

보호된 메소드들

메소드 설명
_buidHTMLTags ( array $param ) : string Calc Tag level and create whole HTML of each Tags.
_calcMumCount ( ) Calc max and min tag count of use.
_calcMumEpoc ( ) Calc max and min timestamp.
_createHTMLTag ( array $tag, string $type, integer $fontsize ) : string Create a Element of HTML part.
_getCountLevel ( integer $count ) : integer Calc Tag Level of size.
_getEpocLevel ( integer $timestamp ) : integer Calc timeline level of Tag.
_sortTags ( integer $limit ) Sort tags by name.
_wrapDiv ( string $html ) : string Wrap div tag.

메소드 상세

__construct() 공개 메소드

Constructor
public __construct ( integer $basefontsize = 24, integer $fontsizerange = 12 )
$basefontsize integer Base font size of output tag (option).
$fontsizerange integer Font size range.

_buidHTMLTags() 보호된 메소드

Calc Tag level and create whole HTML of each Tags.
protected _buidHTMLTags ( array $param ) : string
$param array Limit of Tag Number.
리턴 string HTML

_calcMumCount() 보호된 메소드

Calc max and min tag count of use.
protected _calcMumCount ( )

_calcMumEpoc() 보호된 메소드

Calc max and min timestamp.
protected _calcMumEpoc ( )

_createHTMLTag() 보호된 메소드

Create a Element of HTML part.
protected _createHTMLTag ( array $tag, string $type, integer $fontsize ) : string
$tag array TODO
$type string CSS class of time line param.
$fontsize integer TODO
리턴 string a Element of Tag HTML

_getCountLevel() 보호된 메소드

Calc Tag Level of size.
protected _getCountLevel ( integer $count ) : integer
$count integer TODO
리턴 integer Level.

_getEpocLevel() 보호된 메소드

Calc timeline level of Tag.
protected _getEpocLevel ( integer $timestamp ) : integer
$timestamp integer TODO
리턴 integer Level of timeline.

_sortTags() 보호된 메소드

Sort tags by name.
protected _sortTags ( integer $limit )
$limit integer Limit element number of create TagCloud.

_wrapDiv() 보호된 메소드

Wrap div tag.
protected _wrapDiv ( string $html ) : string
$html string TODO
리턴 string TODO

addElement() 공개 메소드

Add a Tag Element to build Tag Cloud.
public addElement ( string $name, string $url = '', integer $count, integer $timestamp = null, string $onclick = null )
$name string TODO
$url string TODO
$count integer TODO
$timestamp integer UNIX timestamp.
$onclick string Javascript onclick event handler.

addElements() 공개 메소드

Add a Tag Element to build Tag Cloud.
public addElements ( array $tags )
$tags array Associative array to $this->_elements.

buildHTML() 공개 메소드

Build HTML part.
public buildHTML ( array $param = [] ) : string
$param array 'limit' => int limit of generation tag num.
리턴 string HTML

clearElements() 공개 메소드

Clear Tag Elements.
public clearElements ( )

cmpElementsName() 공개 메소드

Using for usort().
public cmpElementsName ( $a, $b ) : integer
리턴 integer TODO

프로퍼티 상세

$_elements 보호되어 있는 프로퍼티

protected array $_elements
리턴 array

$_map 보호되어 있는 프로퍼티

protected array $_map
리턴 array

$_max 보호되어 있는 프로퍼티

protected int $_max
리턴 integer

$_max_epoc 보호되어 있는 프로퍼티

protected int $_max_epoc
리턴 integer

$_min 보호되어 있는 프로퍼티

protected int $_min
리턴 integer

$_min_epoc 보호되어 있는 프로퍼티

protected int $_min_epoc
리턴 integer

$basefontsize 공개적으로 프로퍼티

public int $basefontsize
리턴 integer

$css_class 공개적으로 프로퍼티

public string $css_class
리턴 string

$epoc_level 공개적으로 프로퍼티

public array $epoc_level
리턴 array

$factor 공개적으로 프로퍼티

public int $factor
리턴 integer

$fontsizerange 공개적으로 프로퍼티

public int $fontsizerange
리턴 integer

$size_suffix 공개적으로 프로퍼티

mm,cm,in,pt,pc,px,em
public string $size_suffix
리턴 string