public abstract class AbstractSaveOrUpdateOperation extends AbstractImportOperation implements SaveOrUpdateOperation
Abstract AbstractSaveOrUpdateOperation class.
Constructor and Description |
---|
AbstractSaveOrUpdateOperation(Integer nodeId,
String foreignSource,
String foreignId,
String nodeLabel,
String building,
String city)
Constructor for AbstractSaveOrUpdateOperation.
|
AbstractSaveOrUpdateOperation(String foreignSource,
String foreignId,
String nodeLabel,
String building,
String city)
Constructor for AbstractSaveOrUpdateOperation.
|
Modifier and Type | Method and Description |
---|---|
protected abstract List<Event> |
doPersist()
doPersist
|
void |
foundAsset(String name,
String value)
foundAsset
|
void |
foundCategory(String name)
foundCategory
|
void |
foundInterface(String ipAddr,
Object descr,
InterfaceSnmpPrimaryType snmpPrimary,
boolean managed,
int status)
foundInterface
|
void |
foundMonitoredService(String serviceName)
foundMonitoredService
|
void |
gatherAdditionalData()
gatherAdditionalData
|
CategoryDao |
getCategoryDao()
getCategoryDao
|
protected DistPollerDao |
getDistPollerDao()
getDistPollerDao
|
protected Map<String,OnmsIpInterface> |
getIpAddrToInterfaceMap(OnmsNode imported)
getIpAddrToInterfaceMap
|
protected OnmsNode |
getNode()
getNode
|
protected NodeDao |
getNodeDao()
getNodeDao
|
protected boolean |
isSnmpDataForInterfacesUpToDate()
isSnmpDataForInterfacesUpToDate
|
protected boolean |
isSnmpDataForNodeUpToDate()
isSnmpDataForNodeUpToDate
|
protected ThreadCategory |
log()
log
|
boolean |
nullSafeEquals(Object o1,
Object o2)
nullSafeEquals
|
List<Event> |
persist()
persist
|
void |
setCategoryCache(ThreadLocal<HashMap<String,OnmsCategory>> categoryCache)
setCategoryCache
|
void |
setCategoryDao(CategoryDao categoryDao)
setCategoryDao
|
void |
setDistPollerDao(DistPollerDao distPollerDao)
setDistPollerDao
|
void |
setNodeDao(NodeDao nodeDao)
setNodeDao
|
void |
setServiceTypeDao(ServiceTypeDao svcTypeDao)
setServiceTypeDao
|
void |
setTypeCache(ThreadLocal<HashMap<String,OnmsServiceType>> typeCache)
setTypeCache
|
protected void |
updateSnmpData()
updateSnmpData
|
public AbstractSaveOrUpdateOperation(String foreignSource, String foreignId, String nodeLabel, String building, String city)
Constructor for AbstractSaveOrUpdateOperation.
public void foundInterface(String ipAddr, Object descr, InterfaceSnmpPrimaryType snmpPrimary, boolean managed, int status)
foundInterface
foundInterface
in interface SaveOrUpdateOperation
ipAddr
- a String
object.descr
- a Object
object.snmpPrimary
- a InterfaceSnmpPrimaryType
object.managed
- a boolean.status
- a int.public void gatherAdditionalData()
gatherAdditionalData
gatherAdditionalData
in interface ImportOperation
public List<Event> persist()
persist
persist
in interface ImportOperation
List
object.protected void updateSnmpData()
updateSnmpData
protected boolean isSnmpDataForNodeUpToDate()
isSnmpDataForNodeUpToDate
protected boolean isSnmpDataForInterfacesUpToDate()
isSnmpDataForInterfacesUpToDate
public void foundMonitoredService(String serviceName)
foundMonitoredService
foundMonitoredService
in interface SaveOrUpdateOperation
serviceName
- a String
object.public void foundCategory(String name)
foundCategory
foundCategory
in interface SaveOrUpdateOperation
name
- a String
object.public void foundAsset(String name, String value)
foundAsset
foundAsset
in interface SaveOrUpdateOperation
name
- a String
object.value
- a String
object.protected DistPollerDao getDistPollerDao()
getDistPollerDao
DistPollerDao
object.protected Map<String,OnmsIpInterface> getIpAddrToInterfaceMap(OnmsNode imported)
getIpAddrToInterfaceMap
public CategoryDao getCategoryDao()
getCategoryDao
CategoryDao
object.public void setCategoryDao(CategoryDao categoryDao)
setCategoryDao
categoryDao
- a CategoryDao
object.public void setServiceTypeDao(ServiceTypeDao svcTypeDao)
setServiceTypeDao
svcTypeDao
- a ServiceTypeDao
object.public void setNodeDao(NodeDao nodeDao)
setNodeDao
nodeDao
- a NodeDao
object.public void setDistPollerDao(DistPollerDao distPollerDao)
setDistPollerDao
distPollerDao
- a DistPollerDao
object.public void setTypeCache(ThreadLocal<HashMap<String,OnmsServiceType>> typeCache)
setTypeCache
typeCache
- a ThreadLocal
object.public void setCategoryCache(ThreadLocal<HashMap<String,OnmsCategory>> categoryCache)
setCategoryCache
categoryCache
- a ThreadLocal
object.protected ThreadCategory log()
log
ThreadCategory
object.Copyright © 2015. All Rights Reserved.