twitter4j
Class TwitterException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by twitter4j.TwitterException
All Implemented Interfaces:
java.io.Serializable

public class TwitterException
extends java.lang.Exception

An exception class that will be thrown when TwitterAPI calls are failed.
In case the Twitter server returned HTTP error code, you can get the HTTP status code using getStatusCode() method.

Author:
Yusuke Yamamoto - yusuke at mac.com
See Also:
Serialized Form

Field Summary
private static long serialVersionUID
           
private  int statusCode
           
 
Constructor Summary
TwitterException(java.lang.Exception cause)
           
TwitterException(java.lang.String msg)
           
TwitterException(java.lang.String msg, java.lang.Exception cause)
           
TwitterException(java.lang.String msg, java.lang.Exception cause, int statusCode)
           
TwitterException(java.lang.String msg, int statusCode)
           
 
Method Summary
 int getStatusCode()
           
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

statusCode

private int statusCode

serialVersionUID

private static final long serialVersionUID
See Also:
Constant Field Values
Constructor Detail

TwitterException

public TwitterException(java.lang.String msg)

TwitterException

public TwitterException(java.lang.Exception cause)

TwitterException

public TwitterException(java.lang.String msg,
                        int statusCode)

TwitterException

public TwitterException(java.lang.String msg,
                        java.lang.Exception cause)

TwitterException

public TwitterException(java.lang.String msg,
                        java.lang.Exception cause,
                        int statusCode)
Method Detail

getStatusCode

public int getStatusCode()