Options
All
  • Public
  • Public/Protected
  • All
Menu

Module Feature

JMap.Application.Feature

You can manage everything related to app features here.

Index

Functions

closeEditMenu

  • closeEditMenu(): void
  • JMap.Application.Feature.closeEditMenu

    Closes the feature edit menu if visible.

    If not visible, does nothing.

    example
    
    // close the edit menu if visible
    JMap.Application.Feature.closeEditMenu()

    Returns void

deleteByIds

  • JMap.Application.Feature.deleteByIds

    Deletes features (on the server), refreshes the layer on the map and displays a success or error message when done.

    example
    
    // delete 2 features on layer id=4
    JMap.Application.Feature.deleteByIds(4, [23, 76]).then(result => console.log("Delete result", result))

    Parameters

    • layerId: JId

      the JMap layer id

    • featureIds: JId[]

      an array of features ids

    Returns Promise<JFeatureDeleteByIdsResult>

openEditMenuById

  • openEditMenuById(layerId: JId, featureId: JId): Promise<Feature>
  • JMap.Application.Feature.openEditMenuById

    Opens the feature edit menu for a single feature.

    example
    
    // open edit menu (single feature) for layer id=5, and feature id=234
    JMap.Application.Feature.openEditMenuById(5, 234)

    Parameters

    • layerId: JId

      the JMap layer id

    • featureId: JId

      the feature id

    Returns Promise<Feature>

openEditMenuByIds

  • openEditMenuByIds(layerId: JId, featureIds: JId[]): Promise<Feature[]>
  • JMap.Application.Feature.openEditMenuByIds

    Opens the feature edit menu for multiple features.

    example
    
    // open edit menu (multiple edition) for layer id=5, and features id=234, 452 and 176
    JMap.Application.Feature.openEditMenuByIds(5, [234, 452, 176])

    Parameters

    • layerId: JId

      the JMap layer id

    • featureIds: JId[]

      an array of features ids

    Returns Promise<Feature[]>