import {SourceServerVector} from 'guide4you/src/sources/SourceServerVector.js'
SourceServerVector
Extends:
Direct Subclass:
A custom Source class handling Vector Sources.
Let you set the loading loadingStrategy, if a proxy is used and you should specify in which format it comes in.
This class defines a custom loader function which makes it possible to use different loading strategies.
Constructor Summary
Public Constructor | ||
public |
constructor(options: SourceServerVectorOptions) |
Member Summary
Public Members | ||
public |
|
|
public |
format_: * |
|
public |
localised_: * |
|
public |
|
Protected Members | ||
protected |
urlTemplate: URL |
Private Members | ||
private |
indicates if the source needs to be emptied |
|
private |
|
|
private |
|
|
private |
|
|
private |
|
|
private |
urlProjection_: module:ol/proj~ProjectionLike |
Method Summary
Public Methods | ||
public |
addProxyToHrefTags(text: HTMLElement): HTMLElement makes all urls in href-tags inside of a xmlDocument use the proxy address. |
|
public |
getUrlTemplate(): URL |
|
public |
|
|
public |
setRefresh(refresh: number) This sets the refresh rate. |
|
public |
setUrlTemplate(urlTemplate: URL) |
Public Constructors
public constructor(options: SourceServerVectorOptions) source
Params:
Name | Type | Attribute | Description |
options | SourceServerVectorOptions |
|
Public Members
public format_: * source
public localised_: * source
public refreshTimeoutId_: * source
Protected Members
protected urlTemplate: URL source
Private Members
private urlProjection_: module:ol/proj~ProjectionLike source
Public Methods
public addProxyToHrefTags(text: HTMLElement): HTMLElement source
makes all urls in href-tags inside of a xmlDocument use the proxy address. this function needs to extended with all Tags which could contain urls
Params:
Name | Type | Attribute | Description |
text | HTMLElement | an xml-Document |
Return:
HTMLElement | the xmlDocument |
public loader(extent: module:ol/extent~Extent, resolution: number, projection: module:ol/proj~Projection) source
Params:
Name | Type | Attribute | Description |
extent | module:ol/extent~Extent | ||
resolution | number | ||
projection | module:ol/proj~Projection |
public setRefresh(refresh: number) source
This sets the refresh rate. A value of 0 or smaller turns refresh off.
Params:
Name | Type | Attribute | Description |
refresh | number |
public setUrlTemplate(urlTemplate: URL) source
Params:
Name | Type | Attribute | Description |
urlTemplate | URL |