Example usage for twitter4j TwitterException getMessage

List of usage examples for twitter4j TwitterException getMessage

Introduction

In this page you can find the example usage for twitter4j TwitterException getMessage.

Prototype

@Override
    public String getMessage() 

Source Link

Usage

From source file:com.marpies.ane.twitter.functions.GetDirectMessagesFunction.java

License:Apache License

@Override
public void onException(TwitterException te, TwitterMethod method) {
    if (method == TwitterMethod.DIRECT_MESSAGES) {
        AIR.log("DIRECT MESSAGES QUERY ERROR " + te.getMessage());
        AIR.dispatchEvent(AIRTwitterEvent.DIRECT_MESSAGES_QUERY_ERROR,
                StringUtils.getEventErrorJSON(mCallbackID, te.getMessage()));
    }/*from  w  w  w .  jav a2s.  c  o m*/
}

From source file:com.marpies.ane.twitter.functions.GetFollowersFunction.java

License:Apache License

@Override
public void onException(TwitterException te, TwitterMethod method) {
    if (method == TwitterMethod.FOLLOWERS_LIST) {
        AIR.dispatchEvent(AIRTwitterEvent.USERS_QUERY_ERROR,
                StringUtils.getEventErrorJSON(mCallbackID, te.getMessage()));
    }//from  w  w w .j a  va  2  s . com
}

From source file:com.marpies.ane.twitter.functions.GetFriendsFunction.java

License:Apache License

@Override
public void onException(TwitterException te, TwitterMethod method) {
    if (method == TwitterMethod.FRIENDS_LIST) {
        AIR.dispatchEvent(AIRTwitterEvent.USERS_QUERY_ERROR,
                StringUtils.getEventErrorJSON(mCallbackID, te.getMessage()));
    }//from   w  w w . jav a  2 s  .c o  m
}

From source file:com.marpies.ane.twitter.functions.GetHomeTimelineFunction.java

License:Apache License

@Override
public void onException(TwitterException te, TwitterMethod method) {
    if (method == TwitterMethod.HOME_TIMELINE) {
        AIR.log("HOME TIMELINE ERROR " + te.getMessage());
        AIR.dispatchEvent(AIRTwitterEvent.TIMELINE_QUERY_ERROR,
                StringUtils.getEventErrorJSON(mCallbackID, te.getMessage()));
    }/* w w w.ja  va 2 s .  c  om*/
}

From source file:com.marpies.ane.twitter.functions.GetLikesFunction.java

License:Apache License

@Override
public void onException(TwitterException te, TwitterMethod method) {
    if (method == TwitterMethod.FAVORITES) {
        AIR.log("Error retreiving liked statuses " + te.getMessage());
        AIR.dispatchEvent(AIRTwitterEvent.TIMELINE_QUERY_ERROR,
                StringUtils.getEventErrorJSON(mCallbackID, te.getMessage()));
    }//from www  . j  av  a 2  s .  c o  m
}

From source file:com.marpies.ane.twitter.functions.GetLoggedInUserFunction.java

License:Apache License

@Override
public void onException(TwitterException te, TwitterMethod method) {
    if (method == TwitterMethod.SHOW_USER) {
        AIR.log("Error retrieving user info " + te.getMessage());
        AIR.dispatchEvent(AIRTwitterEvent.USER_QUERY_ERROR,
                StringUtils.getEventErrorJSON(mCallbackID, te.getMessage()));
    }//from   w  w  w  .java  2s.co  m
}

From source file:com.marpies.ane.twitter.functions.GetSentDirectMessagesFunction.java

License:Apache License

@Override
public void onException(TwitterException te, TwitterMethod method) {
    if (method == TwitterMethod.SENT_DIRECT_MESSAGES) {
        AIR.log("SENT DIRECT MESSAGES QUERY ERROR " + te.getMessage());
        AIR.dispatchEvent(AIRTwitterEvent.DIRECT_MESSAGES_QUERY_ERROR,
                StringUtils.getEventErrorJSON(mCallbackID, te.getMessage()));
    }/* ww  w  .  ja  v a 2 s . c  o m*/
}

From source file:com.marpies.ane.twitter.functions.GetUserTimelineFunction.java

License:Apache License

@Override
public void onException(TwitterException te, TwitterMethod method) {
    if (method == TwitterMethod.USER_TIMELINE) {
        AIR.log("USER TIMELINE ERROR " + te.getMessage());
        AIR.dispatchEvent(AIRTwitterEvent.TIMELINE_QUERY_ERROR,
                StringUtils.getEventErrorJSON(mCallbackID, te.getMessage()));
    }//from w  ww.j  av a  2s.c o  m
}

From source file:com.marpies.ane.twitter.functions.InitFunction.java

License:Apache License

@Override
public void onException(TwitterException te, TwitterMethod method) {
    if (method == TwitterMethod.VERIFY_CREDENTIALS) {
        AIR.log("Verify credentials error: " + te.getMessage());
        /* Cached credentials are invalid, remove them from preferences */
        TwitterAPI.removeAccessTokenPreferences();
        AIR.dispatchEvent(AIRTwitterEvent.CREDENTIALS_CHECK, "{ \"result\": \"invalid\" }");
    }/*  w ww . j a  v  a 2 s. co  m*/
}

From source file:com.marpies.ane.twitter.functions.LikeStatusFunction.java

License:Apache License

@Override
public void onException(TwitterException te, TwitterMethod method) {
    if (method == TwitterMethod.CREATE_FAVORITE) {
        AIR.log("Error liking status: " + te.getMessage());
        AIR.dispatchEvent(AIRTwitterEvent.STATUS_QUERY_ERROR,
                StringUtils.getEventErrorJSON(mCallbackID, te.getMessage()));
    }//from w  ww. j  a v  a2s.c  om
}