|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.inria.ns.reflex.xml.serialize.SerializerFactory
public abstract class SerializerFactory
A serializer factory supplies concrete implementations of serializers according to the target MIME type.
Concrete implementations are supplied by the discovery mechanism, so that they can be extended or overridden.
Default implementations of serializer factories available with RefleX are localized in the "META-INF/services/org.inria.ns.reflex.xml.serialize.SerializerFactory/" directory of the jar file. From this directory, the MIME type is the relative path that contains the class name of the default implementation for that MIME type.
For example, "META-INF/services/org.inria.ns.reflex.xml.serialize.SerializerFactory/image/jpeg" is a file that contains the name of the serializer "org.inria.ns.reflex.xml.provider.svg.JPEGSerializerFactory".
Discover
Constructor Summary | |
---|---|
SerializerFactory()
|
Method Summary | |
---|---|
static SerializerFactory |
getSerializerFactory(String mimeType)
Get a specific serializer factory (FO to PDF, SVG to JPEG, etc), or null. |
abstract Serializer |
newSerializer()
Return a new serializer. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SerializerFactory()
Method Detail |
---|
public static SerializerFactory getSerializerFactory(String mimeType) throws InstantiationException, IllegalAccessException, ClassNotFoundException
mimeType
- The MIME type of the expected output.
null
if not supported.
ClassNotFoundException
- When the class name of the implementation is misspelled or is missing in the classpath.
IllegalAccessException
- When the class can't be accessed.
InstantiationException
- When the class can't be instanciated.public abstract Serializer newSerializer()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |