Class ErrorManagerService

java.lang.Object
com.github.badpop.jcoinbase.service.ErrorManagerService

public class ErrorManagerService
extends java.lang.Object
An utility class to centralize error management when we need to log error and throw exceptions
  • Constructor Summary

    Constructors
    Constructor Description
    ErrorManagerService()  
  • Method Summary

    Modifier and Type Method Description
    void manageOnError​(JCoinbaseException jcex, java.lang.String message, java.lang.Object... logParams)
    Log a parameterized message and throws the given exception
    void manageOnError​(JCoinbaseException jcex, java.lang.String message, java.lang.Throwable throwable, java.lang.Object... logParams)
    Log a parameterized message with a throwable and throws the given exception

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • ErrorManagerService

      public ErrorManagerService()
  • Method Details

    • manageOnError

      public void manageOnError​(JCoinbaseException jcex, java.lang.String message, java.lang.Object... logParams)
      Log a parameterized message and throws the given exception
      Parameters:
      jcex - a JCoinbase exception that must be thrown
      message - the message we want to log
      logParams - the message parameters to log
    • manageOnError

      public void manageOnError​(JCoinbaseException jcex, java.lang.String message, java.lang.Throwable throwable, java.lang.Object... logParams)
      Log a parameterized message with a throwable and throws the given exception
      Parameters:
      jcex - a JCoinbase exception that must be thrown
      message - the message we want to log
      throwable - a throwable that we want to log
      logParams - the message parameters to log