PHP 클래스 PAGI\Node\NodeController

저자: Marcelo Gornstein ([email protected])
파일 보기 프로젝트 열기: marcelog/pagi 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$client PAGI\Client\IClient The PAGI client in use.
$logger PAGI\Logger\Asterisk\IAsteriskLogger Asterisk logger instance to use.
$nodeResults NodeActionCommand[] All registered node results.
$nodes Node[] All registered nodes.

공개 메소드들

메소드 설명
jumpTo ( string $name ) : void Runs a node and process the result.
register ( string $name ) : Node Registers a new node in the application. Returns the created node.
registerResult ( string $name ) : NodeActionCommand Registers a new node result to be taken into account when the given node is ran.
setAgiClient ( PAGI\Client\IClient $client ) : NodeController Sets the pagi client to use by this node.
setName ( string $name ) : Node Gives a name for this node.

보호된 메소드들

메소드 설명
logDebug ( string $msg ) : void Used internally to log debug messages
processNodeResult ( Node $node ) : string | false Process the result of the given node. Returns false if no other nodes should be run, or a string with the next node name.

메소드 상세

jumpTo() 공개 메소드

Runs a node and process the result.
public jumpTo ( string $name ) : void
$name string Node to run.
리턴 void

logDebug() 보호된 메소드

Used internally to log debug messages
protected logDebug ( string $msg ) : void
$msg string
리턴 void

processNodeResult() 보호된 메소드

Process the result of the given node. Returns false if no other nodes should be run, or a string with the next node name.
protected processNodeResult ( Node $node ) : string | false
$node Node Node that was run.
리턴 string | false

register() 공개 메소드

Registers a new node in the application. Returns the created node.
public register ( string $name ) : Node
$name string The node to be registered
리턴 Node

registerResult() 공개 메소드

Registers a new node result to be taken into account when the given node is ran.
public registerResult ( string $name ) : NodeActionCommand
$name string
리턴 NodeActionCommand

setAgiClient() 공개 메소드

Sets the pagi client to use by this node.
public setAgiClient ( PAGI\Client\IClient $client ) : NodeController
$client PAGI\Client\IClient
리턴 NodeController

setName() 공개 메소드

Gives a name for this node.
public setName ( string $name ) : Node
$name string
리턴 Node

프로퍼티 상세

$client 보호되어 있는 프로퍼티

The PAGI client in use.
protected IClient,PAGI\Client $client
리턴 PAGI\Client\IClient

$logger 보호되어 있는 프로퍼티

Asterisk logger instance to use.
protected IAsteriskLogger,PAGI\Logger\Asterisk $logger
리턴 PAGI\Logger\Asterisk\IAsteriskLogger

$nodeResults 보호되어 있는 프로퍼티

All registered node results.
protected NodeActionCommand[],PAGI\Node $nodeResults
리턴 NodeActionCommand[]

$nodes 보호되어 있는 프로퍼티

All registered nodes.
protected Node[],PAGI\Node $nodes
리턴 Node[]