tdebluez
synchronization1Interface.cpp
Go to the documentation of this file.
1// File autogenerated
2
3// declaration include
5
6// TQt includes
7#include <tqdom.h>
8#include <tqstring.h>
9
10// TQt D-Bus includes
11#include <tqdbuserror.h>
12#include <tqdbusmessage.h>
13#include <tqdbusobjectpath.h>
14
15
16namespace org
17{
18namespace bluez
19{
20namespace obex
21{
22
24{
25 interfaceElement.setAttribute("name", "org.bluez.obex.Synchronization1");
26
27 TQDomDocument document = interfaceElement.ownerDocument();
28 TQDomElement methodElement = document.createElement("method");
29 methodElement.setAttribute("name", "SetLocation");
30
31 TQDomElement argumentElement = document.createElement("arg");
32 argumentElement.setAttribute("name", "location");
33 argumentElement.setAttribute("type", "s");
34 argumentElement.setAttribute("direction", "in");
35 methodElement.appendChild(argumentElement);
36
38
39 methodElement = document.createElement("method");
40 methodElement.setAttribute("name", "GetPhonebook");
41
42 argumentElement = document.createElement("arg");
43 argumentElement.setAttribute("name", "phonebook");
44 argumentElement.setAttribute("type", "o");
45 argumentElement.setAttribute("direction", "out");
46 methodElement.appendChild(argumentElement);
47
48 argumentElement = document.createElement("arg");
49 argumentElement.setAttribute("name", "sourcefile");
50 argumentElement.setAttribute("type", "s");
51 argumentElement.setAttribute("direction", "in");
52 methodElement.appendChild(argumentElement);
53
54 argumentElement = document.createElement("arg");
55 argumentElement.setAttribute("name", "targetfile");
56 argumentElement.setAttribute("type", "s");
57 argumentElement.setAttribute("direction", "in");
58 methodElement.appendChild(argumentElement);
59
61
62 methodElement = document.createElement("method");
63 methodElement.setAttribute("name", "PutPhonebook");
64
65 argumentElement = document.createElement("arg");
66 argumentElement.setAttribute("name", "sourcefile");
67 argumentElement.setAttribute("type", "s");
68 argumentElement.setAttribute("direction", "in");
69 methodElement.appendChild(argumentElement);
70
72}
73
75{
78
79 TQString _location = message[0].toString();
80
82 {
83 reply = TQT_DBusMessage::methodReply(message);
84 }
85 else
86 {
87 if (!error.isValid())
88 {
89 tqWarning("Call to implementation of org::bluez::obex::Synchronization1Interface::SetLocation returned 'false' but error object is not valid!");
90
91 error = TQT_DBusError::stdFailed("org.bluez.obex.Synchronization1.SetLocation execution failed");
92 }
93
94 reply = TQT_DBusMessage::methodError(message, error);
95 }
96
97 return reply;
98}
99
101{
104
106 TQString _sourcefile = message[0].toString();
107 TQString _targetfile = message[1].toString();
108
110 {
111 reply = TQT_DBusMessage::methodReply(message);
112 reply << TQT_DBusData::fromObjectPath(_phonebook);
113 }
114 else
115 {
116 if (!error.isValid())
117 {
118 tqWarning("Call to implementation of org::bluez::obex::Synchronization1Interface::GetPhonebook returned 'false' but error object is not valid!");
119
120 error = TQT_DBusError::stdFailed("org.bluez.obex.Synchronization1.GetPhonebook execution failed");
121 }
122
123 reply = TQT_DBusMessage::methodError(message, error);
124 }
125
126 return reply;
127}
128
130{
133
134 TQString _sourcefile = message[0].toString();
135
137 {
138 reply = TQT_DBusMessage::methodReply(message);
139 }
140 else
141 {
142 if (!error.isValid())
143 {
144 tqWarning("Call to implementation of org::bluez::obex::Synchronization1Interface::PutPhonebook returned 'false' but error object is not valid!");
145
146 error = TQT_DBusError::stdFailed("org.bluez.obex.Synchronization1.PutPhonebook execution failed");
147 }
148
149 reply = TQT_DBusMessage::methodError(message, error);
150 }
151
152 return reply;
153}
154
156{
157 if (message.interface() != "org.bluez.obex.Synchronization1") return false;
158
159 if (message.member() == "SetLocation")
160 {
163
164 return true;
165 }
166
167 if (message.member() == "GetPhonebook")
168 {
171
172 return true;
173 }
174
175 if (message.member() == "PutPhonebook")
176 {
179
180 return true;
181 }
182
183 return false;
184}
185
186}; // namespace obex
187
188}; // namespace bluez
189
190}; // namespace org
191
192// End of File
193
TQT_DBusMessage callSetLocation(const TQT_DBusMessage &message)
TQT_DBusMessage callPutPhonebook(const TQT_DBusMessage &message)
virtual void handleMethodReply(const TQT_DBusMessage &reply)=0
virtual bool SetLocation(const TQString &location, TQT_DBusError &error)=0
virtual bool GetPhonebook(TQT_DBusObjectPath &phonebook, const TQString &sourcefile, const TQString &targetfile, TQT_DBusError &error)=0
virtual bool PutPhonebook(const TQString &sourcefile, TQT_DBusError &error)=0
virtual bool handleMethodCall(const TQT_DBusMessage &message)
TQT_DBusMessage callGetPhonebook(const TQT_DBusMessage &message)
static void buildIntrospectionData(TQDomElement &interfaceElement)