Class SnmpInterfaceUpgrade
- java.lang.Object
-
- org.opennms.upgrade.implementations.SnmpInterface
-
- org.opennms.upgrade.implementations.SnmpInterfaceUpgrade
-
public class SnmpInterfaceUpgrade extends SnmpInterface
The Class SnmpInterfaceUpgrade.- Author:
- Alejandro Galue
-
-
Constructor Summary
Constructors Constructor Description SnmpInterfaceUpgrade(int nodeId, java.lang.String foreignSource, java.lang.String foreignId, java.lang.String ifDescr, java.lang.String ifName, java.lang.String physAddr, boolean storeByForeignSource)Instantiates a new SNMP interface upgrade.SnmpInterfaceUpgrade(java.sql.ResultSet rs, boolean storeByForeignSource)Instantiates a new SNMP interface upgrade.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.io.FilegetNewInterfaceDir()Gets the new interface directory.java.io.FilegetNodeDir()Gets the node directory.protected java.io.FilegetNodeDirectory(int nodeId, java.lang.String foreignSource, java.lang.String foreignId)Gets the node directory.java.io.FilegetOldInterfaceDir()Gets the old interface directory.protected voidinitialize()Initialize.booleanshouldMerge()Checks if the interface directories should be merged.java.lang.StringtoString()-
Methods inherited from class org.opennms.upgrade.implementations.SnmpInterface
getForeignId, getForeignSource, getIfDescr, getIfName, getNewResourceId, getNewRrdLabel, getNodeId, getOldResourceId, getOldRrdLabel, getPhysAddr, shouldUpdate
-
-
-
-
Constructor Detail
-
SnmpInterfaceUpgrade
public SnmpInterfaceUpgrade(int nodeId, java.lang.String foreignSource, java.lang.String foreignId, java.lang.String ifDescr, java.lang.String ifName, java.lang.String physAddr, boolean storeByForeignSource)Instantiates a new SNMP interface upgrade.- Parameters:
nodeId- the node idforeignSource- the foreign sourceforeignId- the foreign idifDescr- the SNMP interface descriptionifName- the SNMP interface namephysAddr- the SNMP physical addressstoreByForeignSource- true, if store by foreign source is enabled
-
SnmpInterfaceUpgrade
public SnmpInterfaceUpgrade(java.sql.ResultSet rs, boolean storeByForeignSource) throws java.sql.SQLExceptionInstantiates a new SNMP interface upgrade.- Parameters:
rs- the ResultSetstoreByForeignSource- true, if the store by foreign source is enabled- Throws:
java.sql.SQLException- the SQL exception
-
-
Method Detail
-
initialize
protected void initialize()
Description copied from class:SnmpInterfaceInitialize.- Overrides:
initializein classSnmpInterface
-
getNodeDir
public java.io.File getNodeDir()
Gets the node directory.- Returns:
- the node directory
-
getOldInterfaceDir
public java.io.File getOldInterfaceDir()
Gets the old interface directory.- Returns:
- the old interface directory
-
getNewInterfaceDir
public java.io.File getNewInterfaceDir()
Gets the new interface directory.- Returns:
- the new interface directory
-
shouldMerge
public boolean shouldMerge()
Checks if the interface directories should be merged.- Returns:
- true, if the interface directory should be merged
-
getNodeDirectory
protected java.io.File getNodeDirectory(int nodeId, java.lang.String foreignSource, java.lang.String foreignId)Gets the node directory.- Parameters:
nodeId- the node idforeignSource- the foreign sourceforeignId- the foreign id- Returns:
- the node directory
-
toString
public java.lang.String toString()
- Overrides:
toStringin classSnmpInterface
-
-