/** * Initializes the cause of this throwable. * <p> * This method will convert the cause to {@link SerializableThrowable} if it is not already. */ @Override public Throwable initCause(Throwable cause) { return super.initCause(fromThrowable(cause)); }
public void setException(Throwable exception) { thrown = SerializableThrowable.fromThrowable(exception); // Try to improve exception message if there is no class metadata available if (!thrown.isExactDesignatedTypeKnown()) { improveDesignatedType(thrown, exception); } }
public static void serialize(SerializationStreamWriter writer, LogRecord lr) throws SerializationException { // Although Level is serializable, the Level in LogRecord is actually // extending Level, which serialization does not like, so we // manually just serialize the name. writer.writeString(lr.getLevel().getName()); writer.writeString(lr.getMessage()); writer.writeString(lr.getLoggerName()); writer.writeLong(lr.getMillis()); writer.writeObject(SerializableThrowable.fromThrowable(lr.getThrown())); } }
/** * Initializes the cause of this throwable. * <p> * This method will convert the cause to {@link SerializableThrowable} if it is not already. */ @Override public Throwable initCause(Throwable cause) { return super.initCause(fromThrowable(cause)); }
/** * Initializes the cause of this throwable. * <p> * This method will convert the cause to {@link SerializableThrowable} if it is not already. */ @Override public Throwable initCause(Throwable cause) { return super.initCause(fromThrowable(cause)); }
public void setException(Throwable exception) { thrown = SerializableThrowable.fromThrowable(exception); // Try to improve exception message if there is no class metadata available if (!thrown.isExactDesignatedTypeKnown()) { improveDesignatedType(thrown, exception); } }
public static void serialize(SerializationStreamWriter writer, LogRecord lr) throws SerializationException { // Although Level is serializable, the Level in LogRecord is actually // extending Level, which serialization does not like, so we // manually just serialize the name. writer.writeString(lr.getLevel().getName()); writer.writeString(lr.getMessage()); writer.writeString(lr.getLoggerName()); writer.writeLong(lr.getMillis()); writer.writeObject(SerializableThrowable.fromThrowable(lr.getThrown())); } }
public static void serialize(SerializationStreamWriter writer, LogRecord lr) throws SerializationException { // Although Level is serializable, the Level in LogRecord is actually // extending Level, which serialization does not like, so we // manually just serialize the name. writer.writeString(lr.getLevel().getName()); writer.writeString(lr.getMessage()); writer.writeString(lr.getLoggerName()); writer.writeLong(lr.getMillis()); writer.writeObject(SerializableThrowable.fromThrowable(lr.getThrown())); } }
public void setException(Throwable exception) { thrown = SerializableThrowable.fromThrowable(exception); // Try to improve exception message if there is no class metadata available if (!thrown.isExactDesignatedTypeKnown()) { improveDesignatedType(thrown, exception); } }