使用google-voice-java标记所有收件箱项目

时间:2012-11-30 23:55:10

标签: java google-voice

我想使用此Google语音API将我的所有邮件标记为已读。下面的代码不起作用,任何想法为什么?

import java.io.IOException;
import java.util.Collection;

import com.techventus.server.voice.Voice;
import com.techventus.server.voice.datatypes.records.SMSThread;

public class voiceApplication {

    public static void main(String[] args) throws IOException {

        Info info = new Info();
        String userName = info.getUsername();
        String pass = info.getPassword();

        Voice voice = new Voice(userName, pass);

        Collection<SMSThread> smsThreads = voice.getSMSThreads(voice.getUnreadSMS());
        for (SMSThread message : smsThreads)
        {
            voice.markAsRead(message.getId());
        }
    }

}

0 个答案:

没有答案