com.alarmpoint.integrations.nnmi.mg
Class NetworkNodeManagerMobileGatewayWrapper

java.lang.Object
  extended by com.alarmpoint.integrations.nnmi.mg.NetworkNodeManagerMobileGatewayWrapper

public class NetworkNodeManagerMobileGatewayWrapper
extends java.lang.Object

NetworkNodeManagerMobileGatewayWrapper is a wrapper class which enables retrieving of remote data from NNMi. The wrapper uses Axis2 JavaServiceStubs which were created based on NNMi's WSDL to prefore WS calls to NNMi. The wrapper is responsible for wrapping the service stubs so they are not directly referenced from outside classes and allows for an easy way to retrive the NNMi Java Stub objects.

Author:
amagi

Constructor Summary
NetworkNodeManagerMobileGatewayWrapper()
          Default constructor, this should only be used for testing as it uses hardcoded values for the WS credentials.
NetworkNodeManagerMobileGatewayWrapper(java.lang.String host, java.lang.String port, java.lang.String wsUser, java.lang.String wsPassword)
          This constructor sets up the NetworkNodeManagerMobileGatewayWrapper with the correct WS credentials to perform WS calls though the NNMi Java Service Stubs.
 
Method Summary
 java.lang.String[] getAssignToList()
          Retrieve a list of Assignable users for a incident
 java.util.List<IncidentBeanServiceStub.Incident> getChildIncidents(java.lang.String parentId)
          Retrieve the Child Incidents based on the Incident ID of the parent provided.
 IncidentBeanServiceStub.Incident getIncident(java.lang.String id)
          Retrieve the Incident using its id.
 java.util.List<IncidentBeanServiceStub.Incident> getIncidents(IncidentBeanServiceStub.Filter filter)
          Retrieve the Incidents based on the IncidentFilter provided.
 IncidentBeanServiceStub getIncidentService()
           
 InterfaceBeanServiceStub._interface getInterface(java.lang.String sourceName)
          Retrieve the IpAddress Source Object using its name.
 IPAddressBeanServiceStub.IpAddress getIPAddress(java.lang.String sourceName)
          Retrieve the IpAddress Source Object using its name.
 IPSubnetBeanServiceStub.IpSubnet getIPSubnet(java.lang.String sourceName)
          Retrieve the IpSubnet Source Object using its name.
 L2ConnectionBeanServiceStub.L2Connection getL2Connection(java.lang.String sourceName)
          Retrieve the L2Connection Source Object using its name.
 NodeBeanServiceStub.Node getNode(java.lang.String nodeName)
          Retrieve the Node using its name.
 NodeBeanServiceStub getNodeService()
           
 java.lang.String getPort()
           
 void setPort(java.lang.String port)
           
 IncidentBeanServiceStub.UpdateAssignedToResponse updateAssignedTo(java.lang.String id, java.lang.String assigne)
          Update the incident specified by its ID with the associated priority
 IncidentBeanServiceStub.UpdateLifecycleStateResponse updateLifecycleState(java.lang.String id, java.lang.String lifecycle)
          Update the incident specified by its ID with the associated lifecycle
 IncidentBeanServiceStub.UpdateNotesResponse updateNotes(java.lang.String id, java.lang.String notes)
          Update the incident specified by its ID with the associated notes
 IncidentBeanServiceStub.UpdatePriorityResponse updatePriority(java.lang.String id, java.lang.String priority)
          Update the incident specified by its ID with the associated priority
 boolean validateCredentials()
          Verifies that the given credentials are correct otherwise it throws an NmsIncidentFaultException0 exception.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NetworkNodeManagerMobileGatewayWrapper

public NetworkNodeManagerMobileGatewayWrapper()
                                       throws org.apache.axis2.AxisFault
Default constructor, this should only be used for testing as it uses hardcoded values for the WS credentials.

Throws:
org.apache.axis2.AxisFault

NetworkNodeManagerMobileGatewayWrapper

public NetworkNodeManagerMobileGatewayWrapper(java.lang.String host,
                                              java.lang.String port,
                                              java.lang.String wsUser,
                                              java.lang.String wsPassword)
                                       throws org.apache.axis2.AxisFault
This constructor sets up the NetworkNodeManagerMobileGatewayWrapper with the correct WS credentials to perform WS calls though the NNMi Java Service Stubs.

Parameters:
host -
wsUser -
wsPassword -
Throws:
org.apache.axis2.AxisFault
Method Detail

getIncidentService

public IncidentBeanServiceStub getIncidentService()

getNodeService

public NodeBeanServiceStub getNodeService()

getIncidents

public java.util.List<IncidentBeanServiceStub.Incident> getIncidents(IncidentBeanServiceStub.Filter filter)
                                                              throws java.rmi.RemoteException,
                                                                     NmsIncidentFaultException0
Retrieve the Incidents based on the IncidentFilter provided. The incident filter outlines what incidents to return from NNMi.

Parameters:
filter - (Filter must contain the appropriate IncidentFilter)
Returns:
List
Throws:
java.rmi.RemoteException
NmsIncidentFaultException0

getChildIncidents

public java.util.List<IncidentBeanServiceStub.Incident> getChildIncidents(java.lang.String parentId)
                                                                   throws java.rmi.RemoteException,
                                                                          NmsIncidentFaultException0
Retrieve the Child Incidents based on the Incident ID of the parent provided.

Parameters:
Parent - Incident ID
Returns:
List
Throws:
java.rmi.RemoteException
NmsIncidentFaultException0

getIncident

public IncidentBeanServiceStub.Incident getIncident(java.lang.String id)
                                             throws java.rmi.RemoteException,
                                                    NmsIncidentFaultException0
Retrieve the Incident using its id.

Parameters:
id -
Returns:
Incident
Throws:
java.rmi.RemoteException
NmsIncidentFaultException0

updatePriority

public IncidentBeanServiceStub.UpdatePriorityResponse updatePriority(java.lang.String id,
                                                                     java.lang.String priority)
                                                              throws java.rmi.RemoteException,
                                                                     NmsIncidentFaultException0
Update the incident specified by its ID with the associated priority

Parameters:
id -
priority -
Returns:
UpdatePriorityResponse
Throws:
java.rmi.RemoteException
NmsIncidentFaultException0

updateAssignedTo

public IncidentBeanServiceStub.UpdateAssignedToResponse updateAssignedTo(java.lang.String id,
                                                                         java.lang.String assigne)
                                                                  throws java.rmi.RemoteException,
                                                                         NmsIncidentFaultException0
Update the incident specified by its ID with the associated priority

Parameters:
id -
priority -
Returns:
UpdatePriorityResponse
Throws:
java.rmi.RemoteException
NmsIncidentFaultException0

updateLifecycleState

public IncidentBeanServiceStub.UpdateLifecycleStateResponse updateLifecycleState(java.lang.String id,
                                                                                 java.lang.String lifecycle)
                                                                          throws java.rmi.RemoteException,
                                                                                 NmsIncidentFaultException0
Update the incident specified by its ID with the associated lifecycle

Parameters:
id -
lifecycle -
Returns:
UpdateLifecycleStateResponse
Throws:
java.rmi.RemoteException
NmsIncidentFaultException0

updateNotes

public IncidentBeanServiceStub.UpdateNotesResponse updateNotes(java.lang.String id,
                                                               java.lang.String notes)
                                                        throws java.rmi.RemoteException,
                                                               NmsIncidentFaultException0
Update the incident specified by its ID with the associated notes

Parameters:
id -
notes -
Returns:
UpdateNotesResponse
Throws:
java.rmi.RemoteException
NmsIncidentFaultException0

getNode

public NodeBeanServiceStub.Node getNode(java.lang.String nodeName)
                                 throws java.rmi.RemoteException,
                                        NmsNodeFaultException0
Retrieve the Node using its name.

Parameters:
nodeName -
Returns:
Node
Throws:
java.rmi.RemoteException
NmsNodeFaultException0

getL2Connection

public L2ConnectionBeanServiceStub.L2Connection getL2Connection(java.lang.String sourceName)
                                                         throws java.lang.UnsupportedOperationException,
                                                                java.rmi.RemoteException,
                                                                NmsL2ConnectionFaultException0
Retrieve the L2Connection Source Object using its name.

Parameters:
sourceName -
Returns:
L2Connection
Throws:
java.lang.UnsupportedOperationException
java.rmi.RemoteException
NmsL2ConnectionFaultException0

getIPAddress

public IPAddressBeanServiceStub.IpAddress getIPAddress(java.lang.String sourceName)
                                                throws java.lang.UnsupportedOperationException,
                                                       java.rmi.RemoteException,
                                                       NmsIPAddressFaultException0
Retrieve the IpAddress Source Object using its name.

Parameters:
sourceName -
Returns:
IpAddress
Throws:
java.lang.UnsupportedOperationException
java.rmi.RemoteException
NmsIPAddressFaultException0

getIPSubnet

public IPSubnetBeanServiceStub.IpSubnet getIPSubnet(java.lang.String sourceName)
                                             throws java.lang.UnsupportedOperationException,
                                                    java.rmi.RemoteException,
                                                    NmsIPSubnetFaultException0
Retrieve the IpSubnet Source Object using its name.

Parameters:
sourceName -
Returns:
IpSubnet
Throws:
java.lang.UnsupportedOperationException
java.rmi.RemoteException
NmsIPSubnetFaultException0

getInterface

public InterfaceBeanServiceStub._interface getInterface(java.lang.String sourceName)
                                                 throws java.lang.UnsupportedOperationException,
                                                        java.rmi.RemoteException,
                                                        NmsInterfaceFaultException0
Retrieve the IpAddress Source Object using its name.

Parameters:
sourceName -
Returns:
_interface
Throws:
java.lang.UnsupportedOperationException
java.rmi.RemoteException
NmsInterfaceFaultException0

getAssignToList

public java.lang.String[] getAssignToList()
                                   throws java.rmi.RemoteException,
                                          java.lang.Exception
Retrieve a list of Assignable users for a incident

Returns:
a list of Assignable users for a incident
Throws:
java.rmi.RemoteException
java.lang.Exception
NmsIncidentFaultException0

validateCredentials

public boolean validateCredentials()
                            throws java.rmi.RemoteException,
                                   NmsIncidentFaultException0
Verifies that the given credentials are correct otherwise it throws an NmsIncidentFaultException0 exception.

Returns:
boolean
Throws:
java.rmi.RemoteException
NmsIncidentFaultException0

getPort

public java.lang.String getPort()

setPort

public void setPort(java.lang.String port)