org.jppf.serialization
Class XstreamObjectStreamBuilder
java.lang.Object
org.jppf.serialization.XstreamObjectStreamBuilder
- All Implemented Interfaces:
- JPPFObjectStreamBuilder
public class XstreamObjectStreamBuilder
- extends Object
- implements JPPFObjectStreamBuilder
Object stream factory that creates streams from the XStream framework.
This enables serialization to and deserialization from XML streams, and allows non-serializable classes to be processed.
If you do not use it, it will not generate compile time errors, even if the XStream libraries are not in the classpath,
as this class relies entirely on reflection to instantiate the required objects.
- Author:
- Laurent Cohen
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XstreamObjectStreamBuilder
public XstreamObjectStreamBuilder()
newObjectInputStream
public ObjectInputStream newObjectInputStream(InputStream in)
throws Exception
- Obtain an input stream used for deserializing objects.
- Specified by:
newObjectInputStream in interface JPPFObjectStreamBuilder
- Parameters:
in - input stream to read from.
- Returns:
- an
ObjectInputStream
- Throws:
Exception - if an error is raised while creating the stream.- See Also:
JPPFObjectStreamBuilder.newObjectInputStream(java.io.InputStream)
newObjectOutputStream
public ObjectOutputStream newObjectOutputStream(OutputStream out)
throws Exception
- Obtain an Output stream used for serializing objects.
- Specified by:
newObjectOutputStream in interface JPPFObjectStreamBuilder
- Parameters:
out - output stream to write to.
- Returns:
- an
ObjectOutputStream
- Throws:
Exception - if an error is raised while creating the stream.- See Also:
JPPFObjectStreamBuilder.newObjectOutputStream(java.io.OutputStream)
Copyright © 2005-2010 JPPF Team.