Code example for JDBCException

Methods: getCausegetMessagegetSQL

0
		if (!(t instanceof JDBCException))
			return caster().toPageException(t);
		 
		 
		JDBCException j = (JDBCException)t;
		String message = j.getMessage(); 
		Throwable cause = j.getCause();
		if(cause != null) {
			message += " [" + cause.getMessage() + "]";
		} 
		return CFMLEngineFactory.getInstance().getExceptionUtil().createDatabaseException(message, new SQLImpl(j.getSQL()));
		 
	} 
	public static Serializable toSerializable(Object obj) throws PageException {
		return caster().toSerializable(obj); 
	} 
	public static Serializable toSerializable(Object obj,Serializable defaultValue) {
		return caster().toSerializable(obj,defaultValue);
	}