Package com.notnoop.exceptions

Examples of com.notnoop.exceptions.RuntimeIOException


        FileInputStream stream = null;
        try {
            stream = new FileInputStream(fileName);
            return withCert(stream, password);
        } catch (FileNotFoundException e) {
            throw new RuntimeIOException(e);
        } finally {
            Utilities.close(stream);
        }
    }
View Full Code Here


    FileInputStream stream = null;
    try {
      stream = new FileInputStream(fileName);
      return withCert(stream, password);
    } catch (FileNotFoundException e) {
      throw new RuntimeIOException(e);
    } finally {
      Utilities.close(stream);
    }
  }
View Full Code Here

        if (isClasspathResource(path)) {
            String classpathResourcePath = ResourceUtils.getClasspathResourcePath(path);
            is = ResourceUtils.class.getResourceAsStream(classpathResourcePath);
            if (is == null) {
                throw new RuntimeIOException("Certificate stream is null: '" + classpathResourcePath + "'");
            }
        } else {
            try {
                is = new BufferedInputStream(new FileInputStream(path));
            } catch (FileNotFoundException e) {
                throw new RuntimeIOException(e);
            }
        }

        return is;
    }
View Full Code Here

        if (isClasspathResource(path)) {
            String classpathResourcePath = ResourceUtils.getClasspathResourcePath(path);
            is = ResourceUtils.class.getResourceAsStream(classpathResourcePath);
            if (is == null) {
                throw new RuntimeIOException("Certificate stream is null: '" + classpathResourcePath + "'");
            }
        } else {
            try {
                is = IOHelper.buffered(new FileInputStream(path));
            } catch (FileNotFoundException e) {
                throw new RuntimeIOException(e);
            }
        }

        return is;
    }
View Full Code Here

        if (isClasspathResource(path)) {
            String classpathResourcePath = ResourceUtils.getClasspathResourcePath(path);
            is = ResourceUtils.class.getResourceAsStream(classpathResourcePath);
            if (is == null) {
                throw new RuntimeIOException("Certificate stream is null: '" + classpathResourcePath + "'");
            }
        } else {
            try {
                is = new BufferedInputStream(new FileInputStream(path));
            } catch (FileNotFoundException e) {
                throw new RuntimeIOException(e);
            }
        }

        return is;
    }
View Full Code Here

        FileInputStream stream = null;
        try {
            stream = new FileInputStream(fileName);
            return withCert(stream, password);
        } catch (FileNotFoundException e) {
            throw new RuntimeIOException(e);
        } finally {
            Utilities.close(stream);
        }
    }
View Full Code Here

TOP

Related Classes of com.notnoop.exceptions.RuntimeIOException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.