public static byte[] getBytes(InputStream sourceStream, boolean closeStream) throws IOException {
		ByteArrayOutputStream destinationStream = new ByteArrayOutputStream();
		Streams.copyStream(sourceStream, destinationStream, closeStream);
		return destinationStream.toByteArray();
	}
public static byte [ ] getBytes ( InputStream sourceStream , boolean closeStream ) throws IOException { ByteArrayOutputStream destinationStream = new ByteArrayOutputStream ( ) ; Streams . copyStream ( sourceStream , destinationStream , closeStream ) ; return destinationStream . toByteArray ( ) ; }
Kopiert den Inhalt eines Datenstroms in ein ByteArray.

@param sourceStream
Quelldatenstrom
@param closeStream
@throws IOException