jamod at SF

net.wimpi.modbus.procimg
Class SimpleDigitalOut

java.lang.Object
  extended bynet.wimpi.modbus.procimg.SimpleDigitalOut
All Implemented Interfaces:
DigitalOut

public class SimpleDigitalOut
extends java.lang.Object
implements DigitalOut

Class implementing a simple DigitalOut.

The set method is synchronized, which ensures atomic access, but no specific access order.

Version:
1.2rc1 (09/11/2004)
Author:
Dieter Wimberger

Field Summary
protected  boolean m_Set
          Field for the digital out state.
 
Constructor Summary
SimpleDigitalOut()
          Constructs a new SimpleDigitalOut instance.
SimpleDigitalOut(boolean b)
          Constructs a new SimpleDigitalOut instance with the given state.
 
Method Summary
 boolean isSet()
          Tests if this DigitalOut is set.
 void set(boolean b)
          Sets the state of this DigitalOut.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_Set

protected boolean m_Set
Field for the digital out state.

Constructor Detail

SimpleDigitalOut

public SimpleDigitalOut()
Constructs a new SimpleDigitalOut instance. It's state will be invalid.


SimpleDigitalOut

public SimpleDigitalOut(boolean b)
Constructs a new SimpleDigitalOut instance with the given state.

Parameters:
b - true if set, false otherwise.
Method Detail

isSet

public boolean isSet()
Description copied from interface: DigitalOut
Tests if this DigitalOut is set.

Specified by:
isSet in interface DigitalOut
Returns:
true if set, false otherwise.

set

public void set(boolean b)
Description copied from interface: DigitalOut
Sets the state of this DigitalOut.

Specified by:
set in interface DigitalOut
Parameters:
b - true if to be set, false otherwise.

jamod at SF

Copyright © 2002-2004 jamod development team.