Abstract class definition for all timeserver protocols

category Zend
package Zend_TimeSync
copyright Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
license New BSD License

 Methods

Query this timeserver without using the fallback mechanism

getDate(string|\Zend_Locale $locale = null) : \Zend_Date

Parameters

$locale

string\Zend_Locale

(Optional) Locale

Returns

\Zend_Date

Return information sent/returned from the timeserver

getInfo() : array

Returns

array

Connect to the specified timeserver.

_connect() : void

Exceptions

\Zend_TimeSync_Exception When the connection failed

Disconnects from the peer, closes the socket.

_disconnect() : void

Abstract method that extracts the binary data returned from the timeserver

_extract(string|array $data) : integer

Parameters

$data

stringarray

Data returned from the timeserver

Returns

integer

Abstract method that prepares the data to send to the timeserver

_prepare() : mixed

Returns

mixed

Abstract method that reads the data returned from the timeserver

_read() : mixed

Returns

mixed

Abstract method that writes data to to the timeserver

_write(string $data) : void

Parameters

$data

string

Data to write

 Properties

 

Exceptions that might have occured

$_exceptions : array

Default

 

Holds information passed/returned from timeserver

$_info : array

Default

array()
 

Holds the current socket connection

$_socket : array

Default

 

Hostname for timeserver

$_timeserver : string

Default