|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.jsefa.rbf.RbfSerializerImpl<L>
L - the type of the RbfLowLevelSerializerpublic abstract class RbfSerializerImpl<L extends RbfLowLevelSerializer>
Abstract implementation of Serializer for RBF formats.
| Constructor Summary | |
|---|---|
protected |
RbfSerializerImpl(RbfConfiguration<?> config,
Map<Class<?>,RbfEntryPoint> entryPoints,
L lowLevelSerializer)
Constructs a new RbfSerializerImpl. |
| Method Summary | |
|---|---|
void |
close(boolean closeWriter)
Closes the serialization stream. |
void |
flush()
Flushes the stream. |
L |
getLowLevelSerializer()
Returns a low level serializer. |
void |
open(Writer writer)
Opens a new serialization stream based on the given writer. |
void |
write(Object object)
Writes the given object. |
protected abstract void |
writePrefix(String prefix)
Writes the prefix. |
protected abstract void |
writeSimpleValue(Object value,
SimpleTypeMapping<?> mapping)
Writes the given value as a simple value using the simple type mapping. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected RbfSerializerImpl(RbfConfiguration<?> config,
Map<Class<?>,RbfEntryPoint> entryPoints,
L lowLevelSerializer)
RbfSerializerImpl.
config - the configurationentryPoints - a map which maps object types to entry points.lowLevelSerializer - the low level serializer| Method Detail |
|---|
public final void open(Writer writer)
open in interface Serializerwriter - the writer to base the stream onpublic final void write(Object object)
write in interface Serializerobject - the object to writepublic void flush()
flush in interface Serializerpublic final void close(boolean closeWriter)
closeWriter is
true, too.
close in interface SerializercloseWriter - if true, the underlying writer will be closed, too.public L getLowLevelSerializer()
getLowLevelSerializer in interface RbfSerializergetLowLevelSerializer in interface Serializer
protected abstract void writeSimpleValue(Object value,
SimpleTypeMapping<?> mapping)
value - the value to writemapping - the simple type mappingprotected abstract void writePrefix(String prefix)
prefix - the prefix
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||