public class Link extends Object implements Cloneable
specifies the location of any of the following:
If the file specified in
KML files fetched by network links Image files used in any Overlay (the
Specifies the URL of the website containing this KML or KMZ file. Be sure to include the namespace for this element in any KML file that uses it: xmlns:atom="http://www.w3.org/2005/Atom" (see the sample that follows).
Specifies the file to load and optional refresh parameters. See .
The element replaces the
The file is conditionally loaded and refreshed, depending on the refresh parameters
supplied here. Two different sets of refresh parameters can be specified: one set
is based on time (
Tip: To display the top-level Folder or Document within a Network Link in the List View, assign an ID to the Folder or Document. Without this ID, only the child object names are displayed in the List View.
When a file is fetched, the URL that is sent to the server is composed of three pieces of information:
the href (Hypertext Reference) that specifies the file to load. an arbitrary format
string that is created from (a) parameters that you specify in the
<Link id="ID">
<!-- specific to Link -->
<href>...</href> <!-- string -->
<refreshMode>onChange</refreshMode>
<!-- refreshModeEnum: onChange, onInterval, or onExpire -->
<refreshInterval>4</refreshInterval> <!-- float -->
<viewRefreshMode>never</viewRefreshMode>
<!-- viewRefreshModeEnum: never, onStop, onRequest, onRegion -->
<viewRefreshTime>4</viewRefreshTime> <!-- float -->
<viewBoundScale>1</viewBoundScale> <!-- float -->
<viewFormat>BBOX=[bboxWest],[bboxSouth],[bboxEast],[bboxNorth]</viewFormat>
<!-- string -->
<httpQuery>...</httpQuery> <!-- string -->
</Link>
Extends:| Modifier and Type | Field and Description |
|---|---|
protected String |
href
|
protected String |
hreflang |
protected String |
length |
protected String |
rel |
protected String |
title |
protected String |
type |
| Constructor and Description |
|---|
Link(String href)
Value constructor with only mandatory fields
|
| Modifier and Type | Method and Description |
|---|---|
Link |
clone() |
boolean |
equals(Object obj) |
String |
getHref() |
String |
getHreflang() |
String |
getLength() |
String |
getRel() |
String |
getTitle() |
String |
getType() |
int |
hashCode() |
void |
setHref(String value) |
void |
setHreflang(String value) |
void |
setLength(String value) |
void |
setRel(String value) |
void |
setTitle(String value) |
void |
setType(String value) |
Link |
withHreflang(String hreflang)
fluent setter
|
Link |
withLength(String length)
fluent setter
|
Link |
withRel(String rel)
fluent setter
|
Link |
withTitle(String title)
fluent setter
|
Link |
withType(String type)
fluent setter
|
protected String href
A URL (either an HTTP address or a local file specification). When the parent of
is a NetworkLink,
An HTTP address or a local file specification used to load an icon.
Specifies the URI of the image used in the List View for the Feature.
protected String rel
protected String type
protected String hreflang
protected String title
protected String length
public Link(String href)
href - required parameterpublic void setHreflang(String value)
value - allowed object is
Stringhreflangpublic void setTitle(String value)
value - allowed object is
Stringtitlepublic void setLength(String value)
value - allowed object is
Stringlengthpublic Link withRel(String rel)
rel - required parametersetRel(String)public Link withType(String type)
type - required parametersetType(String)public Link withHreflang(String hreflang)
hreflang - required parametersetHreflang(String)public Link withTitle(String title)
title - required parametersetTitle(String)public Link withLength(String length)
length - required parametersetLength(String)Copyright © 2014 Micromata GmbH. All rights reserved.