类 ExceptionFactory
- java.lang.Object
-
- com.mysql.cj.exceptions.ExceptionFactory
-
public class ExceptionFactory extends Object
-
-
构造器概要
构造器 构造器 说明 ExceptionFactory()
-
方法概要
所有方法 静态方法 具体方法 修饰符和类型 方法 说明 static CJCommunicationsExceptioncreateCommunicationsException(PropertySet propertySet, ServerSession serverSession, PacketSentTimeHolder packetSentTimeHolder, PacketReceivedTimeHolder packetReceivedTimeHolder, Throwable cause, ExceptionInterceptor interceptor)static <T extends CJException>
TcreateException(Class<T> clazz, String message)static <T extends CJException>
TcreateException(Class<T> clazz, String message, ExceptionInterceptor interceptor)static <T extends CJException>
TcreateException(Class<T> clazz, String message, Throwable cause)static <T extends CJException>
TcreateException(Class<T> clazz, String message, Throwable cause, ExceptionInterceptor interceptor)static CJExceptioncreateException(String message)static CJExceptioncreateException(String message, ExceptionInterceptor interceptor)static CJExceptioncreateException(String message, String sqlState, int vendorErrorCode, boolean isTransient, Throwable cause, ExceptionInterceptor interceptor)static CJExceptioncreateException(String message, Throwable cause)static CJExceptioncreateException(String message, Throwable cause, ExceptionInterceptor interceptor)static StringcreateLinkFailureMessageBasedOnHeuristics(PropertySet propertySet, ServerSession serverSession, PacketSentTimeHolder packetSentTimeHolder, PacketReceivedTimeHolder packetReceivedTimeHolder, Throwable underlyingException)Creates a communications link failure message to be used in CommunicationsException that (hopefully) has some better information and suggestions based on heuristics.
-
-
-
方法详细资料
-
createException
public static CJException createException(String message)
-
createException
public static <T extends CJException> T createException(Class<T> clazz, String message)
-
createException
public static CJException createException(String message, ExceptionInterceptor interceptor)
-
createException
public static <T extends CJException> T createException(Class<T> clazz, String message, ExceptionInterceptor interceptor)
- 类型参数:
T-CJException- 参数:
clazz- exception classmessage- messageinterceptor- exception interceptor- 返回:
CJExceptioninstance
-
createException
public static CJException createException(String message, Throwable cause)
-
createException
public static <T extends CJException> T createException(Class<T> clazz, String message, Throwable cause)
-
createException
public static CJException createException(String message, Throwable cause, ExceptionInterceptor interceptor)
-
createException
public static CJException createException(String message, String sqlState, int vendorErrorCode, boolean isTransient, Throwable cause, ExceptionInterceptor interceptor)
-
createException
public static <T extends CJException> T createException(Class<T> clazz, String message, Throwable cause, ExceptionInterceptor interceptor)
- 类型参数:
T-CJException- 参数:
clazz- exception classmessage- messagecause- exception caused this oneinterceptor- exception interceptor- 返回:
CJExceptioninstance
-
createCommunicationsException
public static CJCommunicationsException createCommunicationsException(PropertySet propertySet, ServerSession serverSession, PacketSentTimeHolder packetSentTimeHolder, PacketReceivedTimeHolder packetReceivedTimeHolder, Throwable cause, ExceptionInterceptor interceptor)
-
createLinkFailureMessageBasedOnHeuristics
public static String createLinkFailureMessageBasedOnHeuristics(PropertySet propertySet, ServerSession serverSession, PacketSentTimeHolder packetSentTimeHolder, PacketReceivedTimeHolder packetReceivedTimeHolder, Throwable underlyingException)
Creates a communications link failure message to be used in CommunicationsException that (hopefully) has some better information and suggestions based on heuristics.- 参数:
propertySet- property setserverSession- server sessionpacketSentTimeHolder- packetSentTimeHolderpacketReceivedTimeHolder- packetReceivedTimeHolderunderlyingException- underlyingException- 返回:
- message
-
-