PHP 클래스 Horde_SyncMl_Command, horde

A SyncML command is a protocol primitive. Each SyncML command specifies to a recipient an individual operation that is to be performed. The Horde_SyncMl_Command objects are hooked into the XML parser of the Horde_SyncMl_ContentHandler class and are reponsible for parsing a single command inside the SyncBody section of a SyncML message. All actions that must be executed for a single SyncML command are handled by these objects, by means of the handleCommand() method. Copyright 2003-2016 Horde LLC (http://www.horde.org/) See the enclosed file COPYING for license information (LGPL). If you did not receive this file, see http://www.horde.org/licenses/lgpl21.
저자: Anthony Mills ([email protected])
저자: Jan Schneider ([email protected])
파일 보기 프로젝트 열기: horde/horde 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$_chars string Buffer for the parsed character data.
$_cmdID integer The command ID ().
$_cmdName string Must be overwritten by a sub class.
$_outputHandler Horde_SyncMl_XmlOutput A Horde_SyncMl_XmlOutput instance responsible for generating the output.
$_stack array Stack for holding the XML elements during creation of the object from the XML event flow.

공개 메소드들

메소드 설명
__construct ( Horde_SyncMl_XmlOutput &$outputHandler ) Constructor.
characters ( string $str ) Character data handler for the XML parser, delegated from Horde_SyncMl_ContentHandler::characters().
endElement ( string $uri, string $element ) End element handler for the XML parser, delegated from Horde_SyncMl_ContentHandler::endElement().
factory ( string $command, Horde_SyncMl_XmlOutput &$outputHandler ) : Horde_SyncMl_Command Attempts to return a concrete Horde_SyncMl_Command instance based on $command.
getCommandName ( ) : string Returns the command name this instance is reponsible for.
handleCommand ( $debug = false ) This method is supposed to implement the actual business logic of the command once the XML parsing is complete.
startElement ( string $uri, string $element, array $attrs ) Start element handler for the XML parser, delegated from Horde_SyncMl_ContentHandler::startElement().

메소드 상세

__construct() 공개 메소드

Constructor.
public __construct ( Horde_SyncMl_XmlOutput &$outputHandler )
$outputHandler Horde_SyncMl_XmlOutput A Horde_SyncMl_XmlOutput object.

characters() 공개 메소드

Character data handler for the XML parser, delegated from Horde_SyncMl_ContentHandler::characters().
public characters ( string $str )
$str string The data string.

endElement() 공개 메소드

End element handler for the XML parser, delegated from Horde_SyncMl_ContentHandler::endElement().
public endElement ( string $uri, string $element )
$uri string The namespace URI of the element.
$element string The element tag name.

factory() 공개 메소드

Attempts to return a concrete Horde_SyncMl_Command instance based on $command.
public factory ( string $command, Horde_SyncMl_XmlOutput &$outputHandler ) : Horde_SyncMl_Command
$command string The type of the concrete Horde_SyncMl_Comment subclass to return.
$outputHandler Horde_SyncMl_XmlOutput A Horde_SyncMl_XmlOutput object.
리턴 Horde_SyncMl_Command The newly created concrete Horde_SyncMl_Command instance, or false on error.

getCommandName() 공개 메소드

Returns the command name this instance is reponsible for.
public getCommandName ( ) : string
리턴 string The command name this object is handling.

handleCommand() 공개 메소드

This method is supposed to implement the actual business logic of the command once the XML parsing is complete.
public handleCommand ( $debug = false )

startElement() 공개 메소드

Start element handler for the XML parser, delegated from Horde_SyncMl_ContentHandler::startElement().
public startElement ( string $uri, string $element, array $attrs )
$uri string The namespace URI of the element.
$element string The element tag name.
$attrs array A hash with the element's attributes.

프로퍼티 상세

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

Buffer for the parsed character data.
protected string $_chars
리턴 string

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

The command ID ().
protected int $_cmdID
리턴 integer

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

Must be overwritten by a sub class.
protected string $_cmdName
리턴 string

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

A Horde_SyncMl_XmlOutput instance responsible for generating the output.
protected Horde_SyncMl_XmlOutput $_outputHandler
리턴 Horde_SyncMl_XmlOutput

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

Stack for holding the XML elements during creation of the object from the XML event flow.
protected array $_stack
리턴 array