Class SalesForceException

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.avoka.component.salesforce.SalesForceException
All Implemented Interfaces:
Serializable

public class SalesForceException extends RuntimeException
Provides a SalesForce service exception class.
Since:
3.6.5
See Also:
  • Constructor Details

    • SalesForceException

      public SalesForceException(Throwable cause, String operation, SalesForceConnection connection)
      Create a SalesForce service exception with the given cause, operation and connection.
      Parameters:
      cause - the service response
      operation - the operation which failed
      connection - the SalesForceConnection
      Since:
      4.2.0
    • SalesForceException

      public SalesForceException(String response, String operation, SalesForceConnection connection)
      Create a SalesForce service exception with the given response, operation and connection.
      Parameters:
      response - the service response
      operation - the operation which failed
      connection - the SalesForceConnection
      Since:
      4.2.0
    • SalesForceException

      public SalesForceException(String response, String operation)
      Create a SalesForce service exception with the given response and operation.
      Parameters:
      response - the service response
      operation - the operation which failed
    • SalesForceException

      public SalesForceException(String message, Throwable cause)
      Create a SalesForce service exception with the given message and cause.
      Parameters:
      message - the error message
      cause - the cause of the error
    • SalesForceException

      public SalesForceException(String message)
      Create a SalesForce service exception with the given message.
      Parameters:
      message - the error message
    • SalesForceException

      public SalesForceException(Throwable cause)
      Create a SalesForce service exception with the given cause.
      Parameters:
      cause - the cause of the error
  • Method Details

    • getResponse

      public String getResponse()
      Returns:
      the error response
    • getContext

      public String getContext()
      Deprecated.
      use getOperation instead
      Returns:
      the operation which failed
    • getOperation

      public String getOperation()
      Returns:
      the operation which failed
    • toString

      public String toString()
      Return the string representation of the object.
      Overrides:
      toString in class Throwable
      Returns:
      the string representation of the object