PHP Class Pantheon\Terminus\Collections\SavedTokens

Inheritance: extends TerminusCollection, implements Robo\Contract\ConfigAwareInterface, implements Pantheon\Terminus\DataStore\DataStoreAwareInterface, use trait Robo\Common\ConfigAwareTrait, use trait Pantheon\Terminus\DataStore\DataStoreAwareTrait
Show file Open project: pantheon-systems/terminus

Public Properties

Property Type Description
$session Pantheon\Terminus\Session\Session

Protected Properties

Property Type Description
$collected_class string

Public Methods

Method Description
__construct ( $options = [] )
add ( object $model_data, array $options = [] ) : TerminusModel Adds a model to this collection
create ( $token_string ) Saves a machine token to the tokens directory and logs the user in
deleteAll ( ) Delete all of the saved tokens.
get ( string $id ) : SavedToken Retrieves the model with site of the given email or machine token

Protected Methods

Method Description
getCollectionData ( $options = [] )

Method Details

__construct() public method

public __construct ( $options = [] )

add() public method

Adds a model to this collection
public add ( object $model_data, array $options = [] ) : TerminusModel
$model_data object Data to feed into attributes of new model
$options array Data to make properties of the new model
return TerminusModel

create() public method

Saves a machine token to the tokens directory and logs the user in
public create ( $token_string )

deleteAll() public method

Delete all of the saved tokens.
public deleteAll ( )

get() public method

Retrieves the model with site of the given email or machine token
public get ( string $id ) : SavedToken
$id string Email or machine token to look up a saved token by
return Pantheon\Terminus\Models\SavedToken

getCollectionData() protected method

protected getCollectionData ( $options = [] )

Property Details

$collected_class protected property

protected string $collected_class
return string

$session public property

public Session,Pantheon\Terminus\Session $session
return Pantheon\Terminus\Session\Session