Overview

Packages

  • ActiveSync
  • None

Classes

  • Horde_ActiveSync
  • Horde_ActiveSync_Connector_Exporter
  • Horde_ActiveSync_Connector_Importer
  • Horde_ActiveSync_Driver_Base
  • Horde_ActiveSync_Exception
  • Horde_ActiveSync_Exception_InvalidRequest
  • Horde_ActiveSync_Exception_StateGone
  • Horde_ActiveSync_Message_Base
  • Horde_ActiveSync_Request_Base
  • Horde_ActiveSync_Request_FolderCreate
  • Horde_ActiveSync_Request_FolderSync
  • Horde_ActiveSync_Request_GetHierarchy
  • Horde_ActiveSync_Request_GetItemEstimate
  • Horde_ActiveSync_Request_MeetingResponse
  • Horde_ActiveSync_Request_MoveItems
  • Horde_ActiveSync_Request_Notify
  • Horde_ActiveSync_Request_Ping
  • Horde_ActiveSync_Request_Provision
  • Horde_ActiveSync_Request_Search
  • Horde_ActiveSync_Request_SendMail
  • Horde_ActiveSync_Request_SmartForward
  • Horde_ActiveSync_Request_SmartReply
  • Horde_ActiveSync_Request_Sync
  • Horde_ActiveSync_State_File
  • Horde_ActiveSync_Sync
  • Horde_ActiveSync_Wbxml
  • Horde_ActiveSync_Wbxml_Decoder
  • Horde_ActiveSync_Wbxml_Encoder
  • Overview
  • Package
  • Class
  • Tree
 1: <?php
 2: /**
 3:  * Handle Notify requests.
 4:  * 
 5:  * Logic adapted from Z-Push, original copyright notices below.
 6:  *
 7:  * Copyright 2009-2012 Horde LLC (http://www.horde.org/)
 8:  *
 9:  * @author Michael J. Rubinsky <mrubinsk@horde.org>
10:  * @package ActiveSync
11:  */
12: /**
13:  * Zarafa Deutschland GmbH, www.zarafaserver.de
14:  * This file is distributed under GPL-2.0.
15:  * Consult COPYING file for details
16:  */
17: // AIRNOTIFY
18: define("SYNC_AIRNOTIFY_NOTIFY","AirNotify:Notify");
19: define("SYNC_AIRNOTIFY_NOTIFICATION","AirNotify:Notification");
20: define("SYNC_AIRNOTIFY_VERSION","AirNotify:Version");
21: define("SYNC_AIRNOTIFY_LIFETIME","AirNotify:Lifetime");
22: define("SYNC_AIRNOTIFY_DEVICEINFO","AirNotify:DeviceInfo");
23: define("SYNC_AIRNOTIFY_ENABLE","AirNotify:Enable");
24: define("SYNC_AIRNOTIFY_FOLDER","AirNotify:Folder");
25: define("SYNC_AIRNOTIFY_SERVERENTRYID","AirNotify:ServerEntryId");
26: define("SYNC_AIRNOTIFY_DEVICEADDRESS","AirNotify:DeviceAddress");
27: define("SYNC_AIRNOTIFY_VALIDCARRIERPROFILES","AirNotify:ValidCarrierProfiles");
28: define("SYNC_AIRNOTIFY_CARRIERPROFILE","AirNotify:CarrierProfile");
29: define("SYNC_AIRNOTIFY_STATUS","AirNotify:Status");
30: define("SYNC_AIRNOTIFY_REPLIES","AirNotify:Replies");
31: define("SYNC_AIRNOTIFY_VERSION='1.1'","AirNotify:Version='1.1'");
32: define("SYNC_AIRNOTIFY_DEVICES","AirNotify:Devices");
33: define("SYNC_AIRNOTIFY_DEVICE","AirNotify:Device");
34: define("SYNC_AIRNOTIFY_ID","AirNotify:Id");
35: define("SYNC_AIRNOTIFY_EXPIRY","AirNotify:Expiry");
36: define("SYNC_AIRNOTIFY_NOTIFYGUID","AirNotify:NotifyGUID");
37: 
38: class Horde_ActiveSync_Request_Notify extends Horde_ActiveSync_Request_Base
39: {
40:     /**
41:      * Handle request
42:      *
43:      * @return boolean
44:      */
45:     public function handle()
46:     {
47:          if (!$this->_decoder->getElementStartTag(SYNC_AIRNOTIFY_NOTIFY)) {
48:             return false;
49:         }
50: 
51:         if (!$this->_decoder->getElementStartTag(SYNC_AIRNOTIFY_DEVICEINFO)) {
52:             return false;
53:         }
54: 
55:         if (!$this->_decoder->getElementEndTag()) {
56:             return false;
57:         }
58: 
59:         if (!$this->_decoder->getElementEndTag()) {
60:             return false;
61:         }
62:         $this->_encoder->StartWBXML();
63:         $this->_encoder->startTag(SYNC_AIRNOTIFY_NOTIFY);
64:         $this->_encoder->startTag(SYNC_AIRNOTIFY_STATUS);
65:         $this->_encoder->content(1);
66:         $this->_encoder->endTag();
67:         $this->_encoder->startTag(SYNC_AIRNOTIFY_VALIDCARRIERPROFILES);
68:         $this->_encoder->endTag();
69:         $this->_encoder->endTag();
70: 
71:         return true;
72:     }
73: }
API documentation generated by ApiGen