2009-01-09 1.2.0

org.eclipse.soda.dk.device.device.servlet
Class DeviceDeviceServlet

java.lang.Object
  extended by javax.servlet.GenericServlet
      extended by javax.servlet.http.HttpServlet
          extended by org.eclipse.soda.dk.device.servlet.DeviceServlet
              extended by org.eclipse.soda.dk.device.device.servlet.DeviceDeviceServlet
All Implemented Interfaces:
java.io.Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig, DeviceServletService

public class DeviceDeviceServlet
extends DeviceServlet
implements DeviceServletService, javax.servlet.Servlet

Since:
1.0
Version:
1.2.0
See Also:
Serialized Form

Field Summary
 
Fields inherited from interface org.eclipse.soda.dk.device.servlet.service.DeviceServletService
SERVICE_NAME
 
Constructor Summary
DeviceDeviceServlet()
          Constructs an instance of this class.
 
Method Summary
 DeviceServletContext createContext(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Create context with the specified request and response parameters and return the DeviceServletContext result.
static java.lang.String formatData(java.lang.Object data, boolean form)
          Format data with the specified data and form parameters and return the String result.
static void formatData(java.lang.StringBuffer buffer, java.lang.Object data, boolean form)
          Format data with the specified buffer, data and form parameters.
 DeviceService getDevice()
          Gets the device (DeviceService) value.
 void processCommand(DeviceServletContext context, CommandService command, boolean edit)
          Process command with the specified context, command and edit parameters.
 void processCommandPage(DeviceServletContext context, CommandService command, java.lang.String operation)
          Process command page with the specified context, command and operation parameters.
 void processDevice(DeviceDeviceServletContext context, DeviceService device)
          Process device with the specified context and device parameters.
 void processDeviceRegistry(DeviceDeviceServletContext context)
          Process device registry with the specified context parameter.
 void processFileRequest(DeviceServletContext context)
          Process file request with the specified context parameter.
 void processMeasurement(DeviceServletContext context, MeasurementService measurement, boolean edit)
          Process measurement with the specified context, measurement and edit parameters.
 void processMeasurementPage(DeviceServletContext context, MeasurementService measurement, java.lang.String operation)
          Process measurement page with the specified context, measurement and operation parameters.
 void processRequest(DeviceServletContext context)
          Process request with the specified context parameter.
 void processSignal(DeviceServletContext context, SignalService signal, boolean edit)
          Process signal with the specified context, signal and edit parameters.
 void processSignalPage(DeviceServletContext context, SignalService signal, java.lang.String operation)
          Process signal page with the specified context, signal and operation parameters.
 void setDevice(DeviceService device)
          Sets the device value.
 
Methods inherited from class org.eclipse.soda.dk.device.servlet.DeviceServlet
buildMenu, doGet, doPost, escape, escape, findAttribute, getBundleContext, getBundles, getResouceAliasDefault, getResoucePathDefault, getResourceAlias, getResourcePath, getServer, getServiceReferences, getServletAlias, getServletAliasDefault, processOverview, setBundleContext, setResourceAlias, setResourcePath, setServer, setServletAlias, setup
 
Methods inherited from class javax.servlet.http.HttpServlet
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, service
 
Methods inherited from class javax.servlet.GenericServlet
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, init, log, log
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.soda.dk.device.servlet.service.DeviceServletService
getServletAlias
 
Methods inherited from interface javax.servlet.Servlet
destroy, getServletConfig, getServletInfo, init, service
 

Constructor Detail

DeviceDeviceServlet

public DeviceDeviceServlet()
Constructs an instance of this class.

Method Detail

formatData

public static java.lang.String formatData(java.lang.Object data,
                                          boolean form)
Format data with the specified data and form parameters and return the String result.

Parameters:
data - The data (Object) parameter.
form - The form (boolean) parameter.
Returns:
Results of the format data (String) value.
See Also:
formatData(StringBuffer,Object,boolean)

formatData

public static void formatData(java.lang.StringBuffer buffer,
                              java.lang.Object data,
                              boolean form)
Format data with the specified buffer, data and form parameters.

Parameters:
buffer - The buffer (StringBuffer) parameter.
data - The data (Object) parameter.
form - The form (boolean) parameter.
See Also:
formatData(Object,boolean)

createContext

public DeviceServletContext createContext(javax.servlet.http.HttpServletRequest request,
                                          javax.servlet.http.HttpServletResponse response)
Create context with the specified request and response parameters and return the DeviceServletContext result.

Overrides:
createContext in class DeviceServlet
Parameters:
request - The request (HttpServletRequest) parameter.
response - The response (HttpServletResponse) parameter.
Returns:
Results of the create context (DeviceServletContext) value.
See Also:
DeviceServlet.getBundleContext(), DeviceServlet.setBundleContext(BundleContext)

getDevice

public DeviceService getDevice()
Gets the device (DeviceService) value.

Returns:
The device registry service (DeviceRegistryService) value.
See Also:
processDevice(DeviceDeviceServletContext,DeviceService), setDevice(DeviceService)

processCommand

public void processCommand(DeviceServletContext context,
                           CommandService command,
                           boolean edit)
Process command with the specified context, command and edit parameters.

Parameters:
context - The context (DeviceServletContext) parameter.
command - The command (CommandService) parameter.
edit - The edit (boolean) parameter.

processCommandPage

public void processCommandPage(DeviceServletContext context,
                               CommandService command,
                               java.lang.String operation)
Process command page with the specified context, command and operation parameters.

Parameters:
context - The context (DeviceServletContext) parameter.
command - The command (CommandService) parameter.
operation - The operation (String) parameter.

processDevice

public void processDevice(DeviceDeviceServletContext context,
                          DeviceService device)
Process device with the specified context and device parameters.

Parameters:
context - The context (DeviceDeviceServletContext) parameter.
device - The device (DeviceService) parameter.
See Also:
getDevice(), setDevice(DeviceService)

processDeviceRegistry

public void processDeviceRegistry(DeviceDeviceServletContext context)
Process device registry with the specified context parameter.

Parameters:
context - The context (DeviceDeviceServletContext) parameter.

processFileRequest

public void processFileRequest(DeviceServletContext context)
Process file request with the specified context parameter.

Overrides:
processFileRequest in class DeviceServlet
Parameters:
context - The context (DeviceServletContext) parameter.

processMeasurement

public void processMeasurement(DeviceServletContext context,
                               MeasurementService measurement,
                               boolean edit)
Process measurement with the specified context, measurement and edit parameters.

Parameters:
context - The context (DeviceServletContext) parameter.
measurement - The measurement (MeasurementService) parameter.
edit - The edit (boolean) parameter.

processMeasurementPage

public void processMeasurementPage(DeviceServletContext context,
                                   MeasurementService measurement,
                                   java.lang.String operation)
Process measurement page with the specified context, measurement and operation parameters.

Parameters:
context - The context (DeviceServletContext) parameter.
measurement - The measurement (MeasurementService) parameter.
operation - The operation (String) parameter.

processRequest

public void processRequest(DeviceServletContext context)
Process request with the specified context parameter.

Overrides:
processRequest in class DeviceServlet
Parameters:
context - The context (DeviceServletContext) parameter.
See Also:
processFileRequest(DeviceServletContext)

processSignal

public void processSignal(DeviceServletContext context,
                          SignalService signal,
                          boolean edit)
Process signal with the specified context, signal and edit parameters.

Parameters:
context - The context (DeviceServletContext) parameter.
signal - The signal (SignalService) parameter.
edit - The edit (boolean) parameter.

processSignalPage

public void processSignalPage(DeviceServletContext context,
                              SignalService signal,
                              java.lang.String operation)
Process signal page with the specified context, signal and operation parameters.

Parameters:
context - The context (DeviceServletContext) parameter.
signal - The signal (SignalService) parameter.
operation - The operation (String) parameter.

setDevice

public void setDevice(DeviceService device)
Sets the device value.

Parameters:
device - The device (DeviceService) parameter.
See Also:
getDevice(), processDevice(DeviceDeviceServletContext,DeviceService)

2009-01-09 1.2.0

Copyright (c) 2009 IBM. See license in Legal section.