com.restfb
Class FacebookGraphException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by com.restfb.FacebookException
              extended by com.restfb.FacebookGraphException
All Implemented Interfaces:
Serializable

public class FacebookGraphException
extends FacebookException

Indicates that the Facebook Graph API endpoint returned JSON which indicates an error condition.

Example: { "error": { "type": "QueryParseException", "message": "Some of the aliases you requested do not exist: xxxxx" } }

Since:
1.5
Author:
Mark Allen
See Also:
Serialized Form

Constructor Summary
FacebookGraphException(String errorType, String errorMessage)
          Creates an exception with the given error type and message.
 
Method Summary
 String getErrorMessage()
          Gets the Facebook Graph API error message.
 String getErrorType()
          Gets the Facebook Graph API error type.
 
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
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FacebookGraphException

public FacebookGraphException(String errorType,
                              String errorMessage)
Creates an exception with the given error type and message.

Parameters:
errorType - Value of the Facebook response attribute error.type.
errorMessage - Value of the Facebook response attribute error.message.
Method Detail

getErrorType

public String getErrorType()
Gets the Facebook Graph API error type.

Returns:
The Facebook Graph API error type.

getErrorMessage

public String getErrorMessage()
Gets the Facebook Graph API error message.

Returns:
The Facebook Graph API error message.


RestFB version 1.5.3. Copyright © 2010 Mark Allen. All Rights Reserved.