Home | History | Annotate | Download | only in mail
      1 /*
      2  * Copyright (C) 2009 The Android Open Source Project
      3  *
      4  * Licensed under the Apache License, Version 2.0 (the "License");
      5  * you may not use this file except in compliance with the License.
      6  * You may obtain a copy of the License at
      7  *
      8  *      http://www.apache.org/licenses/LICENSE-2.0
      9  *
     10  * Unless required by applicable law or agreed to in writing, software
     11  * distributed under the License is distributed on an "AS IS" BASIS,
     12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     13  * See the License for the specific language governing permissions and
     14  * limitations under the License.
     15  */
     16 
     17 package com.android.emailcommon.mail;
     18 
     19 import android.content.Context;
     20 
     21 import com.android.emailcommon.service.SearchParams;
     22 
     23 
     24 public class MockFolder extends Folder {
     25 
     26     @Override
     27     public void appendMessage(Context context, Message message, boolean noTimeout) {
     28     }
     29 
     30     @Override
     31     public void close(boolean expunge) {
     32     }
     33 
     34     @Override
     35     public void copyMessages(Message[] msgs, Folder folder,
     36             MessageUpdateCallbacks callbacks) {
     37     }
     38 
     39     @Override
     40     public boolean canCreate(FolderType type) {
     41         return false;
     42     }
     43 
     44     @Override
     45     public boolean create(FolderType type) {
     46         return false;
     47     }
     48 
     49     @Override
     50     public void delete(boolean recurse) {
     51     }
     52 
     53     @Override
     54     public boolean exists() {
     55         return false;
     56     }
     57 
     58     @Override
     59     public Message[] expunge() {
     60         return null;
     61     }
     62 
     63     @Override
     64     public void fetch(Message[] messages, FetchProfile fp, MessageRetrievalListener listener) {
     65     }
     66 
     67     @Override
     68     public Message getMessage(String uid) {
     69         return null;
     70     }
     71 
     72     @Override
     73     public int getMessageCount() {
     74         return 0;
     75     }
     76 
     77     @Override
     78     public Message[] getMessages(int start, int end, MessageRetrievalListener listener) {
     79         return null;
     80     }
     81 
     82     @Override
     83     public Message[] getMessages(String[] uids, MessageRetrievalListener listener) {
     84         return null;
     85     }
     86 
     87     @Override
     88     public OpenMode getMode() {
     89         return null;
     90     }
     91 
     92     @Override
     93     public String getName() {
     94         return null;
     95     }
     96 
     97     @Override
     98     public Flag[] getPermanentFlags() {
     99         return null;
    100     }
    101 
    102     @Override
    103     public int getUnreadMessageCount() {
    104         return 0;
    105     }
    106 
    107     @Override
    108     public boolean isOpen() {
    109         return false;
    110     }
    111 
    112     @Override
    113     public void open(OpenMode mode) {
    114     }
    115 
    116     @Override
    117     public void setFlags(Message[] messages, Flag[] flags, boolean value) {
    118     }
    119 
    120     @Override
    121     public Message createMessage(String uid) {
    122         return null;
    123     }
    124 
    125     @Override
    126     public Message[] getMessages(SearchParams params, MessageRetrievalListener listener)
    127             throws MessagingException {
    128         return null;
    129     }
    130 
    131     /* (non-Javadoc)
    132      * @see com.android.emailcommon.mail.Folder#getMessages(long, long,
    133      * com.android.emailcommon.mail.Folder.MessageRetrievalListener)
    134      */
    135     @Override
    136     public Message[] getMessages(long startDate, long endDate, MessageRetrievalListener listener)
    137             throws MessagingException {
    138         return null;
    139     }
    140 
    141 }
    142