PHP Class Scalr\Api\Service\User\V1beta0\Controller\Events

Since: 5.4 (07.05.2015)
Author: Vlad Dobrovolskiy ([email protected])
Inheritance: extends Scalr\Api\Rest\Controller\ApiController
Show file Open project: scalr/scalr

Public Methods

Method Description
createAction ( ) : Scalr\Api\DataType\ResultEnvelope Creates new event in current scope
deleteAction ( string $eventId ) : Scalr\Api\DataType\ResultEnvelope Deletes the event from the curent scope
describeAction ( ) Gets Events list
fetchAction ( string $eventId ) : Scalr\Api\DataType\ResultEnvelope Fetches detailed info about the Event
getEvent ( string $eventId, boolean $restrictToCurrentScope = false ) : EventDefinition | null Gets event from database using User's Account
getScope ( ) : string Gets current scope
modifyAction ( string $eventId ) : Scalr\Api\DataType\ResultEnvelope Modifies event from current scope

Private Methods

Method Description
getDefaultCriteria ( ) : array Gets Default search criteria for the Account scope

Method Details

createAction() public method

Creates new event in current scope
public createAction ( ) : Scalr\Api\DataType\ResultEnvelope
return Scalr\Api\DataType\ResultEnvelope

deleteAction() public method

Deletes the event from the curent scope
public deleteAction ( string $eventId ) : Scalr\Api\DataType\ResultEnvelope
$eventId string Unique identifier of the Event
return Scalr\Api\DataType\ResultEnvelope

describeAction() public method

Gets Events list
public describeAction ( )

fetchAction() public method

Fetches detailed info about the Event
public fetchAction ( string $eventId ) : Scalr\Api\DataType\ResultEnvelope
$eventId string Unique identifier of the Event
return Scalr\Api\DataType\ResultEnvelope

getEvent() public method

Gets event from database using User's Account
public getEvent ( string $eventId, boolean $restrictToCurrentScope = false ) : EventDefinition | null
$eventId string The identifier of the Event
$restrictToCurrentScope boolean optional Whether it should additionally check that event corresponds to current scope
return Scalr\Model\Entity\EventDefinition | null Returns Event Definition entity on success or NULL otherwise

getScope() public method

Gets current scope
public getScope ( ) : string
return string

modifyAction() public method

Modifies event from current scope
public modifyAction ( string $eventId ) : Scalr\Api\DataType\ResultEnvelope
$eventId string Unique identifier of the Event
return Scalr\Api\DataType\ResultEnvelope