|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.wcb.autohome.implementations.RunEvent
Copyright (C) 1999 Walter Bogaardt
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
Project: Alice X10 Home Automation
Filename: $Id: RunEvent.java,v 1.9 2004/02/28 00:21:49 wbogaardt Exp $
Abstract: This is a Run event which should be executed when a monitored
event detects activity. The run event can be firing off a x10 module
or runing an application program.
$Log: RunEvent.java,v $
Revision 1.9 2004/02/28 00:21:49 wbogaardt
fixed formating to be compliant with sun coding convention
Revision 1.8 2004/02/24 23:16:19 wbogaardt
fixed formating to be compliant with checkstyles
Revision 1.7 2004/02/06 20:06:36 wbogaardt
replaced ampm drop boxes with time buttons which launch a time panel move menu items around on main panel
Revision 1.6 2004/01/31 07:40:26 wbogaardt
modified layout managers for the panel so that it uses the java standard layoutsrather than the FormLayout api.
The purpose is to reduce dependency on non-standard layout api.
Revision 1.5 2004/01/20 05:31:05 wbogaardt
added speech event for runing
Revision 1.4 2004/01/19 22:35:37 wbogaardt
added fixes to runing events and emails so they work and added a testing of a monitored event through the table popup
on a right mouse click.
Revision 1.3 2004/01/18 00:48:33 wbogaardt
refactored out unnecessary code and now have a functional initial design of monitoring panel
Revision 1.2 2004/01/17 07:21:17 wbogaardt
added serialization to run events and allow monitoring of these events to the file system to reload later
Revision 1.1 2004/01/17 06:21:55 wbogaardt
added new Run event interfaces
| Field Summary | |
static int |
RUN_APPLICATION
The run an application constant |
static int |
RUN_MODULE
The run an X10 event or module constant |
static int |
SEND_EMAIL
The send email constants |
static int |
SPEAK_COMMAND
The speak text constant |
| Constructor Summary | |
RunEvent()
This constructor automatically runs a set of events |
|
RunEvent(int iT,
IX10Module mod,
int iAction)
The Constructor takes a run type see setRunType() method the X10Module interface, and the action to take place. |
|
| Method Summary | |
java.lang.String[] |
getArguments()
Returns the argument parameters sent with the application name sometimes an application does not have command line parameters and that should be ok too. |
java.lang.String |
getCommand()
Returns the initial command to sent through the command line this is usually the application name. |
int |
getModuleCommand()
Return the module command can be one of the following from the X10DeviceConstants, which is an on event or off event; X10DeviceConstants.ON_ACTION or X10DeviceConstants.OFF_ACTION |
int |
getRunType()
Returns the run type for this action Should be only three types Either execute a module, execute sending email, or running an outside application; 0 send email, 1 run module, 2 run command |
java.lang.String |
getSentence()
Returns the sentence that the user want's the speech engine to speak. |
IX10Module |
getX10Module()
Returns the x10 module to run only if the Run type is a value of 0. |
void |
setArguments(java.lang.String[] args)
The argument parameters sent with the application name sometimes an application does not have command line parameters and that should be ok too. |
void |
setCommand(java.lang.String sCmd)
This is the initial command to send through the command line this is usually the application name. |
void |
setModuleCommand(int iCmd)
The module command can be one of the following from the X10DeviceConstants, which is an on event or off event; X10DeviceConstants.ON_ACTION or X10DeviceConstants.OFF_ACTION |
void |
setRunType(int iT)
Sets the run type for this action. |
void |
setSentence(java.lang.String sSentence)
This saves a string of a sentence that the user wants spoken by the alice speech engine. |
void |
setX10Module(IX10Module module)
the x10 module to run only if the Run type is a value of 0. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final int SEND_EMAIL
public static final int RUN_APPLICATION
public static final int SPEAK_COMMAND
public static final int RUN_MODULE
| Constructor Detail |
public RunEvent()
public RunEvent(int iT,
IX10Module mod,
int iAction)
iT - The Run type valid valies 0-2mod - IX10Module interfaceiAction - Action type for the X10Module either ON or off| Method Detail |
public void setRunType(int iT)
setRunType in interface IRunEventiT - Valid values of 0-2public void setX10Module(IX10Module module)
setX10Module in interface IRunEventmodule - The X10 device module to run.public void setModuleCommand(int iCmd)
setModuleCommand in interface IRunEventiCmd - Either on or off command value 1 or 0public void setCommand(java.lang.String sCmd)
setCommand in interface IRunEventsCmd - The application name.public void setArguments(java.lang.String[] args)
setArguments in interface IRunEventargs - String array of arguments for a command line executionpublic void setSentence(java.lang.String sSentence)
setSentence in interface IRunEventsSentence - Sentence to speakpublic int getRunType()
getRunType in interface IRunEventpublic IX10Module getX10Module()
getX10Module in interface IRunEventpublic int getModuleCommand()
getModuleCommand in interface IRunEventpublic java.lang.String getCommand()
getCommand in interface IRunEventpublic java.lang.String[] getArguments()
getArguments in interface IRunEventpublic java.lang.String getSentence()
getSentence in interface IRunEvent
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||