FileDocCategorySizeDatePackage
SVGTinyModelFactory.javaAPI DocphoneME MR2 API (J2ME)5866Wed May 02 18:00:36 BST 2007com.sun.perseus.builder

SVGTinyModelFactory

public class SVGTinyModelFactory extends Object
This ModelFactory implementation is initialized with all the handlers necessary to handle SVG Tiny 1.1 content.
version
$Id: SVGTinyModelFactory.java,v 1.5 2006/04/21 06:36:12 st125089 Exp $

Fields Summary
public static final String[]
FOREIGN_OBJECT_REQUIRED_ATTRIBUTES
List of required attributes for foreignObject.
Constructors Summary
Methods Summary
public static java.util.VectorgetPrototypes(com.sun.perseus.model.DocumentNode doc)

param
doc the document for which the prototypes are built.
return
a Vector with all the prototypes for SVG Tiny content.


                              
          
        Vector v = new Vector();

        //
        // == Structure Module =================================================
        //
        v.addElement(new SVG(doc));
        v.addElement(new Group(doc));
        v.addElement(new Use(doc));
        v.addElement(new Defs(doc));
        v.addElement(new ImageNode(doc));
        v.addElement(new Switch(doc));
        v.addElement(new Symbol(doc));

        // 
        // == Shape Module =====================================================
        //
        v.addElement(new ShapeNode(doc, SVGConstants.SVG_PATH_TAG));
        v.addElement(new Rect(doc));
        v.addElement(new Line(doc));
        v.addElement(new Ellipse(doc));
        v.addElement(new Ellipse(doc, true)); // <circle>
        v.addElement(new ShapeNode(doc, SVGConstants.SVG_POLYGON_TAG));
        v.addElement(new ShapeNode(doc, SVGConstants.SVG_POLYLINE_TAG));

        // 
        // == Text Module ======================================================
        //
        v.addElement(new Text(doc));
        // v.addElement(new TSpan(doc));

        //
        // == Font Module ======================================================
        //
        v.addElement(new Font(doc));
        v.addElement(new FontFace(doc));
        v.addElement(new Glyph(doc));
        v.addElement(new Glyph(doc, SVGConstants.SVG_MISSING_GLYPH_TAG));
        v.addElement(new HKern(doc)); 

        // 
        // == Hyperlinking Module ==============================================
        //
        v.addElement(new Anchor(doc));

        // 
        // == Animation Module =================================================
        //
        v.addElement(new Animate(doc));
        v.addElement(new AnimateMotion(doc));
        v.addElement(new Set(doc));
        v.addElement(new AnimateTransform(doc));
        v.addElement(new Animate(doc, SVGConstants.SVG_ANIMATE_COLOR_TAG));
        
        //
        // == SolidColor Module ================================================
        //
        v.addElement(new SolidColor(doc));

        //
        // == Gradient Module ================================================
        //
        v.addElement(new LinearGradient(doc));
        v.addElement(new RadialGradient(doc));
        v.addElement(new Stop(doc));

        //
        // == Extensibility Module =========================================
        //
        v.addElement(new StrictElement(doc, 
                                       SVGConstants.SVG_FOREIGN_OBJECT_TAG,
                                       SVGConstants.SVG_NAMESPACE_URI,
                                       FOREIGN_OBJECT_REQUIRED_ATTRIBUTES,
                                       null));
        //
        // == Medial Module ================================================
        //
        // v.addElement(new Audio(doc));

        return v;