PHP 클래스 Piwik\Category\Subcategory

All widgets within a subcategory will be rendered in the Piwik reporting UI under the same page. By default you do not have to specify any subcategory as they are created automatically. Only create a subcategory if you want to change the name for a specific subcategoryId or if you want to specifiy a different order so the subcategory appears eg at a different order in the reporting menu. It also affects the order of reports in API.getReportMetadata and wherever we display any reports. To define a subcategory just place a subclass within the Categories folder of your plugin. Subcategories can also be added through the {@hook Subcategory.addSubcategories} event.
파일 보기 프로젝트 열기: piwik/piwik 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$categoryId See {@link Piwik\Widget\WidgetConfig::setCategoryId()`} or {@link Piwik\Report\getCategoryId()}.
$id For example you might want to have the actual GoalId (eg '4') in the URL but the actual goal name in the submenu (eg 'Downloads'). In this case one should specify $id=4;$name='Downloads'.
$name string The name that shall be used in the menu etc, defaults to the specified {@link $id}. See {@link $id}.
$order integer The order of the subcategory. The lower the value the earlier a widget or a report will be displayed.

공개 메소드들

메소드 설명
getCategoryId ( ) : string Get the specifed categoryId see {@link $categoryId}.
getId ( ) : string Get the id of the subcategory.
getName ( ) : string Get the name of the subcategory.
getOrder ( ) : integer Get the order of the subcategory.
setCategoryId ( string $categoryId ) : static Sets (overwrites) the categoryId see {@link $categoryId}.
setId ( string $id ) : static Sets (overwrites) the id of the subcategory see {@link $id}.
setName ( string $name ) : static Sets (overwrites) the name see {@link $name} and {@link $id}.
setOrder ( integer $order ) : static Sets (overwrites) the order see {@link $order}.

메소드 상세

getCategoryId() 공개 메소드

Get the specifed categoryId see {@link $categoryId}.
public getCategoryId ( ) : string
리턴 string

getId() 공개 메소드

Get the id of the subcategory.
public getId ( ) : string
리턴 string

getName() 공개 메소드

Get the name of the subcategory.
public getName ( ) : string
리턴 string

getOrder() 공개 메소드

Get the order of the subcategory.
public getOrder ( ) : integer
리턴 integer

setCategoryId() 공개 메소드

Sets (overwrites) the categoryId see {@link $categoryId}.
public setCategoryId ( string $categoryId ) : static
$categoryId string
리턴 static

setId() 공개 메소드

Sets (overwrites) the id of the subcategory see {@link $id}.
public setId ( string $id ) : static
$id string A translation key eg 'General_Overview'.
리턴 static

setName() 공개 메소드

Sets (overwrites) the name see {@link $name} and {@link $id}.
public setName ( string $name ) : static
$name string A translation key eg 'General_Overview'.
리턴 static

setOrder() 공개 메소드

Sets (overwrites) the order see {@link $order}.
public setOrder ( integer $order ) : static
$order integer
리턴 static

프로퍼티 상세

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

See {@link Piwik\Widget\WidgetConfig::setCategoryId()`} or {@link Piwik\Report\getCategoryId()}.
protected $categoryId

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

For example you might want to have the actual GoalId (eg '4') in the URL but the actual goal name in the submenu (eg 'Downloads'). In this case one should specify $id=4;$name='Downloads'.
protected $id

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

The name that shall be used in the menu etc, defaults to the specified {@link $id}. See {@link $id}.
protected string $name
리턴 string

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

The order of the subcategory. The lower the value the earlier a widget or a report will be displayed.
protected int $order
리턴 integer