org.apache.batik.dom.svg
Class SVGDOMImplementation
java.lang.Object
|
+--org.apache.batik.dom.AbstractDOMImplementation
|
+--org.apache.batik.dom.svg.SVGDOMImplementation
- All Implemented Interfaces:
- CSSStyleDeclarationFactory, DOMImplementation, DOMImplementationCSS, StyleSheetFactory
- public class SVGDOMImplementation
- extends AbstractDOMImplementation
- implements DOMImplementationCSS, CSSStyleDeclarationFactory, StyleSheetFactory
This class implements the DOMImplementation
interface.
Method Summary |
CSSStyleDeclaration |
createCSSStyleDeclaration()
Creates a style declaration. |
CSSStyleSheet |
createCSSStyleSheet(java.lang.String title,
java.lang.String media)
DOM: Implements DOMImplementationCSS.createCSSStyleSheet(String,String) . |
Document |
createDocument(java.lang.String namespaceURI,
java.lang.String qualifiedName,
DocumentType doctype)
DOM: Implements DOMImplementation.createDocument(String,String,DocumentType) . |
DocumentType |
createDocumentType(java.lang.String qualifiedName,
java.lang.String publicId,
java.lang.String systemId)
DOM: Implements DOMImplementation.createDocumentType(String,String,String) . |
StyleSheet |
createStyleSheet(Node n,
java.lang.String data)
Creates a stylesheet from the data of an xml-stylesheet
processing instruction or throws a DOMException when it is not possible
to create the given stylesheet. |
static DOMImplementation |
getDOMImplementation()
Returns the default instance of this class. |
CSSStyleSheet |
getUserAgentStyleSheet()
Returns the user-agent stylesheet. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SVG_NAMESPACE_URI
public static final java.lang.String SVG_NAMESPACE_URI
- The SVG namespace uri.
DOM_IMPLEMENTATION
protected static final DOMImplementation DOM_IMPLEMENTATION
- The default instance of this class.
valueFactoryMap
protected ValueFactoryMap valueFactoryMap
- The CSS value factory map for SVG.
SVGDOMImplementation
public SVGDOMImplementation()
getDOMImplementation
public static DOMImplementation getDOMImplementation()
- Returns the default instance of this class.
createDocumentType
public DocumentType createDocumentType(java.lang.String qualifiedName,
java.lang.String publicId,
java.lang.String systemId)
- DOM: Implements
DOMImplementation.createDocumentType(String,String,String)
.
- Specified by:
createDocumentType
in interface DOMImplementation
- Following copied from interface:
org.w3c.dom.DOMImplementation
- Parameters:
qualifiedNameThe
- qualified name of the document type to be
created.publicIdThe
- external subset public identifier.systemIdThe
- external subset system identifier.- Returns:
- A new
DocumentType
node with
Node.ownerDocument
set to null
. - Throws:
DOMException
- INVALID_CHARACTER_ERR: Raised if the specified qualified name
contains an illegal character.
NAMESPACE_ERR: Raised if the qualifiedName
is
malformed.
createDocument
public Document createDocument(java.lang.String namespaceURI,
java.lang.String qualifiedName,
DocumentType doctype)
throws DOMException
- DOM: Implements
DOMImplementation.createDocument(String,String,DocumentType)
.
- Specified by:
createDocument
in interface DOMImplementation
- Following copied from interface:
org.w3c.dom.DOMImplementation
- Parameters:
namespaceURIThe
- namespace URI of the document element to create.qualifiedNameThe
- qualified name of the document element to be
created.doctypeThe
- type of document to be created or null
.
When doctype
is not null
, its
Node.ownerDocument
attribute is set to the document
being created.- Returns:
- A new
Document
object. - Throws:
DOMException
- INVALID_CHARACTER_ERR: Raised if the specified qualified name
contains an illegal character.
NAMESPACE_ERR: Raised if the qualifiedName
is
malformed, if the qualifiedName
has a prefix and the
namespaceURI
is null
, or if the
qualifiedName
has a prefix that is "xml" and the
namespaceURI
is different from "
http://www.w3.org/XML/1998/namespace" .
WRONG_DOCUMENT_ERR: Raised if doctype
has already
been used with a different document or was created from a different
implementation.
getUserAgentStyleSheet
public CSSStyleSheet getUserAgentStyleSheet()
- Returns the user-agent stylesheet.
createCSSStyleDeclaration
public CSSStyleDeclaration createCSSStyleDeclaration()
- Creates a style declaration.
- Specified by:
createCSSStyleDeclaration
in interface CSSStyleDeclarationFactory
- Returns:
- a CSSOMStyleDeclaration instance.
createCSSStyleSheet
public CSSStyleSheet createCSSStyleSheet(java.lang.String title,
java.lang.String media)
- DOM: Implements
DOMImplementationCSS.createCSSStyleSheet(String,String)
.
- Specified by:
createCSSStyleSheet
in interface DOMImplementationCSS
- Following copied from interface:
org.w3c.dom.css.DOMImplementationCSS
- Parameters:
title
- The advisory title. See also the section.media
- The comma-separated list of media associated with the new
style sheet. See also the section.- Returns:
- A new CSS style sheet.
- Throws:
DOMException
- SYNTAX_ERR: Raised if the specified media string value has a syntax
error and is unparsable.
createStyleSheet
public StyleSheet createStyleSheet(Node n,
java.lang.String data)
- Creates a stylesheet from the data of an xml-stylesheet
processing instruction or throws a DOMException when it is not possible
to create the given stylesheet.
- Specified by:
createStyleSheet
in interface StyleSheetFactory
Copyright © 2000 Apache Software Foundation. All Rights Reserved.