Horde_ActiveSync_Connector_Exporter_Sync
extends Horde_ActiveSync_Connector_Exporter_Base
in package
Horde_ActiveSync_Connector_Exporter_Sync:: Responsible for outputing blocks of WBXML responses in SYNC responses. E.g., sending all WBXML necessary to transmit a new/changed message object to the client.
Tags
Table of Contents
- $_as : Horde_ActiveSync
- The ActiveSync server object.
- $_changes : array<string|int, mixed>
- Local cache of changes to send.
- $_currentCollection : array<string|int, mixed>
- Currently syncing collection.
- $_encoder : Horde_ActiveSync_Wbxml_Encoder
- The wbxml encoder
- $_procid : int
- Process id for logging.
- $_seenObjects : array<string|int, mixed>
- Local cache of object ids we have already dealt with.
- $_step : int
- Counter of changes sent.
- __construct() : Horde_ActiveSync_Connector_Exporter
- Const'r
- fetchIds() : mixed
- Send the SYNC_FETCH response for any items requested by the client.
- messageChange() : mixed
- Send a message change over the wbxml stream
- messageDeletion() : mixed
- Stream a message deletion to the client.
- messageMove() : mixed
- Move a message to a different folder.
- missingRemove() : mixed
- Send the SYNC_REMOVE response for any items deleted from the client but were unable to be removed on the server. Usually due to not being found.
- modifyFailures() : mixed
- Send the SYNC_MODIFY response for any items modified from the client that require this response. Basically any items that have AirSyncBaseAttachments changes.
- sendNextChange() : bool|Horde_Exception
- Sends the next change in the set to the client.
- setChanges() : mixed
- Set the changes to send to the client.
- syncAddResponse() : mixed
- Send the SYNC_ADD response for any items added from the client.
- syncFolderId() : mixed
- Send the SYNC_FOLDERID value.
- syncFolderType() : mixed
- Send the SYNC_FOLDERTYPE node if needed.
- syncKey() : mixed
- Send the SYNC_SYNCKEY response appropriate for this response.
- syncModifiedResponse() : mixed
- Send the SYNC_MODIFY response for each modified item that requires this response.
- syncStatus() : mixed
- Send the SYNC_STATUS value.
- _getNextChange() : mixed
- _sendEas16MessageResponse() : mixed
- Sends the appropriate message object reply within a SYNC_ADD or SYNC_MODIFY block in a SYNC_REPLIES block for EAS >= 16 clients.
- _sendNextChange() : mixed
- Sends the next message change to the client.
Properties
$_as
The ActiveSync server object.
protected
Horde_ActiveSync
$_as
$_changes
Local cache of changes to send.
protected
array<string|int, mixed>
$_changes
= array()
$_currentCollection
Currently syncing collection.
protected
array<string|int, mixed>
$_currentCollection
$_encoder
The wbxml encoder
protected
Horde_ActiveSync_Wbxml_Encoder
$_encoder
$_procid
Process id for logging.
protected
int
$_procid
$_seenObjects
Local cache of object ids we have already dealt with.
protected
array<string|int, mixed>
$_seenObjects
= array()
$_step
Counter of changes sent.
protected
int
$_step
= 0
Methods
__construct()
Const'r
public
__construct(Horde_ActiveSync $as[, Horde_ActiveSync_Wbxml_Encoder $encoder = null ]) : Horde_ActiveSync_Connector_Exporter
Parameters
- $as : Horde_ActiveSync
-
The ActiveSync server.
- $encoder : Horde_ActiveSync_Wbxml_Encoder = null
-
The encoder
Return values
Horde_ActiveSync_Connector_Exporter —fetchIds()
Send the SYNC_FETCH response for any items requested by the client.
public
fetchIds(mixed $driver, array<string|int, mixed> $collection) : mixed
Parameters
- $driver : mixed
- $collection : array<string|int, mixed>
-
The collection array.
Return values
mixed —messageChange()
Send a message change over the wbxml stream
public
messageChange(string $id, Horde_ActiveSync_Message_Base $message) : mixed
Parameters
- $id : string
-
The uid of the message
- $message : Horde_ActiveSync_Message_Base
-
The message object
Return values
mixed —messageDeletion()
Stream a message deletion to the client.
public
messageDeletion(string $id[, bool $soft = false ]) : mixed
Parameters
- $id : string
-
The uid of the message we are deleting.
- $soft : bool = false
-
If true, send a SOFTDELETE, otherwise a REMOVE.
Return values
mixed —messageMove()
Move a message to a different folder.
public
messageMove(Horde_ActiveSync_Message_Base $message) : mixed
Parameters
- $message : Horde_ActiveSync_Message_Base
-
The message
Return values
mixed —missingRemove()
Send the SYNC_REMOVE response for any items deleted from the client but were unable to be removed on the server. Usually due to not being found.
public
missingRemove(array<string|int, mixed> $collection) : mixed
Parameters
- $collection : array<string|int, mixed>
-
The collection array.
Return values
mixed —modifyFailures()
Send the SYNC_MODIFY response for any items modified from the client that require this response. Basically any items that have AirSyncBaseAttachments changes.
public
modifyFailures(array<string|int, mixed> $collection) : mixed
Parameters
- $collection : array<string|int, mixed>
-
The collection array.
Return values
mixed —sendNextChange()
Sends the next change in the set to the client.
public
sendNextChange() : bool|Horde_Exception
Return values
bool|Horde_Exception —True if more changes can be sent false if all changes were sent, Horde_Exception if there was an error sending an item.
setChanges()
Set the changes to send to the client.
public
setChanges(array<string|int, mixed> $changes[, array<string|int, mixed> $collection = null ]) : mixed
Parameters
- $changes : array<string|int, mixed>
-
The changes array returned from the collection handler.
- $collection : array<string|int, mixed> = null
-
The collection we are currently syncing.
Return values
mixed —syncAddResponse()
Send the SYNC_ADD response for any items added from the client.
public
syncAddResponse(array<string|int, mixed> $collection) : mixed
Parameters
- $collection : array<string|int, mixed>
-
The collection array.
Return values
mixed —syncFolderId()
Send the SYNC_FOLDERID value.
public
syncFolderId(array<string|int, mixed> $collection) : mixed
Parameters
- $collection : array<string|int, mixed>
-
The collection array.
Return values
mixed —syncFolderType()
Send the SYNC_FOLDERTYPE node if needed.
public
syncFolderType(array<string|int, mixed> $collection) : mixed
Parameters
- $collection : array<string|int, mixed>
-
The collection array.
Return values
mixed —syncKey()
Send the SYNC_SYNCKEY response appropriate for this response.
public
syncKey(array<string|int, mixed> $collection) : mixed
Parameters
- $collection : array<string|int, mixed>
-
The collection array.
Return values
mixed —syncModifiedResponse()
Send the SYNC_MODIFY response for each modified item that requires this response.
public
syncModifiedResponse(array<string|int, mixed> $collection) : mixed
@see self::syncAddResponse()
Parameters
- $collection : array<string|int, mixed>
-
The collection array.
Return values
mixed —syncStatus()
Send the SYNC_STATUS value.
public
syncStatus(mixed $statusCode) : mixed
Parameters
- $statusCode : mixed
Return values
mixed —_getNextChange()
protected
_getNextChange() : mixed
Return values
mixed —_sendEas16MessageResponse()
Sends the appropriate message object reply within a SYNC_ADD or SYNC_MODIFY block in a SYNC_REPLIES block for EAS >= 16 clients.
protected
_sendEas16MessageResponse(string $serverid, array<string|int, mixed> $collection) : mixed
Parameters
- $serverid : string
-
The serverid of the message being sent.
- $collection : array<string|int, mixed>
-
The collection array.
Return values
mixed —_sendNextChange()
Sends the next message change to the client.
protected
_sendNextChange() : mixed