org.openjump.util
Class SLDImporter

java.lang.Object
  extended by org.openjump.util.SLDImporter

public class SLDImporter
extends java.lang.Object

SLDImporter

Version:
$Revision:$, $Date:$
Author:
Andreas Schmitz, last edited by: $Author:$

Nested Class Summary
static interface SLDImporter.FillStyle
          FillStyle
static interface SLDImporter.SizedStrokeFillStyle
          SizedStrokeFillStyle
static interface SLDImporter.SizedStyle
          SizedStyle
static interface SLDImporter.StrokeFillStyle
          StrokeFillStyle
static interface SLDImporter.StrokeStyle
          StrokeStyle
 
Field Summary
static javax.xml.namespace.NamespaceContext NSCONTEXT
          Namespace context with sld and ogc namespaces.
static java.lang.String OGCNS
          The OGC namespace URI.
static java.lang.String SLDNS
          The SLD namespace URI.
 
Constructor Summary
SLDImporter()
           
 
Method Summary
static BasicStyle getBasicStyle(org.w3c.dom.Element rule)
          Ignores any filters, and uses the information from Point-, Line- and PolygonSymbolizers.
static BasicStyle getBasicStyle(java.lang.String name, org.w3c.dom.Document doc)
           
static ColorThemingStyle getColorThemingStyle(java.lang.String name, org.w3c.dom.Document doc)
           
static LabelStyle getLabelStyle(java.lang.String name, org.w3c.dom.Document doc)
          Converts a TextSymbolizer.
static java.util.LinkedList<java.lang.String> getPossibleColorThemingStyleNames(org.w3c.dom.Document doc)
           
static java.util.LinkedList<java.lang.String> getRuleNames(org.w3c.dom.Document doc)
           
static java.util.LinkedList<java.lang.String> getRuleNamesWithGeometrySymbolizers(org.w3c.dom.Document doc)
           
static java.util.LinkedList<java.lang.String> getRuleNamesWithTextSymbolizers(org.w3c.dom.Document doc)
           
static VertexStyle getVertexStyle(java.lang.String name, org.w3c.dom.Document doc)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SLDNS

public static final java.lang.String SLDNS
The SLD namespace URI.

See Also:
Constant Field Values

OGCNS

public static final java.lang.String OGCNS
The OGC namespace URI.

See Also:
Constant Field Values

NSCONTEXT

public static final javax.xml.namespace.NamespaceContext NSCONTEXT
Namespace context with sld and ogc namespaces.

Constructor Detail

SLDImporter

public SLDImporter()
Method Detail

getRuleNames

public static java.util.LinkedList<java.lang.String> getRuleNames(org.w3c.dom.Document doc)
Parameters:
doc -
Returns:
a list of SLD rule names

getRuleNamesWithGeometrySymbolizers

public static java.util.LinkedList<java.lang.String> getRuleNamesWithGeometrySymbolizers(org.w3c.dom.Document doc)
Parameters:
doc -
Returns:
a list of SLD rule names

getPossibleColorThemingStyleNames

public static java.util.LinkedList<java.lang.String> getPossibleColorThemingStyleNames(org.w3c.dom.Document doc)
Parameters:
doc -
Returns:
a list of SLD FeatureTypeStyle names

getRuleNamesWithTextSymbolizers

public static java.util.LinkedList<java.lang.String> getRuleNamesWithTextSymbolizers(org.w3c.dom.Document doc)
Parameters:
doc -
Returns:
a list of SLD rule names

getBasicStyle

public static BasicStyle getBasicStyle(java.lang.String name,
                                       org.w3c.dom.Document doc)
Parameters:
name -
doc -
Returns:
a corresponding BasicStyle
See Also:
getBasicStyle(Element)

getBasicStyle

public static BasicStyle getBasicStyle(org.w3c.dom.Element rule)
Ignores any filters, and uses the information from Point-, Line- and PolygonSymbolizers.

Parameters:
rule -
Returns:
a corresponding BasicStyle

getVertexStyle

public static VertexStyle getVertexStyle(java.lang.String name,
                                         org.w3c.dom.Document doc)
Parameters:
name -
doc -
Returns:
a vertex style, if a special one was found (use the basic style from #getBasicStyle if this is null)

getLabelStyle

public static LabelStyle getLabelStyle(java.lang.String name,
                                       org.w3c.dom.Document doc)
Converts a TextSymbolizer.

Parameters:
name -
doc -
Returns:
the label style or null, if none was found

getColorThemingStyle

public static ColorThemingStyle getColorThemingStyle(java.lang.String name,
                                                     org.w3c.dom.Document doc)
Parameters:
name - the name of the feature type style
doc -
Returns:
the color theming style