PHP Class DataSift\Storyplayer\PlayerLib\Story_Checkpoint

Inheritance: implements IteratorAggregat\IteratorAggregate
Afficher le fichier Open project: datasift/storyplayer

Méthodes publiques

Méthode Description
__construct ( StoryTeller $st ) our constructor
__get ( string $key ) : mixed magic method to retrieve data from the checkpoint
__isset ( string $key ) : boolean magic method to tell if the data is stored in the checkpoint or not
__set ( string $key, mixed $value ) : void magic method to store data in the checkpoint
getData ( ) : stdClass get all the data held inside the checkpoint
getIterator ( ) : Traversable support foreach() loops over our data
getList ( string $propName ) : array retrieve the named property as an associative array, even if it is actually an object
getProperties_asList ( $prefix = null ) : array convert our public properties to an array
getReadOnly ( ) : boolean is the checkpoint currently readonly?
getString ( string $propName, string $default = '' ) : string return the named property as a string, or return the default if the property isn't a string
has ( string $propName ) : boolean Do we have a named property set to non-null?
hasList ( string $propName ) : boolean Do we have a named property, and is it a non-empty array?
is ( string $propName ) : boolean Is the named property set to true?
isNot ( string $propName ) : boolean is the named property set to false?
setReadOnly ( ) put the checkpoint into readonly mode
setReadWrite ( ) put the checkpoint into read-write mode

Method Details

__construct() public méthode

our constructor
public __construct ( StoryTeller $st )
$st StoryTeller The StoryTeller object (which we will cache)

__get() public méthode

throws the E5xx_NoSuchDataInCheckpoint exception if you attempt to get data that does not exist
public __get ( string $key ) : mixed
$key string the name of the data to store
Résultat mixed the data stored in the checkpoint

__isset() public méthode

magic method to tell if the data is stored in the checkpoint or not
public __isset ( string $key ) : boolean
$key string the name of the data to test for
Résultat boolean TRUE if the data exists in the checkpoint FALSE if the data does not exist in the checkpoint

__set() public méthode

throws the E5xx_CheckpointIsReadOnly exception if you attempt to store data when the checkpoint is in readonly mode
public __set ( string $key, mixed $value ) : void
$key string the name of the data to store
$value mixed the value to store in the checkpoint
Résultat void

getData() public méthode

get all the data held inside the checkpoint
public getData ( ) : stdClass
Résultat stdClass

getIterator() public méthode

support foreach() loops over our data
public getIterator ( ) : Traversable
Résultat Traversable

getList() public méthode

retrieve the named property as an associative array, even if it is actually an object
public getList ( string $propName ) : array
$propName string
Résultat array

getProperties_asList() public méthode

convert our public properties to an array
public getProperties_asList ( $prefix = null ) : array
Résultat array

getReadOnly() public méthode

is the checkpoint currently readonly?
public getReadOnly ( ) : boolean
Résultat boolean TRUE if the checkpoint is currently readonly FALSE if you can change the data in the checkpoint

getString() public méthode

return the named property as a string, or return the default if the property isn't a string
public getString ( string $propName, string $default = '' ) : string
$propName string name of property to retrieve
$default string default value to return if property not set
Résultat string

has() public méthode

Do we have a named property set to non-null?
public has ( string $propName ) : boolean
$propName string
Résultat boolean

hasList() public méthode

Do we have a named property, and is it a non-empty array?
public hasList ( string $propName ) : boolean
$propName string
Résultat boolean

is() public méthode

Is the named property set to true?
public is ( string $propName ) : boolean
$propName string
Résultat boolean

isNot() public méthode

is the named property set to false?
public isNot ( string $propName ) : boolean
$propName string
Résultat boolean

setReadOnly() public méthode

put the checkpoint into readonly mode
public setReadOnly ( )

setReadWrite() public méthode

put the checkpoint into read-write mode
public setReadWrite ( )