|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.opennms.web.map.db.ManagerDefaultImpl
public class ManagerDefaultImpl
ManagerDefaultImpl class.
| Constructor Summary | |
|---|---|
ManagerDefaultImpl()
Manage Maps using default implementation of Factory and Manager |
|
| Method Summary | |
|---|---|
VMap |
addElements(VMap map,
List<VElement> velems)
addElements |
boolean |
checkCommandExecution()
|
void |
clearMap()
clearMap |
void |
closeMap()
closeMap |
void |
deleteAllMapElements()
delete all defined sub maps in existent maps |
void |
deleteAllNodeElements()
delete all defined node elements in existent maps |
void |
deleteMap()
deleteMap |
void |
deleteMap(int mapId)
delete the map with identifier id |
void |
deleteMap(VMap map)
delete the map in input |
void |
deleteMaps(int[] maps)
delete the maps with the identifiers in input |
void |
deleteMaps(VMap[] maps)
delete the maps in input |
String |
execCommand(Command command)
ExecCommand |
boolean |
foundLoopOnMaps(VMap parentMap,
int mapId)
foundLoopOnMaps |
VMapInfo[] |
getAllMapMenus()
Get all defined maps. |
VMap[] |
getAllMaps(boolean refreshElems)
Get all defined maps. |
Command |
getCommand(String id)
|
Manager |
getDataAccessManager()
getDataAccessManager |
DataSourceInterface |
getDataSource()
Getter for the field dataSource. |
Manager |
getDbManager()
Getter for the field dbManager. |
VMapInfo |
getDefaultMapsMenu(String user)
get the default map for specified user in input if exists null otherwise |
List<VElementInfo> |
getElementInfo()
getElementInfo |
String |
getFilter()
Getter for the field filter. |
GroupDao |
getGroupDao()
getGroupDao |
VMapInfo |
getMapMenu(int mapId)
getMapMenu |
VMap[] |
getMapsByName(String mapName,
boolean refreshElems)
Take the maps with name in input and return them in VMap[] form. |
VMap[] |
getMapsLike(String likeLabel,
boolean refreshElems)
Take the maps with label like the pattern in input and return them in VMap[] form. |
VMapInfo[] |
getMapsMenuByName(String mapName)
Take the maps with name in input and return them in MapMenu[] form. |
List<VMapInfo> |
getMapsMenuTreeByName(String mapName)
Take all the maps in the tree of maps considering the with name in input as the root of the tree. |
MapPropertiesFactory |
getMapsPropertiesFactory()
Getter for the field mapsPropertiesFactory. |
Set<Integer> |
getNodeidsOnElement(VElement velem)
recursively gets all nodes contained by elem and its submaps (if elem is a map) |
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,
int x,
int y)
Create a new VElement with the identifier setted to id. |
VElement |
newElement(int mapId,
int elementId,
String type,
String iconname)
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. |
VElement |
newElement(int elementId,
String type,
int x,
int y)
newElement |
VMap |
newMap(String owner,
String userModifies,
int width,
int height)
Create a new VMap and return it |
VMap |
openMap()
openMap |
VMap |
openMap(int id,
boolean refreshElems)
Take the map with id in input and return it in VMap form. |
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> elems)
searchMap |
void |
setDataSource(DataSourceInterface dataSource)
Setter for the field dataSource. |
void |
setDbManager(Manager dbManager)
Setter for the field dbManager. |
void |
setFilter(String filter)
Setter for the field filter. |
void |
setGroupDao(GroupDao groupDao)
setGroupDao |
void |
setMapsPropertiesFactory(MapPropertiesFactory mapsPropertiesFactory)
Setter for the field mapsPropertiesFactory. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ManagerDefaultImpl()
throws MapsException
MapsException - if any.| Method Detail |
|---|
public String getFilter()
Getter for the field filter.
String object.public void setFilter(String filter)
Setter for the field filter.
filter - a String object.public DataSourceInterface getDataSource()
Getter for the field dataSource.
DataSourceInterface object.public void setDataSource(DataSourceInterface dataSource)
Setter for the field dataSource.
dataSource - a DataSourceInterface object.public Manager getDbManager()
Getter for the field dbManager.
Manager object.public void setDbManager(Manager dbManager)
Setter for the field dbManager.
dbManager - a Manager object.public MapPropertiesFactory getMapsPropertiesFactory()
Getter for the field mapsPropertiesFactory.
public void setMapsPropertiesFactory(MapPropertiesFactory mapsPropertiesFactory)
Setter for the field mapsPropertiesFactory.
mapsPropertiesFactory - a org$opennms$web$map$config$MapPropertiesFactory object.
public VMap openMap()
throws MapNotFoundException
openMap
openMap in interface ManagerVMap object.
MapNotFoundException - if any.
public void clearMap()
throws MapNotFoundException,
MapsException
clearMap
clearMap in interface ManagerMapNotFoundException - if any.
MapsException - if any.
public void deleteMap()
throws MapNotFoundException,
MapsException
deleteMap
deleteMap in interface ManagerMapNotFoundException - if any.
MapsException - if any.public void closeMap()
closeMap
closeMap in interface Manager
public VMap openMap(int id,
String user,
boolean refreshElems)
throws MapsManagementException,
MapNotFoundException,
MapsException
openMap in interface Managerid - a int.user - a String object.refreshElems - says if refresh the map's elements
MapNotFoundException - if any.
MapsException - if any.
MapsManagementException
public VMap newMap(String owner,
String userModifies,
int width,
int height)
newMap in interface Managerowner - a String object.userModifies - a String object.width - a int.height - a int.
public VMap openMap(int id,
boolean refreshElems)
throws MapsManagementException,
MapNotFoundException,
MapsException
id - a int.refreshElems - says if refresh the map's elements
MapsException - if any.
MapsManagementException - if any.
MapNotFoundException - if any.
public VMapInfo getMapMenu(int mapId)
throws MapNotFoundException,
MapsException
getMapMenu
mapId - a int.
VMapInfo object.
MapNotFoundException - if any.
MapsException - if any.
public VMap[] getMapsLike(String likeLabel,
boolean refreshElems)
throws MapsException
refreshElems - says if refresh map's elementslikeLabel - a String object.
MapsException - if any.
public VMap[] getMapsByName(String mapName,
boolean refreshElems)
throws MapNotFoundException,
MapsException
mapName - a String object.refreshElems - a boolean.
MapsException - if any.
MapNotFoundException - if any.
public VMap[] getAllMaps(boolean refreshElems)
throws MapNotFoundException,
MapsException
refreshElems - says if refresh maps' elements
MapsException - if any.
MapNotFoundException - if any.
public VMapInfo[] getAllMapMenus()
throws MapsException
MapsException - if any.
public VMapInfo[] getMapsMenuByName(String mapName)
throws MapNotFoundException,
MapsException
mapName - a String object.
MapsException - if any.
MapNotFoundException - if any.
public VMapInfo getDefaultMapsMenu(String user)
throws MapsException
getDefaultMapsMenu in interface Manageruser - a String object.
MapsException - if any.
public List<VMapInfo> getVisibleMapsMenu(String user)
throws MapsException
getVisibleMapsMenu in interface Manageruser - a String object.
MapsException - if any.
public List<VMapInfo> getMapsMenuTreeByName(String mapName)
throws MapNotFoundException,
MapsException
mapName - a String object.
MapsException - if any.
MapNotFoundException - if any.
public VElement newElement(int mapId,
int elementId,
String type,
int x,
int y)
throws MapsException
mapId - a int.elementId - a int.type - the node typex - a int.y - a int.
MapsException - if any.
public VElement newElement(int elementId,
String type,
int x,
int y)
throws MapsException
newElement
elementId - a int.type - a String object.x - a int.y - a int.
VElement object.
MapsException - if any.
public VElement newElement(int mapId,
int elementId,
String type)
throws MapsException
newElement in interface ManagermapId - a int.elementId - a int.type - the node type
VElement object.
MapsException - if any.
public VElement newElement(int mapId,
int elementId,
String type,
String iconname,
int x,
int y)
throws MapsException
newElement in interface ManagermapId - a int.elementId - a int.type - the node typeiconname - a String object.x - position on the x axisy - position on the y axis
MapsException - if any.
public VElement newElement(int mapId,
int elementId,
String type,
String iconname)
throws MapsException
mapId - a int.elementId - a int.type - the node typeiconname - a String object.
MapsException - if any.
public void deleteMap(VMap map)
throws MapsException,
MapNotFoundException
map - to delete
MapsException - if an error occour deleting map, MapNotFoundException if
the map to delete doesn't exist.
MapNotFoundException - if any.
public void deleteMap(int mapId)
throws MapsException
mapId - a int.
MapsException - if any.
public void deleteMaps(VMap[] maps)
throws MapsException
maps - to delete
MapsException - if any.
public void deleteMaps(int[] maps)
throws MapsException
maps - an array of int.
MapsException - if any.
public int save(VMap map)
throws MapsException
save in interface Managermap - to save
MapsException - if any.
public void deleteAllNodeElements()
throws MapsException
MapsException - if any.
public void deleteAllMapElements()
throws MapsException
MapsException - if any.
public VMap reloadMap(VMap map)
throws MapsException
reloadMap in interface Managermap - a VMap object.
MapsException - if any.
public VMap refreshMap(VMap map)
throws MapsException
refreshMap
refreshMap in interface Managermap - a VMap object.
VMap object.
MapsException - if any.
public boolean foundLoopOnMaps(VMap parentMap,
int mapId)
throws MapsException
foundLoopOnMaps
foundLoopOnMaps in interface ManagerparentMap - a VMap object.mapId - a int.
MapsException - if any.
public Set<Integer> getNodeidsOnElement(VElement velem)
throws MapsException
velem - a VElement object.
Set object.
MapsException - if any.
public List<VElementInfo> getElementInfo()
throws MapsException
getElementInfo
getElementInfo in interface ManagerList object.
MapsException - if any.public Manager getDataAccessManager()
getDataAccessManager
Manager object.public GroupDao getGroupDao()
getGroupDao
GroupDao object.public void setGroupDao(GroupDao groupDao)
setGroupDao
groupDao - a GroupDao object.
public VMap searchMap(String owner,
String userModifies,
int width,
int height,
List<VElement> elems)
throws MapsException
searchMap
searchMap in interface Managerowner - a String object.userModifies - a String object.width - a int.height - a int.elems - a List object.
VMap object.
MapsException - if any.
public Map<String,Set<Integer>> getNodeLabelToMaps(String user)
throws MapsException
getNodeLabelToMaps in interface Manageruser - a String object.
MapsException - if any.
public VProperties getProperties(boolean isUserAdmin)
throws MapsException
getProperties
getProperties in interface ManagerisUserAdmin - a boolean.
VProperties object.
MapsException - if any.
public VMap addElements(VMap map,
List<VElement> velems)
throws MapsException
addElements
addElements in interface Managermap - a VMap object.velems - a List object.
VMap object.
MapsException - if any.
public void reloadConfig()
throws MapsException
reloadConfig
reloadConfig in interface ManagerMapsException - if any.public String execCommand(Command command)
ManagerExecCommand
execCommand in interface Managerpublic Command getCommand(String id)
getCommand in interface Managerpublic void removeCommand(String id)
removeCommand in interface Managerpublic boolean checkCommandExecution()
checkCommandExecution in interface Manager
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||