Now when I included buildSqlerrmc(),  It needs 
StandardException.getArgumentFerry() to be precise.

How should we solve this ?

Hi Abhinav,

Another possibility would be to move StandardException.getArgumentFerry
out of StandardException and into MessageUtils.

It's not a very complicated function, although it does need to
be able to run 'instanceof'.

Perhaps a MessageUtils implementation of this function could be
something like:


    /**
     * Unpack the exception, looking for a StandardException, which carries
     * the Derby messageID and arguments.
     * @see org.apache.derby.impl.jdbc.SQLExceptionFactory
     * @see org.apache.derby.impl.jdbc.Util
     */
    public static Exception getArgumentFerry(SQLException se, Exception carrier)
    {
        Throwable cause = se.getCause();
        return (cause instanceof carrier.getClass()) ? cause : null;
    }

Something like this might be an alternative approach.

bryan

Reply via email to