commands
Class UpdateAttribute

java.lang.Object
  extended bycommands.UpdateAttribute

public class UpdateAttribute
extends java.lang.Object

Commands to update a list of attribute records in the GLTMon database. The commands use a list of retrieved device interfaces to compare against a list of checked deviceIDs. Those that differ get updated in the GLTMon database.

Version:
0.1
Author:
gswalters

Constructor Summary
UpdateAttribute()
           
 
Method Summary
 void done()
          Clean up after the command's execution.
 java.lang.String getDeviceName()
           
 java.lang.String getUpdateResults()
           
 void initialize(java.lang.String dbContext, javax.servlet.http.HttpServletRequest request)
          Initialize the command with the database context and request.
 void updateMonitoring()
          Execute the updateMonitoring UpdateAttribute command.
 void updateRemoved()
          Execute the updateRemoved UpdateAttribute command.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UpdateAttribute

public UpdateAttribute()
Method Detail

getUpdateResults

public java.lang.String getUpdateResults()

getDeviceName

public java.lang.String getDeviceName()

initialize

public void initialize(java.lang.String dbContext,
                       javax.servlet.http.HttpServletRequest request)
                throws java.lang.Exception
Initialize the command with the database context and request. If either has problems, throw an exception to indicate the problem.

Parameters:
dbContext - String containing the JNDI context resource
request - HttpServletRequest holding the full HTTP request
Throws:
java.lang.Exception - containing the reason the initialize failed

updateMonitoring

public void updateMonitoring()
                      throws java.lang.Exception
Execute the updateMonitoring UpdateAttribute command. Construct the database query and submit it to the database.

Throws:
java.lang.Exception - to indicate a failed query

updateRemoved

public void updateRemoved()
                   throws java.lang.Exception
Execute the updateRemoved UpdateAttribute command. Construct the database query and submit it to the database.

Throws:
java.lang.Exception - to indicate a failed query

done

public void done()
Clean up after the command's execution.