dom/mobilemessage/src/ipc/PSms.ipdl

changeset 0
6474c204b198
equal deleted inserted replaced
-1:000000000000 0:6cb403d90d5c
1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set sw=2 ts=8 et ft=cpp : */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
5 * You can obtain one at http://mozilla.org/MPL/2.0/. */
6
7 include protocol PContent;
8 include protocol PSmsRequest;
9 include protocol PMobileMessageCursor;
10 include protocol PBlob;
11 include SmsTypes;
12
13 namespace mozilla {
14 namespace dom {
15 namespace mobilemessage {
16
17 struct SendMmsMessageRequest
18 {
19 uint32_t serviceId;
20 nsString[] receivers;
21 nsString subject;
22 nsString smil;
23 MmsAttachmentData[] attachments;
24 };
25
26 struct SendSmsMessageRequest
27 {
28 uint32_t serviceId;
29 nsString number;
30 nsString message;
31 bool silent;
32 };
33
34 union SendMessageRequest
35 {
36 SendMmsMessageRequest;
37 SendSmsMessageRequest;
38 };
39
40 struct RetrieveMessageRequest
41 {
42 int32_t messageId;
43 };
44
45 struct GetMessageRequest
46 {
47 int32_t messageId;
48 };
49
50 struct DeleteMessageRequest
51 {
52 int32_t[] messageIds;
53 };
54
55 struct CreateMessageCursorRequest
56 {
57 SmsFilterData filter;
58 bool reverse;
59 };
60
61 struct MarkMessageReadRequest
62 {
63 int32_t messageId;
64 bool value;
65 bool sendReadReport;
66 };
67
68 struct GetSegmentInfoForTextRequest
69 {
70 nsString text;
71 };
72
73 struct CreateThreadCursorRequest
74 {
75 };
76
77 struct GetSmscAddressRequest
78 {
79 uint32_t serviceId;
80 };
81
82 union IPCSmsRequest
83 {
84 SendMessageRequest;
85 RetrieveMessageRequest;
86 GetMessageRequest;
87 DeleteMessageRequest;
88 MarkMessageReadRequest;
89 GetSegmentInfoForTextRequest;
90 GetSmscAddressRequest;
91 };
92
93 union IPCMobileMessageCursor
94 {
95 CreateMessageCursorRequest;
96 CreateThreadCursorRequest;
97 };
98
99 sync protocol PSms {
100 manager PContent;
101 manages PSmsRequest;
102 manages PMobileMessageCursor;
103
104 child:
105 NotifyReceivedMessage(MobileMessageData aMessageData);
106
107 NotifyRetrievingMessage(MobileMessageData aMessageData);
108
109 NotifySendingMessage(MobileMessageData aMessageData);
110
111 NotifySentMessage(MobileMessageData aMessageData);
112
113 NotifyFailedMessage(MobileMessageData aMessageData);
114
115 NotifyDeliverySuccessMessage(MobileMessageData aMessageData);
116
117 NotifyDeliveryErrorMessage(MobileMessageData aMessageData);
118
119 NotifyReceivedSilentMessage(MobileMessageData aMessageData);
120
121 NotifyReadSuccessMessage(MobileMessageData aMessageData);
122
123 NotifyReadErrorMessage(MobileMessageData aMessageData);
124
125 parent:
126 /**
127 * Sent when the child no longer needs to use sms.
128 */
129 __delete__();
130
131 /**
132 * Sent when the child makes an asynchronous request to the parent.
133 */
134 PSmsRequest(IPCSmsRequest request);
135
136 /**
137 * Sent when the child makes an asynchronous cursor to the parent.
138 */
139 PMobileMessageCursor(IPCMobileMessageCursor request);
140
141 AddSilentNumber(nsString aNumber);
142 RemoveSilentNumber(nsString aNumber);
143 };
144
145 } // namespace mobilemessage
146 } // namespace dom
147 } // namespace mozilla

mercurial