Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.ecm.core.api
Class SerializableInputStream

java.lang.Object
  extended by java.io.InputStream
      extended by org.nuxeo.ecm.core.api.SerializableInputStream
All Implemented Interfaces:
Closeable, Serializable

public class SerializableInputStream
extends InputStream
implements Serializable

A serializable input stream.

Note: The stream is closed after the object is serialized.

Author:
Bogdan Stefanescu
See Also:
Serialized Form

Field Summary
static int IN_MEM_LIMIT
           
 
Constructor Summary
SerializableInputStream(byte[] content)
           
SerializableInputStream(InputStream in)
           
SerializableInputStream(String content)
           
 
Method Summary
 int available()
           
 boolean canReopen()
           
 void close()
           
 File getTempFile()
           
 void mark(int readlimit)
           
 boolean markSupported()
           
 int read()
           
 int read(byte[] b)
           
 int read(byte[] b, int off, int len)
           
 InputStream reopen()
           
 void reset()
           
 long skip(long n)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

IN_MEM_LIMIT

public static final int IN_MEM_LIMIT
See Also:
Constant Field Values
Constructor Detail

SerializableInputStream

public SerializableInputStream(InputStream in)

SerializableInputStream

public SerializableInputStream(byte[] content)

SerializableInputStream

public SerializableInputStream(String content)
Method Detail

available

public int available()
              throws IOException
Overrides:
available in class InputStream
Throws:
IOException

close

public void close()
           throws IOException
Specified by:
close in interface Closeable
Overrides:
close in class InputStream
Throws:
IOException

mark

public void mark(int readlimit)
Overrides:
mark in class InputStream

markSupported

public boolean markSupported()
Overrides:
markSupported in class InputStream

read

public int read()
         throws IOException
Specified by:
read in class InputStream
Throws:
IOException

read

public int read(byte[] b,
                int off,
                int len)
         throws IOException
Overrides:
read in class InputStream
Throws:
IOException

read

public int read(byte[] b)
         throws IOException
Overrides:
read in class InputStream
Throws:
IOException

reset

public void reset()
           throws IOException
Overrides:
reset in class InputStream
Throws:
IOException

getTempFile

public File getTempFile()

reopen

public InputStream reopen()
                   throws IOException
Throws:
IOException

canReopen

public boolean canReopen()

skip

public long skip(long n)
          throws IOException
Overrides:
skip in class InputStream
Throws:
IOException

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.