org.opennms.web.map.view
Interface Manager

All Known Implementing Classes:
ManagerDefaultImpl

public interface Manager

Manager interface.

Since:
1.8.1
Version:
$Id: $
Author:
maurizio, antonio

Method Summary
 VMap addElements(VMap map, List<VElement> velems)
          addElements
 boolean checkCommandExecution()
           
 void clearMap()
          clearMap
 void closeMap()
          Close a VMap previusly opened.
 void deleteMap()
          delete the map current map
 String execCommand(Command command)
           ExecCommand
 boolean foundLoopOnMaps(VMap parentMap, int mapId)
          foundLoopOnMaps
 Command getCommand(String id)
           
 VMapInfo getDefaultMapsMenu(String user)
          get the default map for specified user in input if exists null otherwise
 List<VElementInfo> getElementInfo()
          getElementInfo
 Map<String,Set<Integer>> getNodeLabelToMaps(String user)
          Get a Map of nodelabel to the container mapids.
 VProperties getProperties(boolean isUserAdmin)
          getProperties
 List<VMapInfo> getVisibleMapsMenu(String user)
          gets all visible maps for user in input
 VElement newElement(int mapid, int elementId, String type)
          Create a new (not child) empty Submap with the identifier setted to id.
 VElement newElement(int mapId, int elementId, String type, String iconname, int x, int y)
          Create a new (not child) empty Submap with the identifier setted to id.
 VMap newMap(String owner, String userModifies, int width, int height)
          Create a new VMap and return it
 VMap openMap()
          openMap
 VMap openMap(int id, String user, boolean refreshElems)
          Take the map with id in input and return it in VMap form.
 VMap refreshMap(VMap map)
          refreshMap
 void reloadConfig()
          reloadConfig
 VMap reloadMap(VMap map)
          Refreshs avail,severity and status of the map in input and its elements
 void removeCommand(String id)
           
 int save(VMap map)
          save the map in input
 VMap searchMap(String owner, String userModifies, int width, int height, List<VElement> velems)
          searchMap
 

Method Detail

newMap

VMap newMap(String owner,
            String userModifies,
            int width,
            int height)
Create a new VMap and return it

Parameters:
owner - a String object.
userModifies - a String object.
width - a int.
height - a int.
Returns:
the new VMap

closeMap

void closeMap()
Close a VMap previusly opened.


openMap

VMap openMap()
             throws MapNotFoundException

openMap

Returns:
the default VMap, if exists
Throws:
MapsException - if any.
MapNotFoundException - if any.

openMap

VMap openMap(int id,
             String user,
             boolean refreshElems)
             throws MapNotFoundException,
                    MapsException
Take the map with id in input and return it in VMap form.

Parameters:
id - a int.
user - a String object.
refreshElems - says if refresh the map's elements
Returns:
the VMap with identifier id
Throws:
MapsException - if any.
MapNotFoundException - if any.

clearMap

void clearMap()
              throws MapNotFoundException,
                     MapsException

clearMap

Throws:
MapNotFoundException - if any.
MapsException - if any.

getVisibleMapsMenu

List<VMapInfo> getVisibleMapsMenu(String user)
                                  throws MapsException
gets all visible maps for user in input

Parameters:
user - a String object.
Returns:
a List of MapMenu objects.
Throws:
MapsException - if any.

getDefaultMapsMenu

VMapInfo getDefaultMapsMenu(String user)
                            throws MapsException
get the default map for specified user in input if exists null otherwise

Parameters:
user - a String object.
Returns:
a MapMenu object.
Throws:
MapsException - if any.

newElement

VElement newElement(int mapid,
                    int elementId,
                    String type)
                    throws MapsException
Create a new (not child) empty Submap with the identifier setted to id.

Parameters:
elementId - a int.
type - the node type
mapid - a int.
Returns:
a VElement object.
Throws:
MapsException - if any.

newElement

VElement newElement(int mapId,
                    int elementId,
                    String type,
                    String iconname,
                    int x,
                    int y)
                    throws MapsException
Create a new (not child) empty Submap with the identifier setted to id.

Parameters:
mapId - a int.
elementId - a int.
type - the node type
x - position on the x axis
y - position on the y axis
iconname - a String object.
Returns:
the new VElement
Throws:
MapsException - if any.

deleteMap

void deleteMap()
               throws MapsException,
                      MapNotFoundException
delete the map current map

Throws:
MapsException - if an error occour deleting map, MapNotFoundException if the map to delete doesn't exist.
MapNotFoundException - if any.

save

int save(VMap map)
         throws MapsException
save the map in input

Parameters:
map - to save
Returns:
a int.
Throws:
MapsException - if any.

refreshMap

VMap refreshMap(VMap map)
                throws MapsException

refreshMap

Parameters:
map - a VMap object.
Returns:
a VMap object.
Throws:
MapsException - if any.

reloadMap

VMap reloadMap(VMap map)
               throws MapsException
Refreshs avail,severity and status of the map in input and its elements

Parameters:
map - a VMap object.
Returns:
the map refreshed
Throws:
MapsException - if any.

foundLoopOnMaps

boolean foundLoopOnMaps(VMap parentMap,
                        int mapId)
                        throws MapsException

foundLoopOnMaps

Parameters:
parentMap - a VMap object.
mapId - a int.
Returns:
a boolean.
Throws:
MapsException - if any.

getElementInfo

List<VElementInfo> getElementInfo()
                                  throws MapsException

getElementInfo

Returns:
a List object.
Throws:
MapsException - if any.

getNodeLabelToMaps

Map<String,Set<Integer>> getNodeLabelToMaps(String user)
                                            throws MapsException
Get a Map of nodelabel to the container mapids.

Parameters:
user - a String object.
Returns:
a java$util$Map object.
Throws:
MapsException - if any.

searchMap

VMap searchMap(String owner,
               String userModifies,
               int width,
               int height,
               List<VElement> velems)
               throws MapsException

searchMap

Parameters:
owner - a String object.
userModifies - a String object.
width - a int.
height - a int.
velems - a List object.
Returns:
a VMap object.
Throws:
MapsException - if any.

getProperties

VProperties getProperties(boolean isUserAdmin)
                          throws MapsException

getProperties

Parameters:
isUserAdmin - a boolean.
Returns:
a VProperties object.
Throws:
MapsException - if any.

addElements

VMap addElements(VMap map,
                 List<VElement> velems)
                 throws MapsException

addElements

Parameters:
map - a VMap object.
velems - a List object.
Returns:
a VMap object.
Throws:
MapsException - if any.

reloadConfig

void reloadConfig()
                  throws MapsException

reloadConfig

Throws:
MapsException - if any.

execCommand

String execCommand(Command command)

ExecCommand


getCommand

Command getCommand(String id)

removeCommand

void removeCommand(String id)

checkCommandExecution

boolean checkCommandExecution()


Copyright © 2011. All Rights Reserved.