public class GMLConfiguration extends Configuration
Modifier and Type | Field and Description |
---|---|
static QName |
ENCODE_FEATURE_MEMBER
Boolean property which controls whether the FeatureCollection should be encoded with multiple
featureMember as opposed to a single featureMembers
|
protected boolean |
forceDecimalEncoding
Force usage of decimals instead of scientific notation *
|
static QName |
NO_FEATURE_BOUNDS
Property which controls whether encoded features should include bounds.
|
static QName |
NO_SRS_DIMENSION
Boolean property which controls whether geometry and envelope objects are encoded with an srs
dimension attribute (not really used for GML2, added for compatibility with GML3)
|
protected int |
numDecimals
Number of decimals in the output
|
static QName |
OPTIMIZED_ENCODING
Property which engages "fast" gml encoding.
|
protected boolean |
padWithZeros
Right-Pad coordinates decimals with zeros up to the configured number of decimals
|
protected SrsSyntax |
srsSyntax
Srs name style to encode srsName URI's with
|
Constructor and Description |
---|
GMLConfiguration()
Creates the new gml configuration, with a depenendency on
XLINKConfiguration |
Modifier and Type | Method and Description |
---|---|
void |
configureContext(MutablePicoContainer container)
Configures the gml2 context.
|
boolean |
getForceDecimalEncoding()
Returns true if decimal notation should always be used, and scientific notation always
avoided.
|
int |
getNumDecimals()
Returns the number of decimals that should be used for encoding coordinates (defaults to 6)
|
boolean |
getPadWithZeros()
Returns true if decimals of coordinates are padded with zeros up to the configured number of
decimals.
|
SrsSyntax |
getSrsSyntax()
Returns the syntax to use for encoding srs uris.
|
void |
registerBindings(MutablePicoContainer container)
Registers the bindings for the configuration.
|
void |
setForceDecimalEncoding(boolean forceDecimalEncoding)
Forces usage of decimal notation, avoiding scientific notations to encode coordinates.
|
void |
setNumDecimals(int numDecimals)
Sets the number of decimals that should be used for encoding coordinates
|
void |
setPadWithZeros(boolean padWithZeros)
Formats decimals of coordinates padding with zeros up to the configured number of decimals.
|
void |
setSrsSyntax(SrsSyntax srsSyntax)
Sets the syntax to use for encoding srs uris.
|
addDependency, allDependencies, configureBindings, configureBindings, configureEncoder, configureParser, equals, getContext, getDependencies, getDependency, getNamespaceURI, getProperties, getSchemaFileURL, getSchemaLocationResolver, getSchemaLocator, getXSD, hashCode, hasProperty, registerBindings, schema, setupBindings, setupBindings, setupContext, setupEncoder, setupParser
public static final QName NO_FEATURE_BOUNDS
public static final QName ENCODE_FEATURE_MEMBER
public static final QName NO_SRS_DIMENSION
public static final QName OPTIMIZED_ENCODING
protected SrsSyntax srsSyntax
protected int numDecimals
protected boolean padWithZeros
protected boolean forceDecimalEncoding
public GMLConfiguration()
XLINKConfiguration
public void setSrsSyntax(SrsSyntax srsSyntax)
If this method is not explicitly called SrsSyntax#LEGACY
is used as the default.
public SrsSyntax getSrsSyntax()
public void registerBindings(MutablePicoContainer container)
Configuration
This method is intended to provide the default bindings for a configuration and is
intended to be subclassed by client code. Client code should use Configuration.configureBindings(MutablePicoContainer)
. Subclasses should mark this method as final after
implementing.
registerBindings
in class Configuration
container
- Container containing all bindings, keyed by QName
.public void configureContext(MutablePicoContainer container)
The following classes are registered:
CoordinateArraySequenceFactory
under CoordinateSequenceFactory
GeometryFactory
FeatureTypeCache
DefaultFeatureCollections
configureContext
in class Configuration
container
- The container representing the context.public int getNumDecimals()
public void setNumDecimals(int numDecimals)
numDecimals
- the numDecimals to setpublic void setPadWithZeros(boolean padWithZeros)
padWithZeros
- right pad decimals with zerospublic void setForceDecimalEncoding(boolean forceDecimalEncoding)
forceDecimalEncoding
- avoid scientific notation, always use decimalpublic boolean getPadWithZeros()
public boolean getForceDecimalEncoding()
Copyright © 1996–2019 Geotools. All rights reserved.