Function
Static Public Summary | ||
public |
bundleEs2015Multiple(fileArray: Array<Array<string>>, production: boolean): * make multiple bundles |
|
public |
calculateExtent(layers: Array<LayerBaseVector> | Array<ol.layer.Vector> | LayerBaseVector | ol.layer.Vector | *): ol.Extent | Array<number> | * |
|
public |
dateToYyyyMmDdHh000(dte: Date): string Given a date return a string in the format YYYYmmdd_hh0000 |
|
public |
dateToYyyyMmDdHhMmSs(dte: Date): string Given a date return a string in the format YYYY-mm-dd hh:MM:SS |
|
public |
definedAndNotNull(input: *): boolean check if the input is defined and not null |
|
public |
fitToMap(layers: Array<LayerBaseVector> | Array<ol.layer.Vector> | LayerBaseVector | ol.layer.Vector, mp: ol.Map, zoomOut: number | undefined) given one or an array of layers, fit to the map |
|
public |
|
|
public |
hexAlphaToRgbOrRgba(hexString: string, alphaVal: number): string Convert hex string to RGB or RGBA string |
|
public |
keyValPairs(obj: object): Array<keyValuePair> iterate over the key value pairs of an object |
|
public |
makeBlueGreenRedGradient(minVal: number, maxVal: number, flipColors: boolean): colorLookupByNumber Make a blue green red gradient |
|
public |
makeBlueGreenRedGradientZScore(median: number, stdDev: number, flipColors: boolean): colorLookupByNumber Create a function that will return colors based on a gradient |
|
public |
makeFeatureServiceLegendAndSymbol(esriResponse: object): styleAndLegend |
|
public |
guids are used to uniquely identify groups and features |
|
public |
makeMapServiceLegend(esriResponse: object): string make map service legent |
|
public |
overflowScroll($table: jQuery, $tableContainer: jQuery, options: object) |
|
public |
processLessFile(inputFile: string, outputFile: string): * convert less file |
|
public |
propertiesZoomStyle(styleFunc: propertiesZoomStyle | *): function | * wrapper to define a style function by properties and zoom level |
|
public |
create a namespace on the gv object |
|
public |
Sets up a map with some default parameters and initializes mapMove and mapPopup |
|
public |
quickMapBase(options: object): ol.Map Sets up a map with some default parameters and initializes mapMove and mapPopup |
|
public |
quickMapMulti(options: object): quickMapMultiReturn Sets up a map with some default parameters and initializes mapMove and mapPopup |
|
public |
resolutionToZoom(resolution: number): number | * Get resolution from the zoom level |
|
public |
responsiveScroll($table: jQuery, $responsiveContainer: jQuery, options: object) |
|
public |
converts an RGB string to hex |
|
public |
adds alpha value to rgb string 'rgb(r, b, g)', returns 'rgba(r, g, b, a)' |
|
public |
undefinedOrNull(input: *): boolean check if the input is undefined or null |
|
public |
windowScroll($table: jQuery, options: object) implement the default window scroll |
|
public |
zoomToResolution(zoomLevel: number): number | * Get the resolution given the zoom level |
Static Public
public bundleEs2015Multiple(fileArray: Array<Array<string>>, production: boolean): * source
import {bundleEs2015Multiple} from 'webmapsjs/src/gulp-helpers.js'
make multiple bundles
Return:
* | output stream |
public calculateExtent(layers: Array<LayerBaseVector> | Array<ol.layer.Vector> | LayerBaseVector | ol.layer.Vector | *): ol.Extent | Array<number> | * source
import {calculateExtent} from 'webmapsjs/src/olHelpers/extentUtil.js'
Params:
Name | Type | Attribute | Description |
layers | Array<LayerBaseVector> | Array<ol.layer.Vector> | LayerBaseVector | ol.layer.Vector | * | array of layers or single |
public dateToYyyyMmDdHh000(dte: Date): string source
import {dateToYyyyMmDdHh000} from 'webmapsjs/src/util/dateConvert.js'
Given a date return a string in the format YYYYmmdd_hh0000
Params:
Name | Type | Attribute | Description |
dte | Date | the input date |
public dateToYyyyMmDdHhMmSs(dte: Date): string source
import {dateToYyyyMmDdHhMmSs} from 'webmapsjs/src/util/dateConvert.js'
Given a date return a string in the format YYYY-mm-dd hh:MM:SS
Params:
Name | Type | Attribute | Description |
dte | Date | to convert |
public definedAndNotNull(input: *): boolean source
import {definedAndNotNull} from 'webmapsjs/src/util/checkDefined.js'
check if the input is defined and not null
Params:
Name | Type | Attribute | Description |
input | * | input pointer |
public fitToMap(layers: Array<LayerBaseVector> | Array<ol.layer.Vector> | LayerBaseVector | ol.layer.Vector, mp: ol.Map, zoomOut: number | undefined) source
import {fitToMap} from 'webmapsjs/src/olHelpers/extentUtil.js'
given one or an array of layers, fit to the map
Params:
Name | Type | Attribute | Description |
layers | Array<LayerBaseVector> | Array<ol.layer.Vector> | LayerBaseVector | ol.layer.Vector | array of layers or single |
|
mp | ol.Map | the map to fit |
|
zoomOut | number | undefined |
|
levels to zoom out after fit |
public hexAlphaToRgbOrRgba(hexString: string, alphaVal: number): string source
import {hexAlphaToRgbOrRgba} from 'webmapsjs/src/util/colors.js'
Convert hex string to RGB or RGBA string
public keyValPairs(obj: object): Array<keyValuePair> source
import {keyValPairs} from 'webmapsjs/src/util/objectHelpers.js'
iterate over the key value pairs of an object
Params:
Name | Type | Attribute | Description |
obj | object | the input object |
public makeBlueGreenRedGradient(minVal: number, maxVal: number, flipColors: boolean): colorLookupByNumber source
import {makeBlueGreenRedGradient} from 'webmapsjs/src/util/colors.js'
Make a blue green red gradient
public makeBlueGreenRedGradientZScore(median: number, stdDev: number, flipColors: boolean): colorLookupByNumber source
import {makeBlueGreenRedGradientZScore} from 'webmapsjs/src/util/colors.js'
Create a function that will return colors based on a gradient
public makeFeatureServiceLegendAndSymbol(esriResponse: object): styleAndLegend source
import {makeFeatureServiceLegendAndSymbol} from 'webmapsjs/src/olHelpers/esriToOlStyle.js'
Params:
Name | Type | Attribute | Description |
esriResponse | object | layer info |
public makeGuid(): string source
import makeGuid from 'webmapsjs/src/util/makeGuid.js'
guids are used to uniquely identify groups and features
public makeMapServiceLegend(esriResponse: object): string source
import {makeMapServiceLegend} from 'webmapsjs/src/olHelpers/esriToOlStyle.js'
make map service legent
Params:
Name | Type | Attribute | Description |
esriResponse | object | layer info |
public overflowScroll($table: jQuery, $tableContainer: jQuery, options: object) source
import {overflowScroll} from 'webmapsjs/src/jquery/floatthead.js'
public processLessFile(inputFile: string, outputFile: string): * source
import {processLessFile} from 'webmapsjs/src/gulp-helpers.js'
convert less file
Return:
* | stream |
public propertiesZoomStyle(styleFunc: propertiesZoomStyle | *): function | * source
import propertiesZoomStyle from 'webmapsjs/src/olHelpers/propertiesZoomStyle.js'
wrapper to define a style function by properties and zoom level
Params:
Name | Type | Attribute | Description |
styleFunc | propertiesZoomStyle | * | style function |
public provide(namespace: string): object source
import provide from 'webmapsjs/src/util/provide.js'
create a namespace on the gv object
Params:
Name | Type | Attribute | Description |
namespace | string | to create |
public quickMap(options: object): ol.Map source
import quickMap from 'webmapsjs/src/olHelpers/quickMap.js'
Sets up a map with some default parameters and initializes mapMove and mapPopup
Params:
Name | Type | Attribute | Description |
options | object |
|
config options |
options.divId | string |
|
map div id |
options.center | object |
|
center config object |
options.center.x | number |
|
center x, web mercator x or lon |
options.center.y | number |
|
center y, web mercator y or lat |
options.zoom | number |
|
zoom level |
options.minZoom | number |
|
min zoom |
options.maxZoom | number |
|
max zoom |
options.baseSwitcher | boolean |
|
if add base map switcher |
options.fullScreen | boolean |
|
if add base map switcher |
Return:
ol.Map | the ol map |
public quickMapBase(options: object): ol.Map source
import quickMapBase from 'webmapsjs/src/olHelpers/quickMapBase.js'
Sets up a map with some default parameters and initializes mapMove and mapPopup
Params:
Name | Type | Attribute | Description |
options | object |
|
config options |
options.divId | string |
|
map div id |
options.center | object |
|
center config object |
options.center.x | number |
|
center x, web mercator x or lon |
options.center.y | number |
|
center y, web mercator y or lat |
options.zoom | number |
|
zoom level |
options.minZoom | number |
|
min zoom |
options.maxZoom | number |
|
max zoom |
options.baseSwitcher | boolean |
|
if add base map switcher |
options.fullScreen | boolean |
|
if add base map switcher |
Return:
ol.Map | the ol map |
public quickMapMulti(options: object): quickMapMultiReturn source
import quickMapMulti from 'webmapsjs/src/olHelpers/quickMapMulti.js'
Sets up a map with some default parameters and initializes mapMove and mapPopup
Params:
Name | Type | Attribute | Description |
options | object |
|
config options |
options.divId | string |
|
map div id |
options.center | object |
|
center config object |
options.center.x | number |
|
center x, web mercator x or lon |
options.center.y | number |
|
center y, web mercator y or lat |
options.zoom | number |
|
zoom level |
options.minZoom | number |
|
min zoom |
options.maxZoom | number |
|
max zoom |
options.baseSwitcher | boolean |
|
if add base map switcher |
options.fullScreen | boolean |
|
if add base map switcher |
public resolutionToZoom(resolution: number): number | * source
import {resolutionToZoom} from 'webmapsjs/src/olHelpers/zoomResolutionConvert.js'
Get resolution from the zoom level
Params:
Name | Type | Attribute | Description |
resolution | number | the resolution |
public responsiveScroll($table: jQuery, $responsiveContainer: jQuery, options: object) source
import {responsiveScroll} from 'webmapsjs/src/jquery/floatthead.js'
public rgb2hex(rgb: string): string source
import {rgb2hex} from 'webmapsjs/src/util/colors.js'
converts an RGB string to hex
Params:
Name | Type | Attribute | Description |
rgb | string | rgb color |
public rgbToRgba(rgb: string, alpha: number): string source
import {rgbToRgba} from 'webmapsjs/src/util/colors.js'
adds alpha value to rgb string 'rgb(r, b, g)', returns 'rgba(r, g, b, a)'
public undefinedOrNull(input: *): boolean source
import {undefinedOrNull} from 'webmapsjs/src/util/checkDefined.js'
check if the input is undefined or null
Params:
Name | Type | Attribute | Description |
input | * | input pointer |
public windowScroll($table: jQuery, options: object) source
import {windowScroll} from 'webmapsjs/src/jquery/floatthead.js'
implement the default window scroll