DrawObjectLayer: Difference between revisions
Jump to navigation
Jump to search
(→) |
(→) |
||
Line 39: | Line 39: | ||
StyleXml:{Type:"inline", Value:""} | StyleXml:{Type:"inline", Value:""} | ||
} | } | ||
const layers = new Layers.ILayersrInfo={ | |||
Services:{}, | |||
Layers:[DOLayer] | |||
} | |||
const props = { | |||
"Zoom": 10, | |||
"Center": [1197567, 8380058], | |||
"Projection": 'EPSG:3857' | |||
} | |||
const mapHtmlId = "map"; | |||
const maria = new MariaCore(props, mapHtmlId) | |||
maria.SetupLayers(layers) | |||
</source> | </source> | ||
Revision as of 14:16, 26 April 2022
About
The Draw Object Layer is used to display tactical graphics served as map tiles from the draw object service.
Setup
interface IGdkDrawLayerInfo {
LayerType: "GdkDrawLayer";
Id: string;
Name?: string;
Description?: string;
Visible?: boolean;
ZoomRange?: [minZoom: number, maxZoom: number];
ParentLayerId?: string;
LogLevel?: LogLevel;
StoreId?: string;
StyleXml?: UrlOrInlineData;
FilterXml?: UrlOrInlineData;
DrawObjectServiceUri?: URL;
RenderServiceUri?: URL;
UpdateIntervalMs?: number;
}
Example
include {Layers} from "@mariateleplan/map-core"
const DOLayer = new Layers.DrawObjectLayer{
LayerType:"GdkDrawLayer",
Id:"drawobjs",
StoreId:"test",
Name:"GDK Objects",
Description:"TPG test draw object layer",
DrawObjectServiceUri:new URL("http://serviceHosterName:PORT/drawobjects/web/"),
RenderServiceUri:new URL("http://serviceHosterName:PORT/drawobjectrendering/web/"),
StyleXml:{Type:"inline", Value:""}
}
const layers = new Layers.ILayersrInfo={
Services:{},
Layers:[DOLayer]
}
const props = {
"Zoom": 10,
"Center": [1197567, 8380058],
"Projection": 'EPSG:3857'
}
const mapHtmlId = "map";
const maria = new MariaCore(props, mapHtmlId)
maria.SetupLayers(layers)