public final class IoUtils
extends java.lang.Object
To limit the dependencies of eHealth's Crypto lib these operations were put here, in stead of adding a dependency to a library like Spring.
| Modifier and Type | Method and Description |
|---|---|
static java.io.FileInputStream |
openFileInputStream(java.lang.String pathname)
Opens an InputStream to a file.
|
static java.io.FileOutputStream |
openFileOutputStream(java.lang.String pathname)
Opens an OutputStream to a file.
|
static byte[] |
readFile(java.lang.String pathname)
Reads the data of a file into a byte[].
|
static java.io.File |
writeToFile(byte[] data,
java.lang.String pathname)
Writes data to a file with the given pathname.
|
public static java.io.File writeToFile(byte[] data,
java.lang.String pathname)
data - the data to writepathname - the path to the output filepublic static byte[] readFile(java.lang.String pathname)
pathname - path of the file to read.public static java.io.FileInputStream openFileInputStream(java.lang.String pathname)
pathname - path of the file to read.public static java.io.FileOutputStream openFileOutputStream(java.lang.String pathname)
pathname - path of the file to write to.Copyright © 2025 eHealth. All rights reserved.