* @param graph if graphing should be enabled
* @return the serializer
*/
public static final Serializer create(FormatType format, CompressionType compression, boolean graph) {
Serializer serializer = null;
SerializationProvider provider = SerializationProvider.getPrimaryProvider(format);
if (provider != null) {
serializer = provider.newSerializer(format);
if (graph) {
serializer = new GraphSerializer(serializer);
}
if (compression != null) {
if (CompressionType.GZIP.equals(compression)) {