Class ServiceException

java.lang.Object
java.lang.Throwable
java.lang.Exception
com.priint.pubserver.exception.PubServerException
com.priint.pubserver.entitydata.service.ServiceException
All Implemented Interfaces:
Serializable

public class ServiceException extends com.priint.pubserver.exception.PubServerException
Represents an exception that occurs when a service method fails and there is no expected remedy.

This exception is used to signal non-recoverable errors encountered in the service layer. It extends PubServerException and supports passing a message, cause, error code, and caller context.

See Also:
  • Constructor Details

    • ServiceException

      public ServiceException(String message, Throwable cause, int errorCode, Object caller)
      Constructs a new ServiceException with the specified message, cause, error code, and caller.
      Parameters:
      message - the detail message describing the error.
      cause - the underlying cause of the exception (can be null).
      errorCode - the error code associated with the exception.
      caller - the object or class where the exception originated (can be null).
    • ServiceException

      public ServiceException(String message, Throwable cause)
      Constructs a new ServiceException with the specified message and cause.

      The error code is set to 0 and caller is set to null.

      Parameters:
      message - the detail message describing the error.
      cause - the underlying cause of the exception (can be null).