com.eightydegreeswest.iristools
Class IrisServlet

java.lang.Object
  extended by java.lang.Thread
      extended by com.eightydegreeswest.iristools.IrisServlet
All Implemented Interfaces:
java.lang.Runnable

public class IrisServlet
extends java.lang.Thread


Nested Class Summary
 
Nested classes/interfaces inherited from class java.lang.Thread
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler
 
Field Summary
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
IrisServlet(java.util.Properties properties)
          
Initialize Web Server - set appropriate port specified in the properties file
 
Method Summary
 java.lang.String getPort()
           
 void run()
          
Starts a Web Server on a specified port to listen for commands
Web Server will accept the following required parameter:
command=commandName, where commandName is the method name from the IrisApi class
Second optional parameter is needed for some method in the following format:
command=commandName&idorparam=parameterName
Generally, the call will be as follows:
http://localhost:8080?command=setProfileAway
http://localhost:8080?command=setDeviceOn&deviceId=XX
 void setPort(java.lang.String port)
           
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IrisServlet

public IrisServlet(java.util.Properties properties)

Initialize Web Server - set appropriate port specified in the properties file

Parameters:
properties -
Method Detail

run

public void run()

Starts a Web Server on a specified port to listen for commands
Web Server will accept the following required parameter:
command=commandName, where commandName is the method name from the IrisApi class
Second optional parameter is needed for some method in the following format:
command=commandName&idorparam=parameterName
Generally, the call will be as follows:
http://localhost:8080?command=setProfileAway
http://localhost:8080?command=setDeviceOn&deviceId=XX

Specified by:
run in interface java.lang.Runnable
Overrides:
run in class java.lang.Thread

getPort

public java.lang.String getPort()

setPort

public void setPort(java.lang.String port)