Methods Summary |
---|
public static oracle.toplink.essentials.exceptions.ConversionException | couldNotBeConverted(java.lang.Object mapping, java.lang.Object descriptor, oracle.toplink.essentials.exceptions.ConversionException exception)
Object sourceObject = exception.getSourceObject();
Class javaClass = exception.getClassToConvertTo();
Exception original = (Exception)exception.getInternalException();
Object[] args = { sourceObject, sourceObject.getClass(), mapping, descriptor, javaClass };
String message = ExceptionMessageGenerator.buildMessage(ConversionException.class, COULD_NOT_BE_CONVERTED_EXTENDED, args);
ConversionException conversionException = new ConversionException(message, sourceObject, javaClass, original);
conversionException.setStackTrace(exception.getStackTrace());
conversionException.setErrorCode(COULD_NOT_BE_CONVERTED_EXTENDED);
return conversionException;
|
public static oracle.toplink.essentials.exceptions.ConversionException | couldNotBeConverted(java.lang.Object object, java.lang.Class javaClass)
Object[] args = { object, object.getClass(), javaClass };
String message = ExceptionMessageGenerator.buildMessage(ConversionException.class, COULD_NOT_BE_CONVERTED, args);
ConversionException conversionException = new ConversionException(message, object, javaClass, null);
conversionException.setErrorCode(COULD_NOT_BE_CONVERTED);
return conversionException;
|
public static oracle.toplink.essentials.exceptions.ConversionException | couldNotBeConverted(java.lang.Object object, java.lang.Class javaClass, java.lang.Exception exception)
Object[] args = { object, object.getClass(), javaClass };
String message = ExceptionMessageGenerator.buildMessage(ConversionException.class, COULD_NOT_BE_CONVERTED, args);
ConversionException conversionException = new ConversionException(message, object, javaClass, exception);
conversionException.setErrorCode(COULD_NOT_BE_CONVERTED);
return conversionException;
|
public static oracle.toplink.essentials.exceptions.ConversionException | couldNotBeConvertedToClass(java.lang.Object object, java.lang.Class javaClass, java.lang.Exception exception)
Object[] args = { object, object.getClass(), javaClass };
String message = ExceptionMessageGenerator.buildMessage(ConversionException.class, COULD_NOT_BE_CONVERTED_TO_CLASS, args);
ConversionException conversionException = new ConversionException(message, object, javaClass, exception);
conversionException.setErrorCode(COULD_NOT_BE_CONVERTED_TO_CLASS);
return conversionException;
|
public static oracle.toplink.essentials.exceptions.ConversionException | couldNotConvertToByteArray(java.lang.Object object)
Object[] args = { object };
String message = ExceptionMessageGenerator.buildMessage(ConversionException.class, COULD_NOT_CONVERT_TO_BYTE_ARRAY, args);
ConversionException conversionException = new ConversionException(message, object, byte[].class, null);
conversionException.setErrorCode(COULD_NOT_CONVERT_TO_BYTE_ARRAY);
return conversionException;
|
public java.lang.Class | getClassToConvertTo()PUBLIC:
Return the class to convert to.
return classToConvertTo;
|
public java.lang.Object | getSourceObject()PUBLIC:
Return the object for which the problem was detected.
return sourceObject;
|
public static oracle.toplink.essentials.exceptions.ConversionException | incorrectDateFormat(java.lang.String dateString)
Object[] args = { dateString };
String message = ExceptionMessageGenerator.buildMessage(ConversionException.class, INCORRECT_DATE_FORMAT, args);
ConversionException conversionException = new ConversionException(message, dateString, java.sql.Date.class, null);
conversionException.setErrorCode(INCORRECT_DATE_FORMAT);
return conversionException;
|
public static oracle.toplink.essentials.exceptions.ConversionException | incorrectDateTimeFormat(java.lang.String dateTimeString)
Object[] args = { dateTimeString };
String message = ExceptionMessageGenerator.buildMessage(ConversionException.class, INCORRECT_DATE_TIME_FORMAT, args);
ConversionException conversionException = new ConversionException(message, dateTimeString, Calendar.class, null);
conversionException.setErrorCode(INCORRECT_DATE_TIME_FORMAT);
return conversionException;
|
public static oracle.toplink.essentials.exceptions.ConversionException | incorrectTimeFormat(java.lang.String timeString)
Object[] args = { timeString };
String message = ExceptionMessageGenerator.buildMessage(ConversionException.class, INCORRECT_TIME_FORMAT, args);
ConversionException conversionException = new ConversionException(message, timeString, java.sql.Time.class, null);
conversionException.setErrorCode(INCORRECT_TIME_FORMAT);
return conversionException;
|
public static oracle.toplink.essentials.exceptions.ConversionException | incorrectTimestampFormat(java.lang.String timestampString)
Object[] args = { timestampString };
String message = ExceptionMessageGenerator.buildMessage(ConversionException.class, INCORRECT_TIMESTAMP_FORMAT, args);
ConversionException conversionException = new ConversionException(message, timestampString, java.sql.Timestamp.class, null);
conversionException.setErrorCode(INCORRECT_TIMESTAMP_FORMAT);
return conversionException;
|
public void | setClassToConvertTo(java.lang.Class classToConvertTo)INTERNAL:
Set the class to convert to.
this.classToConvertTo = classToConvertTo;
|
public void | setSourceObject(java.lang.Object sourceObject)INTERNAL:
Set the object for which the problem was detected.
this.sourceObject = sourceObject;
|