OpenNMS API 1.2.9

## org.opennms.netmgt.mock
Class MockQueryManager

    java.lang.Object
      org.opennms.netmgt.mock.MockQueryManager

All Implemented Interfaces:
  QueryManager

public class MockQueryManager
extends java.lang.Object
implements QueryManager

Field Summary
`private MockNetwork` `m_network` Comment for `m_network`

Constructor Summary
`MockQueryManager(MockNetwork network)`

Method Summary
`boolean` `activeServiceExists(java.lang.String whichEvent, int nodeId, java.lang.String ipAddr, java.lang.String serviceName)`
`void` `buildServiceNameToIdMaps(java.util.Map nameToId, java.util.Map idToName)`
`java.util.List` `getActiveServiceIdsForInterface(java.lang.String ipaddr)`
`java.util.List` `getInterfacesWithService(java.lang.String svcName)`
`int` `getNodeIDForInterface(java.lang.String ipaddr)`
`java.lang.String` `getNodeLabel(int nodeId)`
`int` `getServiceCountForInterface(java.lang.String ipaddr)`
`java.util.Date` `getServiceLostDate(int nodeId, java.lang.String ipAddr, java.lang.String svcName, int serviceId)`
`void` `openOutage(java.lang.String outageIdSQL, int nodeId, java.lang.String ipAddr, int serviceId, int dbid, java.lang.String time)`
`void` `reparentOutages(java.lang.String ipAddr, int oldNodeId, int newNodeId)`
`void` `resolveOutage(int nodeId, java.lang.String ipAddr, int serviceId, int dbid, java.lang.String time)`
`void` `setDbConnectionFactory(DbConnectionFactory dbConnectionFactory)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### m_network

    private final MockNetwork m_network

  Comment for `m_network`

Constructor Detail

### MockQueryManager

    public MockQueryManager(MockNetwork network)

Parameters:
  `network` -

Method Detail

### setDbConnectionFactory

    public void setDbConnectionFactory(DbConnectionFactory dbConnectionFactory)

  Specified by:
    `setDbConnectionFactory` in interface `QueryManager`
  Parameters:
    `dbConnectionFactory` -

### activeServiceExists

    public boolean activeServiceExists(java.lang.String whichEvent,
                                       int nodeId,
                                       java.lang.String ipAddr,
                                       java.lang.String serviceName)

  Specified by:
    `activeServiceExists` in interface `QueryManager`
  Parameters:
    `whichEvent` -
    `nodeId` -
    `ipAddr` -
    `serviceName` -
  Returns:

### buildServiceNameToIdMaps

    public void buildServiceNameToIdMaps(java.util.Map nameToId,
                                         java.util.Map idToName)

  Specified by:
    `buildServiceNameToIdMaps` in interface `QueryManager`
  Parameters:
    `nameToId` -
    `idToName` -
  Returns:

### getActiveServiceIdsForInterface

    public java.util.List getActiveServiceIdsForInterface(java.lang.String ipaddr)
                                                   throws java.sql.SQLException

  Specified by:
    `getActiveServiceIdsForInterface` in interface `QueryManager`
  Parameters:
    `ipaddr` -
  Returns:
  Throws:
    `java.sql.SQLException`

### getInterfacesWithService

    public java.util.List getInterfacesWithService(java.lang.String svcName)
                                            throws java.sql.SQLException

  Specified by:
    `getInterfacesWithService` in interface `QueryManager`
  Parameters:
    `svcName` -
  Returns:
  Throws:
    `java.sql.SQLException`

### getNodeIDForInterface

    public int getNodeIDForInterface(java.lang.String ipaddr)
                              throws java.sql.SQLException

  Specified by:
    `getNodeIDForInterface` in interface `QueryManager`
  Parameters:
    `ipaddr` -
  Returns:
  Throws:
    `java.sql.SQLException`

### getNodeLabel

    public java.lang.String getNodeLabel(int nodeId)
                                  throws java.sql.SQLException

  Specified by:
    `getNodeLabel` in interface `QueryManager`
  Parameters:
    `nodeId` -
  Returns:
  Throws:
    `java.sql.SQLException`

### getServiceCountForInterface

    public int getServiceCountForInterface(java.lang.String ipaddr)
                                    throws java.sql.SQLException

  Specified by:
    `getServiceCountForInterface` in interface `QueryManager`
  Parameters:
    `ipaddr` -
  Returns:
  Throws:
    `java.sql.SQLException`

### getServiceLostDate

    public java.util.Date getServiceLostDate(int nodeId,
                                             java.lang.String ipAddr,
                                             java.lang.String svcName,
                                             int serviceId)

  Specified by:
    `getServiceLostDate` in interface `QueryManager`
  Parameters:
    `nodeId` -
    `ipAddr` -
    `svcName` -
  Returns:

### openOutage

    public void openOutage(java.lang.String outageIdSQL,
                           int nodeId,
                           java.lang.String ipAddr,
                           int serviceId,
                           int dbid,
                           java.lang.String time)

  Specified by:
    `openOutage` in interface `QueryManager`
  Parameters:
    `nodeId` -
    `ipAddr` -
    `serviceId` -
    `dbid` -
    `time` -

### resolveOutage

    public void resolveOutage(int nodeId,
                              java.lang.String ipAddr,
                              int serviceId,
                              int dbid,
                              java.lang.String time)

  Specified by:
    `resolveOutage` in interface `QueryManager`
  Parameters:
    `nodeId` -
    `ipAddr` -
    `serviceId` -
    `dbid` -
    `time` -

### reparentOutages

    public void reparentOutages(java.lang.String ipAddr,
                                int oldNodeId,
                                int newNodeId)

  Specified by:
    `reparentOutages` in interface `QueryManager`
  Parameters:
    `ipAddr` -
    `oldNodeId` -
    `newNodeId` -

OpenNMS API 1.2.9

Generated by ranger on May 19 2007 2335.