Package gov.nasa.worldwind.ogc.kml
Class KMLStyle
- java.lang.Object
-
- gov.nasa.worldwind.util.xml.AbstractXMLEventParser
-
- gov.nasa.worldwind.ogc.kml.KMLAbstractObject
-
- gov.nasa.worldwind.ogc.kml.KMLAbstractStyleSelector
-
- gov.nasa.worldwind.ogc.kml.KMLStyle
-
- All Implemented Interfaces:
MessageListener
,XMLEventParser
public class KMLStyle extends KMLAbstractStyleSelector
Represents the KML Style element and provides access to its contents.
-
-
Field Summary
-
Fields inherited from class gov.nasa.worldwind.ogc.kml.KMLAbstractObject
MSG_BOX_CHANGED, MSG_GEOMETRY_CHANGED, MSG_LINK_CHANGED, MSG_STYLE_CHANGED, MSG_TIME_CHANGED, MSG_VIEW_CHANGED
-
Fields inherited from class gov.nasa.worldwind.util.xml.AbstractXMLEventParser
CHARACTERS_CONTENT, fields, namespaceURI, parent
-
-
Constructor Summary
Constructors Constructor Description KMLStyle(java.lang.String namespaceURI)
Construct an instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
applyChange(KMLAbstractObject sourceValues)
KMLBalloonStyle
getBaloonStyle()
KMLIconStyle
getIconStyle()
KMLLabelStyle
getLabelStyle()
KMLLineStyle
getLineStyle()
KMLListStyle
getListStyle()
KMLPolyStyle
getPolyStyle()
KMLAbstractSubStyle
mergeSubStyle(KMLAbstractSubStyle subStyle)
Adds the sub-style fields of a specified sub-style to this one's fields if they don't already exist.void
setField(java.lang.String keyName, java.lang.Object value)
Overridden to handle deprecatedlabelColor
field.-
Methods inherited from class gov.nasa.worldwind.ogc.kml.KMLAbstractStyleSelector
markUnresolved, mergeSubStyles, mergeSubStyles
-
Methods inherited from class gov.nasa.worldwind.ogc.kml.KMLAbstractObject
getId, getRoot, getTargetId, onChange, onMessage
-
Methods inherited from class gov.nasa.worldwind.util.xml.AbstractXMLEventParser
allocate, doAddCharacters, doAddEventAttribute, doAddEventContent, doParseEventAttributes, doParseEventContent, freeResources, getAConstructor, getCharacters, getField, getField, getFields, getNamespaceURI, getParent, hasField, hasField, hasFields, mergeFields, newInstance, overrideFields, parse, parseCharacterContent, removeField, setField, setFields, setNamespaceURI, setParent
-
-
-
-
Method Detail
-
getIconStyle
public KMLIconStyle getIconStyle()
-
getLabelStyle
public KMLLabelStyle getLabelStyle()
-
getLineStyle
public KMLLineStyle getLineStyle()
-
getPolyStyle
public KMLPolyStyle getPolyStyle()
-
getBaloonStyle
public KMLBalloonStyle getBaloonStyle()
-
getListStyle
public KMLListStyle getListStyle()
-
setField
public void setField(java.lang.String keyName, java.lang.Object value)
Overridden to handle deprecatedlabelColor
field. ThelabelColor
field is deprecated, and has been replaced byLabelStyle
. IflabelColor
is set this method will apply the color to theLabelStyle
, creating a newLabelStyle
if necessary.- Overrides:
setField
in classAbstractXMLEventParser
-
mergeSubStyle
public KMLAbstractSubStyle mergeSubStyle(KMLAbstractSubStyle subStyle)
Adds the sub-style fields of a specified sub-style to this one's fields if they don't already exist.- Parameters:
subStyle
- the sub-style to merge with this one.- Returns:
- the substyle passed in as the parameter.
- Throws:
java.lang.IllegalArgumentException
- if the sub-style parameter is null.
-
applyChange
public void applyChange(KMLAbstractObject sourceValues)
- Overrides:
applyChange
in classKMLAbstractObject
-
-