Readonly
$iThe instance of RampMap API scoped to a single Vue R4MP application.
APIScope
Protected
CLASS_Protected
CONTAINER_Protected
CONTAINER_Protected
CONTENT_Protected
CONTENT_Protected
CONTENT_Protected
NONEProtected
SIMPLEProtected
UNIQUE_The instance of Vue R4MP application controlled by this InstanceAPI.
This is just a shorthand for this.$iApi.$vApp
.
APIScope
Private
generateGiven feature attributes, return the image URL for that feature/graphic object.
object of feature attribute key value pairs
an enhanced renderer (see function enhanceRenderer)
svgcode Url to the features symbology image
getGraphicIcon
Given feature attributes, return the symbol for that feature/graphic object.
object of feature attribute key value pairs
an enhanced renderer (see function enhanceRenderer)
an ESRI Symbol object in server format
getGraphicSymbol
Private
getPrivate
listPrivate
Converts a config-supplied list of symbology to the format used by layer records.
a conversion function to wrap the supplied image into an image or an icon style symbology container
a list of config-supplied symbology items in the form of [ { text: image
can be dataURL or an actual url
an array of converted symbology symbols in the form of [ { name:
_listToSymbology
Private
mapPrivate
Our symbology engine works off of renderers. When dealing with layers with no renderers, we need to take server-side legend and convert it to a fake renderer, which lets us leverage all the existing symbology code.
legend json from an esri map server
the index of the layer in the legend we are interested in
a fake unique value renderer based off the legend
mapServerLegendToRenderer
Private
mapPrivate
Our symbology engine works off of renderers. When dealing with layers with no renderers, we need to take server-side legend and convert it to a fake renderer, which lets us leverage all the existing symbology code.
Same as mapServerLegendToRenderer function but combines all layer renderers.
legend json from an esri map server
a fake unique value renderer based off the legend
mapServerLegendToRendererAll
Orchestrator function that will:
service url (root service, not indexed endpoint)
Optional
layerIndex: string | number = undefinedthe index of the layer in the legend we are interested in. If not provided, all layers will be collapsed into a single legend
resolves in a viewer-compatible legend for the given server and layer index
mapServerToLocalLegend
Renders a supplied image as an icon-style symbology item (fitting an image inside an icon container, usually 32x32 pixels).
a image dataUrl or a regular url
[optional=null] an svg container to draw the image on; if not supplied, a new one is created
renderSymbologyIcon
Renders a supplied image as an image-style symbology item (preserving the true image dimensions).
a image dataUrl or a regular url
[optional=null] an svg container to draw the image on; if not supplied, a new one is created
renderSymbologyImage
Generate a legend object based on an ESRI renderer.
an ESRI renderer object in server JSON form
list of legend symbologies
Private
svgPrivate
Renders a specified image on an svg element. This is a helper function that wraps around async draw.image
call in the svg library.
svg element to render the image onto
image url or dataURL of the image to render
[optional = 0] width of the image
[optional = 0] height of the image
[optional = true] specifies if the image should be loaded as crossOrigin
promise resolving with the loaded image and its loader object (see svg.js http://documentup.com/wout/svg.js#image for details)
svgDrawImage
Private
symbolGenerated using TypeDoc
A base class for anything requiring access to the InstanceApi and instance of Vue app controlled by it.
Export