76 * is emitted with SmfContactList once data is arrived. When the list is big, |
77 * is emitted with SmfContactList once data is arrived. When the list is big, |
77 * user can specify the page number and per page item data. If not supplied |
78 * user can specify the page number and per page item data. If not supplied |
78 * by the user default values are used. |
79 * by the user default values are used. |
79 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
80 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
80 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
81 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
81 * @return true if success, else false |
82 * @return SmfError. SmfNoError if success, else appropriate error code |
82 */ |
83 */ |
83 bool friends ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); |
84 SmfError friends ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); |
84 |
85 |
85 /** |
86 /** |
86 * Get the list of followers asynchronously. The followersListAvailable() signal |
87 * Get the list of followers asynchronously. The followersListAvailable() signal |
87 * is emitted with SmfContactList once data is arrived. Please note that some |
88 * is emitted with SmfContactList once data is arrived. Please note that some |
88 * service may not support followers/fans - FALSE is returned if not supported. |
89 * service may not support followers/fans - FALSE is returned if not supported. |
89 * When the list is big user can specify the page number and per page item data. |
90 * When the list is big user can specify the page number and per page item data. |
90 * If not supplied by the user default values are used. |
91 * If not supplied by the user default values are used. |
91 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
92 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
92 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
93 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
93 * @return true if success, else false |
94 * @return SmfError. SmfNoError if success, else appropriate error code |
94 */ |
95 */ |
95 bool followers ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); |
96 SmfError followers ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); |
96 |
97 |
97 /** |
98 /** |
98 * Searches for a contact The searchContactFinished() signal |
99 * Searches for a contact The searchContactFinished() signal |
99 * is emitted with SmfContactList once data is arrived. |
100 * is emitted with SmfContactList once data is arrived. |
100 * When the list is big user can specify the page number and per page item data. |
101 * When the list is big user can specify the page number and per page item data. |
101 * If not supplied by the user default values are used. |
102 * If not supplied by the user default values are used. |
102 * @param contact The contact to be searched. The serach criteria must be |
103 * @param contact The contact to be searched. The serach criteria must be |
103 * set as one of its fields. |
104 * set as one of its fields. |
104 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
105 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
105 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
106 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
106 */ |
107 * @return SmfError. SmfNoError if success, else appropriate error code |
107 void search ( SmfContact* contact, int pageNum = SMF_FIRST_PAGE, |
108 */ |
|
109 SmfError search ( SmfContact* contact, int pageNum = SMF_FIRST_PAGE, |
108 int perPage = SMF_ITEMS_PER_PAGE ); |
110 int perPage = SMF_ITEMS_PER_PAGE ); |
109 |
111 |
110 /** |
112 /** |
111 * Searches for a contacts (friends) who are near the user. The signal |
113 * Searches for a contacts (friends) who are near the user. The signal |
112 * searchNearFinished() is emitted with SmfContactList once data is arrived. |
114 * searchNearFinished() is emitted with SmfContactList once data is arrived. |
115 * default values are used. |
117 * default values are used. |
116 * @param location The location information |
118 * @param location The location information |
117 * @param proximity The search boundary criteria |
119 * @param proximity The search boundary criteria |
118 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
120 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
119 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
121 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
120 */ |
122 * @return SmfError. SmfNoError if success, else appropriate error code |
121 bool searchNear ( SmfLocation* location, |
123 */ |
|
124 SmfError searchNear ( SmfLocation* location, |
122 SmfLocationSearchBoundary proximity, |
125 SmfLocationSearchBoundary proximity, |
123 int pageNum = SMF_FIRST_PAGE, |
126 int pageNum = SMF_FIRST_PAGE, |
124 int perPage = SMF_ITEMS_PER_PAGE); |
127 int perPage = SMF_ITEMS_PER_PAGE); |
125 |
128 |
126 /** |
129 /** |
129 * doesn't support any mode of grouping (very rare). When the list is big, |
132 * doesn't support any mode of grouping (very rare). When the list is big, |
130 * user can specify the page number and per page item data. If not supplied |
133 * user can specify the page number and per page item data. If not supplied |
131 * by the user default values are used. |
134 * by the user default values are used. |
132 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
135 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
133 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
136 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
134 */ |
137 * @return SmfError. SmfNoError if success, else appropriate error code |
135 bool groups ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); |
138 */ |
|
139 SmfError groups ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); |
136 |
140 |
137 /** |
141 /** |
138 * Searches for Smf Contacts in an Smf group. The signal searchInGroupFinished() |
142 * Searches for Smf Contacts in an Smf group. The signal searchInGroupFinished() |
139 * is emitted with SmfContactList once data is arrived. When the list is big user |
143 * is emitted with SmfContactList once data is arrived. When the list is big user |
140 * can specify the page number and per page item data. If not supplied by the |
144 * can specify the page number and per page item data. If not supplied by the |
141 * user default values are used. |
145 * user default values are used. |
142 * @param group The group to be searched in |
146 * @param group The group to be searched in |
143 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
147 * @contact The contact to be searched, default (NULL) is the self contact. |
144 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
148 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
145 * @return true if success, else false |
149 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
146 */ |
150 * @return SmfError. SmfNoError if success, else appropriate error code |
147 bool searchInGroup ( SmfGroup group, |
151 */ |
|
152 SmfError searchInGroup ( SmfGroup group, |
|
153 SmfContact* contact = NULL, |
148 int pageNum = SMF_FIRST_PAGE, |
154 int pageNum = SMF_FIRST_PAGE, |
149 int perPage = SMF_ITEMS_PER_PAGE ); |
155 int perPage = SMF_ITEMS_PER_PAGE ); |
150 |
156 |
151 /** |
157 /** |
152 * Request for a custom operation. The signal customDataAvailable() is emitted |
158 * Request for a custom operation. The signal customDataAvailable() is emitted |
153 * when the result is available. |
159 * when the result is available. |
154 * @param operationId OperationId |
160 * @param operationId OperationId |
155 * @param customData Custom data to be sent |
161 * @param customData Custom data to be sent |
|
162 * @return SmfError. SmfNoError if success, else appropriate error code |
156 * Note:-Interpretation of operationId and customData is upto the concerned |
163 * Note:-Interpretation of operationId and customData is upto the concerned |
157 * plugin and client application. service provider should provide some |
164 * plugin and client application. service provider should provide some |
158 * serializing-deserializing utilities for these custom data |
165 * serializing-deserializing utilities for these custom data |
159 */ |
166 */ |
160 void customRequest ( const int& operationId, QByteArray* customData ); |
167 SmfError customRequest ( const int& operationId, QByteArray* customData ); |
|
168 |
|
169 /** |
|
170 * Cancels a request generated due to the call to any API which results |
|
171 * into http request. Might return error if no request is currently pending. |
|
172 * Please note that there can be only one request pending at any point of time |
|
173 * @return Appropriate SmfError value |
|
174 */ |
|
175 SmfError cancelRequest (); |
161 |
176 |
162 signals: |
177 signals: |
163 |
178 |
164 /** |
179 /** |
165 * This signal is emitted when a request to get friends is completed. |
180 * This signal is emitted when a request to get friends is completed. |