|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.fhg.igd.semoa.service.AbstractService
examples.carcontrol.DoorServiceImpl
Field Summary | |
static String |
DESCR
The descriptor of the general options. |
private byte |
state
|
Fields inherited from class de.fhg.igd.semoa.service.AbstractService |
REV_POSTFIX, REV_PREFIX |
Fields inherited from interface examples.carcontrol.DoorService |
LEFT_BACK, LEFT_FRONT, PUBLISH_KEY, REAR, RIGHT_BACK, RIGHT_FRONT |
Constructor Summary | |
DoorServiceImpl()
|
Method Summary | |
String |
author()
Returns the name of the author of the service. |
private void |
clear(int which)
Clears a bit of the status byte. |
byte |
getStatus()
Returns current state, means the current position of all doors |
String |
info()
Returns the informative string which should describe the service's essence in a sentence. |
boolean |
isOpen(int which)
Returns true if door is open |
static void |
main(String[] argv)
Main method to control the door status via service access. |
String |
revision()
Returns the revision number of this class as a string. |
private void |
set(int which)
Sets a bit of the status byte. |
void |
setStatus(int newstate)
Sets the states of all doors. |
String |
toString()
Returns the current status of the doors as string. |
Methods inherited from class de.fhg.igd.semoa.service.AbstractService |
checkDependencies, dependencies, docs, doPrivileged, doPrivileged, getACC, getEnvironment, majorVersion, minorVersion |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final String DESCR
private byte state
Constructor Detail |
public DoorServiceImpl()
Method Detail |
public String author()
AbstractService
author
in interface Service
author
in class AbstractService
public String revision()
AbstractService
majorVersion()
, minorVersion
based on the assumption that this method returns a
revision string as generated by rcs(1) for the template
"$Revision: 1.7 $/$Date: 2007-08-08 04:41:53 +0200 (Wed, 08 Aug 2007) $".
revision
in class AbstractService
public String info()
AbstractService
info
in interface Service
info
in class AbstractService
public byte getStatus()
getStatus
in interface DoorService
public void setStatus(int newstate)
setStatus
in interface DoorService
newstate
- the new state status is set to.public boolean isOpen(int which)
isOpen
in interface DoorService
which
- number of the door to be checked. Use the
constants defined in DoorService
.
private void set(int which)
which
- number of the door to be checked. Use the
constants defined in DoorService
.private void clear(int which)
which
- number of the door to be checked. Use the
constants defined in DoorService
.public String toString()
toString
in class AbstractService
public static void main(String[] argv) throws Exception
argv
-
Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |