Zend Framework  1.12
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
Zend_TimeSync_Sntp Class Reference

Public Member Functions

 __construct ($timeserver, $port)
 Class constructor, sets the timeserver and port number.
 
- Public Member Functions inherited from Zend_TimeSync_Protocol
 getInfo ()
 Return information sent/returned from the timeserver.
 
 getDate ($locale=null)
 Query this timeserver without using the fallback mechanism.
 

Protected Member Functions

 _prepare ()
 Prepares the data that will be send to the timeserver.
 
 _read ()
 Reads the data returned from the timeserver.
 
 _write ($data)
 Writes data to to the timeserver.
 
 _extract ($result)
 Extracts the data returned from the timeserver.
 
- Protected Member Functions inherited from Zend_TimeSync_Protocol
 _prepare ()
 Abstract method that prepares the data to send to the timeserver.
 
 _read ()
 Abstract method that reads the data returned from the timeserver.
 
 _write ($data)
 Abstract method that writes data to to the timeserver.
 
 _extract ($data)
 Abstract method that extracts the binary data returned from the timeserver.
 
 _connect ()
 Connect to the specified timeserver.
 
 _disconnect ()
 Disconnects from the peer, closes the socket.
 

Protected Attributes

 $_port = 37
 
- Protected Attributes inherited from Zend_TimeSync_Protocol
 $_socket
 
 $_exceptions
 
 $_timeserver
 
 $_info = array()
 

Constructor & Destructor Documentation

__construct (   $timeserver,
  $port 
)

Class constructor, sets the timeserver and port number.

Parameters
string$timeserverTimeserver to connect to
integer$portPort of the timeserver when it differs from the default port

Member Function Documentation

_extract (   $result)
protected

Extracts the data returned from the timeserver.

Parameters
string$resultData to extract
Returns
integer
_prepare ( )
protected

Prepares the data that will be send to the timeserver.

Returns
array
_read ( )
protected

Reads the data returned from the timeserver.

Returns
string
_write (   $data)
protected

Writes data to to the timeserver.

Parameters
string$dataData to write to the timeserver
Returns
void

Member Data Documentation

$_port = 37
protected