PHP 클래스 Piwik\Columns\Dimension

부터: 2.5.0
파일 보기 프로젝트 열기: piwik/piwik 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$columnName string This will be the name of the column in the database table if a $columnType is specified.
$columnType string If a columnType is defined, we will create a column in the MySQL table having this type. Please make sure MySQL understands this type. Once you change the column type the Piwik platform will notify the user to perform an update which can sometimes take a long time so be careful when choosing the correct column type.
$segments Piwik\Plugin\Segment[] Holds an array of segment instances

공개 메소드들

메소드 설명
factory ( string $dimensionId ) : Dimension | null Creates a Dimension instance from a string ID (see {@link getId()}).
getAllDimensions ( ) : Dimension[] Gets an instance of all available visit, action and conversion dimension.
getColumnName ( ) : string Get the name of the dimension column.
getDimensions ( Plugin $plugin )
getId ( ) : string Returns a unique string ID for this dimension. The ID is built using the namespaced class name of the dimension, but is modified to be more human readable.
getModule ( ) : string Returns the name of the plugin that contains this Dimension.
getName ( ) : string Get the translated name of the dimension. Defaults to an empty string.
getSegments ( ) : Piwik\Plugin\Segment[] Get the list of configured segments.
hasColumnType ( ) : boolean Check whether the dimension has a column type configured
hasImplementedEvent ( $method ) : boolean Check whether a dimension has overwritten a specific method.

보호된 메소드들

메소드 설명
addSegment ( Piwik\Plugin\Segment $segment ) Adds a new segment. The segment type will be set to 'dimension' automatically if not already set.
configureSegments ( ) Overwrite this method to configure segments. To do so just create an instance of a {@link \Piwik\Plugin\Segment} class, configure it and call the {@link addSegment()} method. You can add one or more segments for this dimension. Example:

메소드 상세

addSegment() 보호된 메소드

Adds a new segment. The segment type will be set to 'dimension' automatically if not already set.
protected addSegment ( Piwik\Plugin\Segment $segment )
$segment Piwik\Plugin\Segment

configureSegments() 보호된 메소드

$segment = new Segment(); $segment->setSegment('exitPageUrl'); $segment->setName('Actions_ColumnExitPageURL'); $segment->setCategory('General_Visit'); $this->addSegment($segment);
protected configureSegments ( )

factory() 공개 정적인 메소드

Creates a Dimension instance from a string ID (see {@link getId()}).
public static factory ( string $dimensionId ) : Dimension | null
$dimensionId string See {@link getId()}.
리턴 Dimension | null The created instance or null if there is no Dimension for $dimensionId or if the plugin that contains the Dimension is not loaded.

getAllDimensions() 공개 정적인 메소드

Gets an instance of all available visit, action and conversion dimension.
public static getAllDimensions ( ) : Dimension[]
리턴 Dimension[]

getColumnName() 공개 메소드

Get the name of the dimension column.
public getColumnName ( ) : string
리턴 string

getDimensions() 공개 정적인 메소드

public static getDimensions ( Plugin $plugin )
$plugin Piwik\Plugin

getId() 공개 메소드

Returns a unique string ID for this dimension. The ID is built using the namespaced class name of the dimension, but is modified to be more human readable.
public getId ( ) : string
리턴 string eg, `"Referrers.Keywords"`

getModule() 공개 메소드

Returns the name of the plugin that contains this Dimension.
public getModule ( ) : string
리턴 string

getName() 공개 메소드

Get the translated name of the dimension. Defaults to an empty string.
public getName ( ) : string
리턴 string

getSegments() 공개 메소드

Get the list of configured segments.
public getSegments ( ) : Piwik\Plugin\Segment[]
리턴 Piwik\Plugin\Segment[]

hasColumnType() 공개 메소드

Check whether the dimension has a column type configured
public hasColumnType ( ) : boolean
리턴 boolean

hasImplementedEvent() 공개 메소드

Check whether a dimension has overwritten a specific method.
public hasImplementedEvent ( $method ) : boolean
$method
리턴 boolean

프로퍼티 상세

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

This will be the name of the column in the database table if a $columnType is specified.
protected string $columnName
리턴 string

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

If a columnType is defined, we will create a column in the MySQL table having this type. Please make sure MySQL understands this type. Once you change the column type the Piwik platform will notify the user to perform an update which can sometimes take a long time so be careful when choosing the correct column type.
protected string $columnType
리턴 string

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

Holds an array of segment instances
protected Segment[],Piwik\Plugin $segments
리턴 Piwik\Plugin\Segment[]