PHP Class Piwik\Tracker\Action

Datei anzeigen Open project: piwik/piwik Class Usage Examples

Public Properties

Property Type Description
$request Request Public so that events listener can access it

Public Methods

Method Description
__construct ( $type, Request $request )
factory ( Request $request ) : Action Makes the correct Action object based on the request.
getActionName ( )
getActionType ( )
getActionUrl ( ) : string Returns URL of the page currently being tracked, or the file being downloaded, or the outlink being clicked
getActionUrlRaw ( ) Returns URL of page being tracked, including all original Query parameters
getCustomFields ( )
getCustomFloatValue ( ) custom_float column
getCustomVariables ( )
getIdActionName ( )
getIdActionNameForEntryAndExitIds ( )
getIdActionUrl ( )
getIdActionUrlForEntryAndExitIds ( )
getIdLinkVisitAction ( ) : integer Returns the ID of the newly created record in the log_link_visit_action table
getTypeAsString ( $type )
loadIdsFromLogActionTable ( ) Loads the idaction of the current action name and the current action url.
record ( Piwik\Tracker\Visitor $visitor, integer $idReferrerActionUrl, $idReferrerActionName ) Records in the DB the association between the visit and this action.
setCustomField ( $field, $value )
shouldHandle ( Request $request )
writeDebugInfo ( )

Protected Methods

Method Description
getActionsToLookup ( )
getUrlAndType ( )
setActionName ( $name )
setActionUrl ( $url )
setActionUrlWithoutExcludingParameters ( $url )

Private Methods

Method Description
getAllActions ( Request $request )
getModel ( )
getPriority ( Action $actionType )
isActionHasActionName ( ) : boolean

Method Details

__construct() public method

public __construct ( $type, Request $request )
$request Request

factory() public static method

Makes the correct Action object based on the request.
public static factory ( Request $request ) : Action
$request Request
return Action

getActionName() public method

public getActionName ( )

getActionType() public method

public getActionType ( )

getActionUrl() public method

Returns URL of the page currently being tracked, or the file being downloaded, or the outlink being clicked
public getActionUrl ( ) : string
return string

getActionUrlRaw() public method

Returns URL of page being tracked, including all original Query parameters
public getActionUrlRaw ( )

getActionsToLookup() abstract protected method

abstract protected getActionsToLookup ( )

getCustomFields() public method

public getCustomFields ( )

getCustomFloatValue() public method

custom_float column
public getCustomFloatValue ( )

getCustomVariables() public method

public getCustomVariables ( )

getIdActionName() public method

public getIdActionName ( )

getIdActionNameForEntryAndExitIds() public method

getIdActionUrl() public method

public getIdActionUrl ( )

getIdActionUrlForEntryAndExitIds() public method

getIdLinkVisitAction() public method

Returns the ID of the newly created record in the log_link_visit_action table
public getIdLinkVisitAction ( ) : integer
return integer

getTypeAsString() public static method

public static getTypeAsString ( $type )

getUrlAndType() protected method

protected getUrlAndType ( )

loadIdsFromLogActionTable() public method

These idactions are used in the visitor logging table to link the visit information (entry action, exit action) to the actions. These idactions are also used in the table that links the visits and their actions. The methods takes care of creating a new record(s) in the action table if the existing action name and action url doesn't exist yet.

record() public method

Records in the DB the association between the visit and this action.
public record ( Piwik\Tracker\Visitor $visitor, integer $idReferrerActionUrl, $idReferrerActionName )
$visitor Piwik\Tracker\Visitor
$idReferrerActionUrl integer is the ID of the last action done by the current visit.
$idReferrerActionName

setActionName() protected method

protected setActionName ( $name )

setActionUrl() protected method

protected setActionUrl ( $url )

setActionUrlWithoutExcludingParameters() protected method

setCustomField() public method

public setCustomField ( $field, $value )

shouldHandle() public static method

public static shouldHandle ( Request $request )
$request Request

writeDebugInfo() public method

public writeDebugInfo ( )

Property Details

$request public_oe property

Public so that events listener can access it
public Request,Piwik\Tracker $request
return Request