org.opennms.web.element
Interface NetworkElementFactoryInterface

All Known Implementing Classes:
NetworkElementFactory

public interface NetworkElementFactoryInterface


Method Summary
 Interface[] getActiveInterfacesOnNode(int nodeId)
          getActiveInterfacesOnNode
 Interface[] getAllInterfaces()
          getAllInterfaces
 Interface[] getAllInterfaces(boolean includeSnmp)
           
 Interface[] getAllInterfacesOnNode(int nodeId)
          getAllInterfacesOnNode
 Interface[] getAllManagedIpInterfaces(boolean includeSNMP)
          getAllManagedIpInterfaces
 List<OnmsNode> getAllNodes()
          Returns all non-deleted nodes.
 List<OnmsNode> getAllNodes(int serviceId)
          getAllNodes
 Service[] getAllServices()
          getAllServices
 Interface[] getAllSnmpInterfacesOnNode(int nodeId)
          Returns all SNMP interfaces on a node
 AtInterface getAtInterface(int nodeId, String ipAddr)
           
 List<LinkInterface> getDataLinksOnInterface(int id)
          getDataLinksOnInterface
 List<LinkInterface> getDataLinksOnInterface(int nodeID, int ifindex)
          getDataLinksOnInterface
 List<LinkInterface> getDataLinksOnInterface(int nodeID, String ipaddr)
          getDataLinksOnInterface
 List<LinkInterface> getDataLinksOnNode(int nodeID)
          getDataLinksOnNode
 String getHostname(String ipAddress)
          Resolve an IP address to a DNS hostname via the database.
 Integer getIfIndex(int ipinterfaceid)
           
 Integer getIfIndex(int nodeID, String ipaddr)
           
 Interface getInterface(int ipInterfaceId)
          getInterface
 Interface getInterface(int nodeId, String ipAddress)
          getInterface
 Interface getInterface(int nodeId, String ipAddress, int ifIndex)
          getInterface
 Interface[] getInterfacesWithIfAlias(int nodeId, String ifAlias)
           
 Interface[] getInterfacesWithIpAddress(String ipAddress)
          getInterfacesWithIpAddress
 String getIpPrimaryAddress(int nodeId)
          Find the IP address of the primary SNMP interface.
 IpRouteInterface[] getIpRoute(int nodeId)
           
 Set<Integer> getLinkedNodeIdOnNode(int safeParseInt)
           
 OnmsNode getNode(int nodeId)
           
 List<Integer> getNodeIdsWithIpLike(String iplike)
          Returns all non-deleted nodes with an IP address like the rule given.
 String getNodeLabel(int nodeId)
           
 List<OnmsNode> getNodesFromPhysaddr(String atPhysAddr)
          getNodesFromPhysaddr
 List<OnmsNode> getNodesLike(String nodeLabel)
          Returns all non-deleted nodes that have the given nodeLabel substring somewhere in their nodeLabel.
 List<OnmsNode> getNodesLike(String nodeLabel, int serviceId)
          getNodesLike
 List<OnmsNode> getNodesLikeAndIpLike(String nodeLabel, String iplike, int serviceId)
          getNodesLikeAndIpLike
 List<OnmsNode> getNodesWithCategories(String[] categories, boolean onlyNodesWithDownAggregateStatus)
          getNodesWithCategories
 List<OnmsNode> getNodesWithCategories(String[] categories1, String[] categories2, boolean onlyNodesWithDownAggregateStatus)
          getNodesWithCategories
 List<OnmsNode> getNodesWithCategories(org.springframework.transaction.support.TransactionTemplate transTemplate, String[] categories1, boolean onlyNodesWithDownAggregateStatus)
          getNodesWithCategories
 List<OnmsNode> getNodesWithCategories(org.springframework.transaction.support.TransactionTemplate transTemplate, String[] categories1, String[] categories2, boolean onlyNodesWithDownAggregateStatus)
          getNodesWithCategories
 List<OnmsNode> getNodesWithIfAlias(String ifAlias)
          Returns all non-deleted nodes that contain the given string in an ifAlias
 List<OnmsNode> getNodesWithIpLike(String iplike)
           
 List<OnmsNode> getNodesWithIpLike(String iplike, int serviceId)
          getNodesWithIpLike
 List<OnmsNode> getNodesWithPhysAddr(String macAddr)
          Returns all non-deleted nodes that have the given mac.
 List<OnmsNode> getNodesWithPhysAddrAtInterface(String macAddr)
          Returns all non-deleted nodes with a MAC address like the rule given from AtInterface.
 List<OnmsNode> getNodesWithPhysAddrFromSnmpInterface(String macAddr)
          Returns all non-deleted nodes with a MAC address like the rule given from SnmpInterface.
 List<OnmsNode> getNodesWithService(int serviceId)
          Returns all non-deleted nodes that have the given service.
 Service getService(int ifServiceId)
          Return the service specified by the node identifier, IP address, and service identifier.
 Service getService(int nodeId, String ipAddress, int serviceId)
          Return the service specified by the node identifier, IP address, and service identifier.
 int getServiceIdFromName(String serviceName)
          getServiceIdFromName
 Map<Integer,String> getServiceIdToNameMap()
          getServiceIdToNameMap
 String getServiceNameFromId(int serviceId)
          getServiceNameFromId
 Map<String,Integer> getServiceNameToIdMap()
          getServiceNameToIdMap
 Service[] getServicesOnInterface(int nodeId, String ipAddress)
          getServicesOnInterface
 Service[] getServicesOnInterface(int nodeId, String ipAddress, boolean includeDeletions)
          getServicesOnInterface
 Service[] getServicesOnNode(int nodeId)
          Get the list of all services on a given node.
 Service[] getServicesOnNode(int nodeId, int serviceId)
          Get the list of all instances of a specific service on a given node.
 Interface getSnmpInterface(int nodeId, int ifIndex)
          Get interface from snmpinterface table.
 StpInterface[] getStpInterface(int nodeId)
           
 StpInterface[] getStpInterface(int nodeId, int ifIndex)
           
 StpNode[] getStpNode(int nodeId)
           
 Vlan[] getVlansOnNode(int nodeID)
           
 boolean isBridgeNode(int nodeId)
           
 boolean isParentNode(int nodeId)
          isParentNode
 boolean isRouteInfoNode(int nodeId)
           
 

Method Detail

getNodeLabel

String getNodeLabel(int nodeId)

getIpPrimaryAddress

String getIpPrimaryAddress(int nodeId)
Find the IP address of the primary SNMP interface.

Parameters:
nodeId - an int.
Returns:
An IPv4 or IPv6 address in string format or null if the node has no primary SNMP interface

getNode

OnmsNode getNode(int nodeId)

getAllNodes

List<OnmsNode> getAllNodes()
Returns all non-deleted nodes.

Returns:
an array of OnmsNode objects.

getNodesLike

List<OnmsNode> getNodesLike(String nodeLabel)
Returns all non-deleted nodes that have the given nodeLabel substring somewhere in their nodeLabel.

Parameters:
nodeLabel - a String object.
Returns:
an array of OnmsNode objects.

getNodesWithIpLike

List<OnmsNode> getNodesWithIpLike(String iplike)

getNodesWithService

List<OnmsNode> getNodesWithService(int serviceId)
Returns all non-deleted nodes that have the given service.

Parameters:
serviceId - a int.
Returns:
an array of OnmsNode objects.

getNodesWithPhysAddr

List<OnmsNode> getNodesWithPhysAddr(String macAddr)
Returns all non-deleted nodes that have the given mac.

Parameters:
macAddr - a String object.
Returns:
an array of OnmsNode objects.

getNodesWithPhysAddrAtInterface

List<OnmsNode> getNodesWithPhysAddrAtInterface(String macAddr)
Returns all non-deleted nodes with a MAC address like the rule given from AtInterface.

Parameters:
macAddr - a String object.
Returns:
an array of OnmsNode objects.

getNodesWithPhysAddrFromSnmpInterface

List<OnmsNode> getNodesWithPhysAddrFromSnmpInterface(String macAddr)
Returns all non-deleted nodes with a MAC address like the rule given from SnmpInterface.

Parameters:
macAddr - a String object.
Returns:
an array of OnmsNode objects.

getNodesWithIfAlias

List<OnmsNode> getNodesWithIfAlias(String ifAlias)
Returns all non-deleted nodes that contain the given string in an ifAlias

Parameters:
ifAlias - a String object.
Returns:
nodes the nodes with a matching ifAlias on one or more interfaces

getHostname

String getHostname(String ipAddress)
Resolve an IP address to a DNS hostname via the database. If no hostname can be found, the given IP address is returned.

Parameters:
ipAddress - a String object.
Returns:
a String object.

getInterface

Interface getInterface(int ipInterfaceId)

getInterface

Parameters:
ipInterfaceId - a int.
Returns:
a Interface object.

getInterface

Interface getInterface(int nodeId,
                       String ipAddress)

getInterface

Parameters:
nodeId - a int.
ipAddress - a String object.
Returns:
a Interface object.

getInterface

Interface getInterface(int nodeId,
                       String ipAddress,
                       int ifIndex)

getInterface

Parameters:
nodeId - a int.
ipAddress - a String object.
ifindex - a int.
Returns:
a Interface object.

getSnmpInterface

Interface getSnmpInterface(int nodeId,
                           int ifIndex)
Get interface from snmpinterface table. Intended for use with non-ip interfaces.

Parameters:
nodeId - a int.
ifIndex - a int.
Returns:
Interface

getInterfacesWithIpAddress

Interface[] getInterfacesWithIpAddress(String ipAddress)

getInterfacesWithIpAddress

Parameters:
ipAddress - a String object.
Returns:
an array of Interface objects.

getInterfacesWithIfAlias

Interface[] getInterfacesWithIfAlias(int nodeId,
                                     String ifAlias)

getAllInterfacesOnNode

Interface[] getAllInterfacesOnNode(int nodeId)

getAllInterfacesOnNode

Parameters:
nodeId - a int.
Returns:
an array of Interface objects.

getAllSnmpInterfacesOnNode

Interface[] getAllSnmpInterfacesOnNode(int nodeId)
Returns all SNMP interfaces on a node

Parameters:
nodeId - a int.
Returns:
Interface[]

getActiveInterfacesOnNode

Interface[] getActiveInterfacesOnNode(int nodeId)

getActiveInterfacesOnNode

Parameters:
nodeId - a int.
Returns:
an array of Interface objects.

getAllInterfaces

Interface[] getAllInterfaces()

getAllInterfaces

Returns:
an array of Interface objects.

getAllInterfaces

Interface[] getAllInterfaces(boolean includeSnmp)

getAllManagedIpInterfaces

Interface[] getAllManagedIpInterfaces(boolean includeSNMP)

getAllManagedIpInterfaces

Parameters:
includeSNMP - a boolean.
Returns:
an array of Interface objects.

getService

Service getService(int nodeId,
                   String ipAddress,
                   int serviceId)
Return the service specified by the node identifier, IP address, and service identifier.

Note that if there are both an active service and historically deleted services with this (nodeid, ipAddress, serviceId) key, then the active service will be returned. If there are only deleted services, then the first deleted service will be returned.

Parameters:
nodeId - a int.
ipAddress - a String object.
serviceId - a int.
Returns:
a Service object.

getService

Service getService(int ifServiceId)
Return the service specified by the node identifier, IP address, and service identifier.

Note that if there are both an active service and historically deleted services with this (nodeid, ipAddress, serviceId) key, then the active service will be returned. If there are only deleted services, then the first deleted service will be returned.

Parameters:
ifServiceId - a int.
Returns:
a Service object.

getAllServices

Service[] getAllServices()

getAllServices

Returns:
an array of Service objects.

getServicesOnInterface

Service[] getServicesOnInterface(int nodeId,
                                 String ipAddress)

getServicesOnInterface

Parameters:
nodeId - a int.
ipAddress - a String object.
Returns:
an array of Service objects.

getServicesOnInterface

Service[] getServicesOnInterface(int nodeId,
                                 String ipAddress,
                                 boolean includeDeletions)

getServicesOnInterface

Parameters:
nodeId - a int.
ipAddress - a String object.
includeDeletions - a boolean.
Returns:
an array of Service objects.

getServicesOnNode

Service[] getServicesOnNode(int nodeId)
Get the list of all services on a given node.

Parameters:
nodeId - a int.
Returns:
an array of Service objects.

getServicesOnNode

Service[] getServicesOnNode(int nodeId,
                            int serviceId)
Get the list of all instances of a specific service on a given node.

Parameters:
nodeId - a int.
serviceId - a int.
Returns:
an array of Service objects.

getServiceNameFromId

String getServiceNameFromId(int serviceId)

getServiceNameFromId

Parameters:
serviceId - a int.
Returns:
a String object.

getServiceIdFromName

int getServiceIdFromName(String serviceName)

getServiceIdFromName

Parameters:
serviceName - a String object.
Returns:
a int.

getServiceIdToNameMap

Map<Integer,String> getServiceIdToNameMap()

getServiceIdToNameMap

Returns:
a java$util$Map object.

getServiceNameToIdMap

Map<String,Integer> getServiceNameToIdMap()

getServiceNameToIdMap

Returns:
a java$util$Map object.

getNodesLikeAndIpLike

List<OnmsNode> getNodesLikeAndIpLike(String nodeLabel,
                                     String iplike,
                                     int serviceId)

getNodesLikeAndIpLike

Parameters:
nodeLabel - a String object.
iplike - a String object.
serviceId - a int.
Returns:
an array of OnmsNode objects.

getNodesLike

List<OnmsNode> getNodesLike(String nodeLabel,
                            int serviceId)

getNodesLike

Parameters:
nodeLabel - a String object.
serviceId - a int.
Returns:
an array of OnmsNode objects.

getNodesWithIpLike

List<OnmsNode> getNodesWithIpLike(String iplike,
                                  int serviceId)

getNodesWithIpLike

Parameters:
iplike - a String object.
serviceId - a int.
Returns:
an array of OnmsNode objects.

getAllNodes

List<OnmsNode> getAllNodes(int serviceId)

getAllNodes

Parameters:
serviceId - a int.
Returns:
an array of OnmsNode objects.

getNodesFromPhysaddr

List<OnmsNode> getNodesFromPhysaddr(String atPhysAddr)

getNodesFromPhysaddr

Parameters:
atPhysAddr - a String object.
Returns:
an array of OnmsNode objects.

getAtInterface

AtInterface getAtInterface(int nodeId,
                           String ipAddr)

getIpRoute

IpRouteInterface[] getIpRoute(int nodeId)

isParentNode

boolean isParentNode(int nodeId)

isParentNode

Parameters:
nodeID - a int.
Returns:
a boolean.

getDataLinksOnNode

List<LinkInterface> getDataLinksOnNode(int nodeID)

getDataLinksOnNode

Parameters:
nodeID - a int.
Returns:
an list of LinkInterface objects.
Throws:
SQLException - if any.

getDataLinksOnInterface

List<LinkInterface> getDataLinksOnInterface(int nodeID,
                                            int ifindex)

getDataLinksOnInterface

Parameters:
nodeID - a int.
ifindex - a int.
Returns:
an array of LinkInterface objects.

getDataLinksOnInterface

List<LinkInterface> getDataLinksOnInterface(int id)

getDataLinksOnInterface

Parameters:
ID - a int identifier for interface.
Returns:
an array of LinkInterface objects.

getDataLinksOnInterface

List<LinkInterface> getDataLinksOnInterface(int nodeID,
                                            String ipaddr)

getDataLinksOnInterface

Parameters:
nodeID - a int.
ipaddr - a String.
Returns:
an array of LinkInterface objects.

getNodeIdsWithIpLike

List<Integer> getNodeIdsWithIpLike(String iplike)
Returns all non-deleted nodes with an IP address like the rule given.

Parameters:
iplike - a String object.
Returns:
a List object.

getNodesWithCategories

List<OnmsNode> getNodesWithCategories(org.springframework.transaction.support.TransactionTemplate transTemplate,
                                      String[] categories1,
                                      boolean onlyNodesWithDownAggregateStatus)

getNodesWithCategories

Parameters:
transTemplate - a TransactionTemplate object.
nodeDao - a NodeDao object.
categoryDao - a CategoryDao object.
categories1 - an array of String objects.
onlyNodesWithDownAggregateStatus - a boolean.
Returns:
an array of OnmsNode objects.

getNodesWithCategories

List<OnmsNode> getNodesWithCategories(String[] categories,
                                      boolean onlyNodesWithDownAggregateStatus)

getNodesWithCategories

Parameters:
nodeDao - a NodeDao object.
categoryDao - a CategoryDao object.
categories1 - an array of String objects.
onlyNodesWithDownAggregateStatus - a boolean.
Returns:
an array of OnmsNode objects.

getNodesWithCategories

List<OnmsNode> getNodesWithCategories(org.springframework.transaction.support.TransactionTemplate transTemplate,
                                      String[] categories1,
                                      String[] categories2,
                                      boolean onlyNodesWithDownAggregateStatus)

getNodesWithCategories

Parameters:
transTemplate - a TransactionTemplate object.
nodeDao - a NodeDao object.
categoryDao - a CategoryDao object.
categories1 - an array of String objects.
categories2 - an array of String objects.
onlyNodesWithDownAggregateStatus - a boolean.
Returns:
an array of OnmsNode objects.

getNodesWithCategories

List<OnmsNode> getNodesWithCategories(String[] categories1,
                                      String[] categories2,
                                      boolean onlyNodesWithDownAggregateStatus)

getNodesWithCategories

Parameters:
nodeDao - a NodeDao object.
categoryDao - a CategoryDao object.
categories1 - an array of String objects.
categories2 - an array of String objects.
onlyNodesWithDownAggregateStatus - a boolean.
Returns:
an array of OnmsNode objects.

getLinkedNodeIdOnNode

Set<Integer> getLinkedNodeIdOnNode(int safeParseInt)
                                   throws SQLException
Throws:
SQLException

isRouteInfoNode

boolean isRouteInfoNode(int nodeId)
                        throws SQLException
Throws:
SQLException

isBridgeNode

boolean isBridgeNode(int nodeId)
                     throws SQLException
Throws:
SQLException

getStpNode

StpNode[] getStpNode(int nodeId)
                     throws SQLException
Throws:
SQLException

getStpInterface

StpInterface[] getStpInterface(int nodeId)
                               throws SQLException
Throws:
SQLException

getStpInterface

StpInterface[] getStpInterface(int nodeId,
                               int ifIndex)
                               throws SQLException
Throws:
SQLException

getVlansOnNode

Vlan[] getVlansOnNode(int nodeID)
                      throws SQLException
Throws:
SQLException

getIfIndex

Integer getIfIndex(int ipinterfaceid)

getIfIndex

Integer getIfIndex(int nodeID,
                   String ipaddr)


Copyright © 2011. All Rights Reserved.