public class HibernateTrapdIpMgr extends Object implements TrapdIpMgr, org.springframework.beans.factory.InitializingBean
| Modifier and Type | Field and Description |
|---|---|
protected Map<InetAddress,Integer> |
m_knownips
A Map of IP addresses and node IDs
|
| Constructor and Description |
|---|
HibernateTrapdIpMgr()
Default construct for the instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet()
afterPropertiesSet
|
void |
dataSourceSync()
dataSourceSync
|
IpInterfaceDao |
getIpInterfaceDao()
getIpInterfaceDao
|
long |
getNodeId(String addr)
Returns the nodeid for the IP Address
|
long |
removeNodeId(String addr)
Removes an address from the node ID map.
|
long |
setNodeId(String addr,
long nodeid)
Sets the IP Address and Node ID in the Map.
|
protected Map<InetAddress,Integer> m_knownips
public HibernateTrapdIpMgr()
@Transactional(readOnly=true) public void dataSourceSync()
dataSourceSync
dataSourceSync in interface TrapdIpMgrpublic long getNodeId(String addr)
getNodeId in interface TrapdIpMgraddr - The IP Address to query.public long setNodeId(String addr, long nodeid)
setNodeId in interface TrapdIpMgraddr - The IP Address to add.nodeid - The Node ID to add.public long removeNodeId(String addr)
removeNodeId in interface TrapdIpMgraddr - The address to remove from the node ID map.public void afterPropertiesSet()
throws Exception
afterPropertiesSet
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanException - if any.public IpInterfaceDao getIpInterfaceDao()
getIpInterfaceDao
IpInterfaceDao object.Copyright © 2015. All rights reserved.