2009-06-16 19:03:45 +00:00
|
|
|
/*
|
2010-08-24 04:56:45 +00:00
|
|
|
* Copyright (C) 2008-2010 Marc Blank
|
2009-06-16 19:03:45 +00:00
|
|
|
* Licensed to The Android Open Source Project.
|
|
|
|
*
|
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
* you may not use this file except in compliance with the License.
|
|
|
|
* You may obtain a copy of the License at
|
|
|
|
*
|
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
*
|
|
|
|
* Unless required by applicable law or agreed to in writing, software
|
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
* See the License for the specific language governing permissions and
|
|
|
|
* limitations under the License.
|
|
|
|
*/
|
|
|
|
|
2011-02-09 01:50:30 +00:00
|
|
|
package com.android.emailcommon.service;
|
|
|
|
|
2011-06-14 01:48:05 +00:00
|
|
|
import com.android.emailcommon.provider.HostAuth;
|
2011-02-09 01:50:30 +00:00
|
|
|
import com.android.emailcommon.service.IEmailServiceCallback;
|
2011-06-02 19:06:22 +00:00
|
|
|
import com.android.emailcommon.service.SearchParams;
|
2009-12-18 17:18:55 +00:00
|
|
|
import android.os.Bundle;
|
2009-06-16 19:03:45 +00:00
|
|
|
|
2009-07-07 16:39:11 +00:00
|
|
|
interface IEmailService {
|
2011-06-14 01:48:05 +00:00
|
|
|
Bundle validate(in HostAuth hostauth);
|
2009-06-16 19:03:45 +00:00
|
|
|
|
2011-02-09 01:50:30 +00:00
|
|
|
oneway void startSync(long mailboxId, boolean userRequest);
|
|
|
|
oneway void stopSync(long mailboxId);
|
2009-06-16 19:03:45 +00:00
|
|
|
|
2011-02-09 01:50:30 +00:00
|
|
|
oneway void loadMore(long messageId);
|
2011-02-14 22:39:27 +00:00
|
|
|
oneway void loadAttachment(long attachmentId, boolean background);
|
2009-06-16 19:03:45 +00:00
|
|
|
|
2011-02-09 01:50:30 +00:00
|
|
|
oneway void updateFolderList(long accountId);
|
2009-06-16 19:03:45 +00:00
|
|
|
|
|
|
|
boolean createFolder(long accountId, String name);
|
|
|
|
boolean deleteFolder(long accountId, String name);
|
|
|
|
boolean renameFolder(long accountId, String oldName, String newName);
|
2009-07-21 07:02:39 +00:00
|
|
|
|
2011-02-09 01:50:30 +00:00
|
|
|
// Must not be oneway; unless an exception is thrown, the caller is guaranteed that the callback
|
|
|
|
// has been registered
|
2009-07-29 01:28:24 +00:00
|
|
|
void setCallback(IEmailServiceCallback cb);
|
|
|
|
|
2011-02-09 01:50:30 +00:00
|
|
|
oneway void setLogging(int on);
|
2009-09-27 02:02:49 +00:00
|
|
|
|
2011-02-09 01:50:30 +00:00
|
|
|
oneway void hostChanged(long accountId);
|
2009-12-18 17:18:55 +00:00
|
|
|
|
|
|
|
Bundle autoDiscover(String userName, String password);
|
2010-01-25 20:38:32 +00:00
|
|
|
|
2011-02-09 01:50:30 +00:00
|
|
|
oneway void sendMeetingResponse(long messageId, int response);
|
2010-08-24 04:56:45 +00:00
|
|
|
|
2011-02-09 01:50:30 +00:00
|
|
|
// Must not be oneway; unless an exception is thrown, the caller is guaranteed that the action
|
|
|
|
// has been completed
|
2010-11-16 19:01:20 +00:00
|
|
|
void deleteAccountPIMData(long accountId);
|
2011-02-09 01:50:30 +00:00
|
|
|
|
|
|
|
int getApiLevel();
|
2011-03-31 20:29:23 +00:00
|
|
|
|
|
|
|
// API level 2
|
2011-06-02 19:06:22 +00:00
|
|
|
int searchMessages(long accountId, in SearchParams params, long destMailboxId);
|
2012-06-28 17:40:46 +00:00
|
|
|
|
|
|
|
void sendMail(long accountId);
|
2011-06-14 01:48:05 +00:00
|
|
|
}
|