com.softicar.platform.common.io.stream.EmptyInputStream Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of platform-common Show documentation
Show all versions of platform-common Show documentation
The SoftiCAR Platform is a lightweight, Java-based library to create interactive business web applications.
package com.softicar.platform.common.io.stream;
import java.io.InputStream;
/**
* The empty {@link InputStream}.
*
* @author Oliver Richers
*/
public class EmptyInputStream extends InputStream {
private static final EmptyInputStream SINGLETON = new EmptyInputStream();
private EmptyInputStream() {
// singleton
}
public static EmptyInputStream get() {
return SINGLETON;
}
@Override
public int read() {
return -1;
}
}