|
What this is
Other links
The source code/* * Sun Public License Notice * * The contents of this file are subject to the Sun Public License * Version 1.0 (the "License"). You may not use this file except in * compliance with the License. A copy of the License is available at * http://www.sun.com/ * * The Original Code is NetBeans. The Initial Developer of the Original * Code is Sun Microsystems, Inc. Portions Copyright 1997-2001 Sun * Microsystems, Inc. All Rights Reserved. */ package org.netbeans.mdr.persistence; import java.io.*; /** * This is thrown when an IO error occurs in the storage layer. The IOException * is converted to a subclass of Storage Exception to maintain this simple * rule: only StorageExceptions are thrown from the storage layer. A * StorageIOException returns the stack trace information of the * original IOException occurred, since this is far more useful than the stack * trace of the point where the exception was converted. */ public class StorageIOException extends StorageException { /** The original IO Exception that we are converting to a StorageException */ private IOException ioExcept; /** this constructs a StorageIOException from an IOException * @param err the IOException */ public StorageIOException(IOException err) { super(err.getMessage()); ioExcept = err; } /** return the original IOException's message */ public String getMessage() { return ioExcept.getMessage(); } /** return the original IOException's localized message */ public String getLocalizedMessage() { return ioExcept.getLocalizedMessage(); } /** print the original IOException's stack trace */ public void printStackTrace() { ioExcept.printStackTrace(); } /** print the original IOException's stack trace */ public void printStackTrace(PrintStream ps) { ioExcept.printStackTrace(ps); } /** print the original IOException's stack trace */ public void printStackTrace(PrintWriter pw) { ioExcept.printStackTrace(pw); } } |
... this post is sponsored by my books ... | |
#1 New Release! |
FP Best Seller |
Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.
A percentage of advertising revenue from
pages under the /java/jwarehouse
URI on this website is
paid back to open source projects.