...
A Document is a container for features and styles. This element is required if your
KML file uses shared styles. It is recommended that you use shared styles, which
require the following steps:
Define all Styles in a Document. Assign a unique ID to each Style. Within a given
Feature or StyleMap, reference the Style's ID using a element.
Do not put shared styles within a Folder.
Each Feature must explicitly reference the styles it uses in a element.
For a Style that applies to a Document (such as ListStyle), the Document itself
must explicitly reference the . For example:
Note that shared styles are not inherited by the Features in the Document.
The following example illustrates use of a shared style.
Syntax:
<Document id="ID">
<!-- inherited from Feature element -->
<name>... </name> <!-- string -->
<visibility>1</visibility> <!-- boolean -->
<open>0</open> <!-- boolean -->
<atom:author>...<atom:author> <!-- xmlns:atom -->
<atom:link>...</atom:link> <!-- xmlns:atom -->
<address>... </address> <!-- string -->
<xal:AddressDetails>...</xal:AddressDetails> <!-- xmlns:xal --> <phoneNumber>...</phoneNumber> <!-- string --> <Snippet maxLines="2">... </Snippet> <!-- string -->
<description>... </description> <!-- string -->
<AbstractView>...</AbstractView> <!-- Camera or LookAt -->
<TimePrimitive >...</TimePrimitive >
<styleUrl>... </styleUrl> <!-- anyURI -->
<StyleSelector>...</StyleSelector>
<Region>...</Region>
<Metadata>...</Metadata> <!-- deprecated in KML 2.2 -->
<ExtendedData>...</ExtendedData> <!-- new in KML 2.2 -->
<!-- specific to Document -->
<!-- 0 or more Schema elements -->
<!-- 0 or more Feature elements -->
</Document>
Extends:
Fields inherited from class de.micromata.opengis.kml.v_2_2_0.Feature
abstractView , address , atomAuthor , atomLink , description , extendedData , featureObjectExtension , featureSimpleExtension , metadata , name , open , phoneNumber , region , snippet , snippetd , styleSelector , styleUrl , timePrimitive , visibility , xalAddressDetails
Methods inherited from class de.micromata.opengis.kml.v_2_2_0.Feature
createAndAddStyle , createAndAddStyleMap , createAndSetAtomAuthor , createAndSetAtomLink , createAndSetCamera , createAndSetExtendedData , createAndSetLookAt , createAndSetMetadata , createAndSetRegion , createAndSetSnippet , createAndSetTimeSpan , createAndSetTimeStamp , createAndSetXalAddressDetails , getAbstractView , getAddress , getAtomAuthor , getAtomLink , getDescription , getExtendedData , getFeatureObjectExtension , getFeatureSimpleExtension , getMetadata , getName , getPhoneNumber , getRegion , getSnippet , getSnippetd , getStyleSelector , getStyleUrl , getTimePrimitive , getXalAddressDetails , isOpen , isVisibility , setAbstractView , setAddress , setAtomAuthor , setAtomLink , setDescription , setExtendedData , setMetadata , setName , setOpen , setPhoneNumber , setRegion , setSnippet , setSnippetd , setStyleUrl , setTimePrimitive , setVisibility , setXalAddressDetails
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
schema
protected java.util.List<Schema > schema
Specifies a custom KML schema that is used to add custom data to KML Features. The
"id" attribute is required and must be unique within the KML file. is always
a child of .
Syntax:
<Schema name="string" id="ID">
<SimpleField type="string" name="string">
<displayName>...</displayName> <!-- string -->
</SimpleField>
</Schema>
Extends:
feature
protected java.util.List<Feature > feature
This is an abstract element and cannot be used directly in a KML file. The following
diagram shows how some of a Feature's elements appear in Google Earth.
Syntax:
<!-- abstract element; do not create -->
<!-- Feature id="ID" --> <!-- Document,Folder,
NetworkLink,Placemark,
GroundOverlay,PhotoOverlay,ScreenOverlay -->
<name>... </name> <!-- string -->
<visibility>1</visibility> <!-- boolean -->
<open>0</open> <!-- boolean -->
<atom:author>...<atom:author> <!-- xmlns:atom -->
<atom:link>...</atom:link> <!-- xmlns:atom -->
<address>... </address> <!-- string -->
<xal:AddressDetails>...</xal:AddressDetails> <!-- xmlns:xal --> <phoneNumber>...</phoneNumber> <!-- string --> <Snippet maxLines="2">... </Snippet> <!-- string -->
<description>... </description> <!-- string -->
<AbstractView>...</AbstractView> <!-- Camera or LookAt -->
<TimePrimitive >...</TimePrimitive > <!-- TimeStamp or TimeSpan -->
<styleUrl>... </styleUrl> <!-- anyURI -->
<StyleSelector>...</StyleSelector>
<Region>...</Region>
<Metadata>...</Metadata> <!-- deprecated in KML 2.2 -->
<ExtendedData>...</ExtendedData> <!-- new in KML 2.2 --> <-- /Feature -->
Extends:
documentSimpleExtension
protected java.util.List<java.lang.Object> documentSimpleExtension
documentObjectExtension
protected java.util.List<AbstractObject > documentObjectExtension
This is an abstract base class and cannot be used directly in a KML file. It provides
the id attribute, which allows unique identification of a KML element, and the targetId
attribute, which is used to reference objects that have already been loaded into
Google Earth. The id attribute must be assigned if the mechanism is to
be used.
Syntax:
<!-- abstract element; do not create -->
<!-- Object id="ID" targetId="NCName" -->
<!-- /Object > -->
Document
public Document ()
getSchema
public java.util.List<Schema > getSchema ()
See Also: schema
getFeature
public java.util.List<Feature > getFeature ()
See Also: feature
getDocumentSimpleExtension
public java.util.List<java.lang.Object> getDocumentSimpleExtension ()
See Also: documentSimpleExtension
getDocumentObjectExtension
public java.util.List<AbstractObject > getDocumentObjectExtension ()
See Also: documentObjectExtension
hashCode
public int hashCode ()
Overrides: hashCode
in class Container
equals
public boolean equals (java.lang.Object obj)
Overrides: equals
in class Container
createAndAddSchema
public Schema createAndAddSchema ()
Creates a new instance of Schema
and adds it to schema.
This method is a short version for:
Schema schema = new Schema();
this.getSchema().add(schema);
createAndAddTour
public Tour createAndAddTour ()
Creates a new instance of Tour
and adds it to feature.
This method is a short version for:
Tour tour = new Tour();
this.getFeature().add(tour);
createAndAddNetworkLink
public NetworkLink createAndAddNetworkLink ()
Creates a new instance of NetworkLink
and adds it to feature.
This method is a short version for:
NetworkLink networkLink = new NetworkLink();
this.getFeature().add(networkLink);
createAndAddPhotoOverlay
public PhotoOverlay createAndAddPhotoOverlay ()
Creates a new instance of PhotoOverlay
and adds it to feature.
This method is a short version for:
PhotoOverlay photoOverlay = new PhotoOverlay();
this.getFeature().add(photoOverlay);
createAndAddScreenOverlay
public ScreenOverlay createAndAddScreenOverlay ()
Creates a new instance of ScreenOverlay
and adds it to feature.
This method is a short version for:
ScreenOverlay screenOverlay = new ScreenOverlay();
this.getFeature().add(screenOverlay);
createAndAddGroundOverlay
public GroundOverlay createAndAddGroundOverlay ()
Creates a new instance of GroundOverlay
and adds it to feature.
This method is a short version for:
GroundOverlay groundOverlay = new GroundOverlay();
this.getFeature().add(groundOverlay);
createAndAddDocument
public Document createAndAddDocument ()
Creates a new instance of Document
and adds it to feature.
This method is a short version for:
Document document = new Document();
this.getFeature().add(document);
createAndAddFolder
public Folder createAndAddFolder ()
Creates a new instance of Folder
and adds it to feature.
This method is a short version for:
Folder folder = new Folder();
this.getFeature().add(folder);
createAndAddPlacemark
public Placemark createAndAddPlacemark ()
Creates a new instance of Placemark
and adds it to feature.
This method is a short version for:
Placemark placemark = new Placemark();
this.getFeature().add(placemark);
setSchema
public void setSchema (java.util.List<Schema > schema)
Parameters: schema
- See Also: schema
addToSchema
public Document addToSchema (Schema schema)
add a value to the schema property collection
Parameters: schema
- Objects of the following type are allowed in the list: Schema
Returns: true (as general contract of Collection.add ).
setFeature
public void setFeature (java.util.List<Feature > feature)
Parameters: feature
- See Also: feature
addToFeature
public Document addToFeature (Feature feature)
add a value to the feature property collection
Parameters: feature
- Objects of the following type are allowed in the list: <
Tour
JAXBElement
<
Container
JAXBElement
<
Document
JAXBElement
<
NetworkLink
JAXBElement
<
GroundOverlay
JAXBElement
<
Folder
JAXBElement
<
PhotoOverlay
JAXBElement
<
Feature
JAXBElement
<
Placemark
JAXBElement
<
Overlay
JAXBElement
<
ScreenOverlay
Returns: true (as general contract of Collection.add ).
setDocumentSimpleExtension
public void setDocumentSimpleExtension (java.util.List<java.lang.Object> documentSimpleExtension)
Parameters: documentSimpleExtension
- See Also: documentSimpleExtension
addToDocumentSimpleExtension
public Document addToDocumentSimpleExtension (java.lang.Object documentSimpleExtension)
add a value to the documentSimpleExtension property collection
Parameters: documentSimpleExtension
- Objects of the following type are allowed in the list: Object
Returns: true (as general contract of Collection.add ).
setDocumentObjectExtension
public void setDocumentObjectExtension (java.util.List<AbstractObject > documentObjectExtension)
Parameters: documentObjectExtension
- See Also: documentObjectExtension
addToDocumentObjectExtension
public Document addToDocumentObjectExtension (AbstractObject documentObjectExtension)
add a value to the documentObjectExtension property collection
Parameters: documentObjectExtension
- Objects of the following type are allowed in the list: AbstractObject
Returns: true (as general contract of Collection.add ).
setObjectSimpleExtension
public void setObjectSimpleExtension (java.util.List<java.lang.Object> objectSimpleExtension)
Overrides: setObjectSimpleExtension
in class Container
See Also: objectSimpleExtension
addToObjectSimpleExtension
public Document addToObjectSimpleExtension (java.lang.Object objectSimpleExtension)
Description copied from class: AbstractObject
add a value to the objectSimpleExtension property collection
Overrides: addToObjectSimpleExtension
in class Container
Parameters: objectSimpleExtension
- Objects of the following type are allowed in the list: Object
Returns: true (as general contract of Collection.add ).
setStyleSelector
public void setStyleSelector (java.util.List<StyleSelector > styleSelector)
Overrides: setStyleSelector
in class Container
See Also: styleSelector
addToStyleSelector
public Document addToStyleSelector (StyleSelector styleSelector)
Description copied from class: Feature
add a value to the styleSelector property collection
Overrides: addToStyleSelector
in class Container
Parameters: styleSelector
- Objects of the following type are allowed in the list: <
StyleSelector
JAXBElement
<
StyleMap
JAXBElement
<
Style
Returns: true (as general contract of Collection.add ).
setFeatureSimpleExtension
public void setFeatureSimpleExtension (java.util.List<java.lang.Object> featureSimpleExtension)
Overrides: setFeatureSimpleExtension
in class Container
See Also: featureSimpleExtension
addToFeatureSimpleExtension
public Document addToFeatureSimpleExtension (java.lang.Object featureSimpleExtension)
Description copied from class: Feature
add a value to the featureSimpleExtension property collection
Overrides: addToFeatureSimpleExtension
in class Container
Parameters: featureSimpleExtension
- Objects of the following type are allowed in the list: <
Object
JAXBElement
<
Boolean
Returns: true (as general contract of Collection.add ).
setFeatureObjectExtension
public void setFeatureObjectExtension (java.util.List<AbstractObject > featureObjectExtension)
Overrides: setFeatureObjectExtension
in class Container
See Also: featureObjectExtension
addToFeatureObjectExtension
public Document addToFeatureObjectExtension (AbstractObject featureObjectExtension)
Description copied from class: Feature
add a value to the featureObjectExtension property collection
Overrides: addToFeatureObjectExtension
in class Container
Parameters: featureObjectExtension
- Objects of the following type are allowed in the list: AbstractObject
Returns: true (as general contract of Collection.add ).
setContainerSimpleExtension
public void setContainerSimpleExtension (java.util.List<java.lang.Object> containerSimpleExtension)
Overrides: setContainerSimpleExtension
in class Container
See Also: containerSimpleExtension
addToContainerSimpleExtension
public Document addToContainerSimpleExtension (java.lang.Object containerSimpleExtension)
Description copied from class: Container
add a value to the containerSimpleExtension property collection
Overrides: addToContainerSimpleExtension
in class Container
Parameters: containerSimpleExtension
- Objects of the following type are allowed in the list: Object
Returns: true (as general contract of Collection.add ).
setContainerObjectExtension
public void setContainerObjectExtension (java.util.List<AbstractObject > containerObjectExtension)
Overrides: setContainerObjectExtension
in class Container
See Also: containerObjectExtension
addToContainerObjectExtension
public Document addToContainerObjectExtension (AbstractObject containerObjectExtension)
Description copied from class: Container
add a value to the containerObjectExtension property collection
Overrides: addToContainerObjectExtension
in class Container
Parameters: containerObjectExtension
- Objects of the following type are allowed in the list: AbstractObject
Returns: true (as general contract of Collection.add ).
withSchema
public Document withSchema (java.util.List<Schema > schema)
fluent setter
Parameters: schema
- required parameterSee Also: #setSchema(List)
withFeature
public Document withFeature (java.util.List<Feature > feature)
fluent setter
Parameters: feature
- required parameterSee Also: #setFeature(List)
withDocumentSimpleExtension
public Document withDocumentSimpleExtension (java.util.List<java.lang.Object> documentSimpleExtension)
fluent setter
Parameters: documentSimpleExtension
- required parameterSee Also: #setDocumentSimpleExtension(List)
withDocumentObjectExtension
public Document withDocumentObjectExtension (java.util.List<AbstractObject > documentObjectExtension)
fluent setter
Parameters: documentObjectExtension
- required parameterSee Also: #setDocumentObjectExtension(List)
withObjectSimpleExtension
public Document withObjectSimpleExtension (java.util.List<java.lang.Object> objectSimpleExtension)
Description copied from class: AbstractObject
fluent setter
Overrides: withObjectSimpleExtension
in class Container
Parameters: objectSimpleExtension
- required parameterSee Also: #setObjectSimpleExtension(List)
withId
public Document withId (java.lang.String id)
Description copied from class: AbstractObject
fluent setter
Overrides: withId
in class Container
Parameters: id
- required parameterSee Also: AbstractObject.setId(String)
withTargetId
public Document withTargetId (java.lang.String targetId)
Description copied from class: AbstractObject
fluent setter
Overrides: withTargetId
in class Container
Parameters: targetId
- required parameterSee Also: AbstractObject.setTargetId(String)
withName
public Document withName (java.lang.String name)
Description copied from class: Feature
fluent setter
Overrides: withName
in class Container
Parameters: name
- required parameterSee Also: Feature.setName(String)
withVisibility
public Document withVisibility (java.lang.Boolean visibility)
Description copied from class: Feature
fluent setter
Overrides: withVisibility
in class Container
Parameters: visibility
- required parameterSee Also: Feature.setVisibility(Boolean)
withOpen
public Document withOpen (java.lang.Boolean open)
Description copied from class: Feature
fluent setter
Overrides: withOpen
in class Container
Parameters: open
- required parameterSee Also: Feature.setOpen(Boolean)
withAtomAuthor
public Document withAtomAuthor (Author atomAuthor)
Description copied from class: Feature
fluent setter
Overrides: withAtomAuthor
in class Container
Parameters: atomAuthor
- required parameterSee Also: Feature.setAtomAuthor(Author)
withAtomLink
public Document withAtomLink (Link atomLink)
Description copied from class: Feature
fluent setter
Overrides: withAtomLink
in class Container
Parameters: atomLink
- required parameterSee Also: Feature.setAtomLink(Link)
withAddress
public Document withAddress (java.lang.String address)
Description copied from class: Feature
fluent setter
Overrides: withAddress
in class Container
Parameters: address
- required parameterSee Also: Feature.setAddress(String)
withXalAddressDetails
public Document withXalAddressDetails (AddressDetails xalAddressDetails)
Description copied from class: Feature
fluent setter
Overrides: withXalAddressDetails
in class Container
Parameters: xalAddressDetails
- required parameterSee Also: Feature.setXalAddressDetails(AddressDetails)
withPhoneNumber
public Document withPhoneNumber (java.lang.String phoneNumber)
Description copied from class: Feature
fluent setter
Overrides: withPhoneNumber
in class Container
Parameters: phoneNumber
- required parameterSee Also: Feature.setPhoneNumber(String)
withSnippet
public Document withSnippet (Snippet snippet)
Description copied from class: Feature
fluent setter
Overrides: withSnippet
in class Container
Parameters: snippet
- required parameterSee Also: Feature.setSnippet(Snippet)
withSnippetd
public Document withSnippetd (java.lang.String snippetd)
Description copied from class: Feature
fluent setter
Overrides: withSnippetd
in class Container
Parameters: snippetd
- required parameterSee Also: Feature.setSnippetd(String)
withDescription
public Document withDescription (java.lang.String description)
Description copied from class: Feature
fluent setter
Overrides: withDescription
in class Container
Parameters: description
- required parameterSee Also: Feature.setDescription(String)
withAbstractView
public Document withAbstractView (AbstractView abstractView)
Description copied from class: Feature
fluent setter
Overrides: withAbstractView
in class Container
Parameters: abstractView
- required parameterSee Also: Feature.setAbstractView(AbstractView)
withTimePrimitive
public Document withTimePrimitive (TimePrimitive timePrimitive)
Description copied from class: Feature
fluent setter
Overrides: withTimePrimitive
in class Container
Parameters: timePrimitive
- required parameterSee Also: Feature.setTimePrimitive(TimePrimitive)
withStyleUrl
public Document withStyleUrl (java.lang.String styleUrl)
Description copied from class: Feature
fluent setter
Overrides: withStyleUrl
in class Container
Parameters: styleUrl
- required parameterSee Also: Feature.setStyleUrl(String)
withStyleSelector
public Document withStyleSelector (java.util.List<StyleSelector > styleSelector)
Description copied from class: Feature
fluent setter
Overrides: withStyleSelector
in class Container
Parameters: styleSelector
- required parameterSee Also: #setStyleSelector(List)
withRegion
public Document withRegion (Region region)
Description copied from class: Feature
fluent setter
Overrides: withRegion
in class Container
Parameters: region
- required parameterSee Also: Feature.setRegion(Region)
withMetadata
public Document withMetadata (Metadata metadata)
Description copied from class: Feature
fluent setter
Overrides: withMetadata
in class Container
Parameters: metadata
- required parameterSee Also: Feature.setMetadata(Metadata)
withExtendedData
public Document withExtendedData (ExtendedData extendedData)
Description copied from class: Feature
fluent setter
Overrides: withExtendedData
in class Container
Parameters: extendedData
- required parameterSee Also: Feature.setExtendedData(ExtendedData)
withFeatureSimpleExtension
public Document withFeatureSimpleExtension (java.util.List<java.lang.Object> featureSimpleExtension)
Description copied from class: Feature
fluent setter
Overrides: withFeatureSimpleExtension
in class Container
Parameters: featureSimpleExtension
- required parameterSee Also: #setFeatureSimpleExtension(List)
withFeatureObjectExtension
public Document withFeatureObjectExtension (java.util.List<AbstractObject > featureObjectExtension)
Description copied from class: Feature
fluent setter
Overrides: withFeatureObjectExtension
in class Container
Parameters: featureObjectExtension
- required parameterSee Also: #setFeatureObjectExtension(List)
withContainerSimpleExtension
public Document withContainerSimpleExtension (java.util.List<java.lang.Object> containerSimpleExtension)
Description copied from class: Container
fluent setter
Overrides: withContainerSimpleExtension
in class Container
Parameters: containerSimpleExtension
- required parameterSee Also: #setContainerSimpleExtension(List)
withContainerObjectExtension
public Document withContainerObjectExtension (java.util.List<AbstractObject > containerObjectExtension)
Description copied from class: Container
fluent setter
Overrides: withContainerObjectExtension
in class Container
Parameters: containerObjectExtension
- required parameterSee Also: #setContainerObjectExtension(List)
clone
public Document clone ()
Overrides: clone
in class Container