package com.graphicsengine.scene;

import com.graphicsengine.json.JSONSceneFactory;

/**
 * Creates the sceneserializer implementations
 * 
 * @author Richard Sahlin
 *
 */
public class SceneSerializerFactory {

    /**
     * Returns an implementation of the SceneSerializer interface, pass null to get the default platform serializer.
     * Pass classname for a specific implementation.
     * 
     * @param className Implementing classname or null for default.
     * @return The scene serializer implementation
     * @throws ClassNotFoundException If the specified class cannot be found
     * @throws InstantiationException If the specified class cannot be created
     * @throws IllegalAccessException If the specified class cannot be created
     */
    public static SceneSerializer getSerializer(String className) throws ClassNotFoundException,
            InstantiationException, IllegalAccessException {

        if (className == null) {
            return new JSONSceneFactory();
        }
        return (SceneSerializer) Class.forName(className).newInstance();
    }

}

@@ -32,58 +32,8 @@
 e;%0A%0A
-import com.graphicsengine.json.JSONSceneFactory;%0A%0A
 /**%0A
@@ -234,94 +234,29 @@
 ce, 
-pass null to get the default platform serializer.%0A     * Pass classname for a specific
+callers must know the
  imp
@@ -261,21 +261,25 @@
 mplement
-ation
+ing class
 .%0A     *
@@ -803,95 +803,8 @@
 on %7B
-%0A%0A        if (className == null) %7B%0A            return new JSONSceneFactory();%0A        %7D
 %0A   

Remove default serializer, caller must specify classname of serializer implementation