PHP Class RTMediaUserInteraction, rtMedia

Author: saurabh
Mostrar archivo Open project: rtCamp/rtMedia Class Usage Examples

Public Properties

Property Type Description
$action The singular action word (like, unlike, view, download, etc)
$action_query The action query populated by the default query
$actions The plural of the action (likes, unlikes, etc)
$increase Whether the action increases the count or decreases the count
$interactor
$media
$model The db model
$owner
$privacy

Public Methods

Method Description
__construct ( array $args = [] ) Initialise the user interaction
before_render ( )
button_filter ( $buttons )
init ( )
interactor_privacy ( )
is_clickable ( )
is_visible ( )
preprocess ( ) Checks if an id is set Creates pre and post process hooks for the action Calls the process
process ( ) : integer Updates count of the action
register ( array $actions ) : array
render ( )
set_interactor ( )
set_label ( ) Checks if there's a label, if not creates from the action name
set_media ( )
set_plural ( )

Method Details

__construct() public method

Initialise the user interaction
public __construct ( array $args = [] )
$args array

before_render() public method

public before_render ( )

button_filter() public method

public button_filter ( $buttons )

init() public method

public init ( )

interactor_privacy() public method

public interactor_privacy ( )

is_clickable() public method

public is_clickable ( )

is_visible() public method

public is_visible ( )

preprocess() public method

Checks if an id is set Creates pre and post process hooks for the action Calls the process
public preprocess ( )

process() public method

Updates count of the action
public process ( ) : integer
return integer New count

register() public method

public register ( array $actions ) : array
$actions array The default array of actions
return array $actions Filtered actions array

render() public method

public render ( )

set_interactor() public method

public set_interactor ( )

set_label() public method

Checks if there's a label, if not creates from the action name
public set_label ( )

set_media() public method

public set_media ( )

set_plural() public method

public set_plural ( )

Property Details

$action public_oe property

The singular action word (like, unlike, view, download, etc)
public $action

$action_query public_oe property

The action query populated by the default query
public $action_query

$actions public_oe property

The plural of the action (likes, unlikes, etc)
public $actions

$increase public_oe property

Whether the action increases the count or decreases the count
public $increase

$interactor public_oe property

public $interactor

$media public_oe property

public $media

$model public_oe property

The db model
public $model

$owner public_oe property

public $owner

$privacy public_oe property

public $privacy