Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

engine
Class ValueChangeMonitor  view ValueChangeMonitor download ValueChangeMonitor.java

java.lang.Object
  extended byengine.ValueChangeMonitor
All Implemented Interfaces:
Monitor

class ValueChangeMonitor
extends java.lang.Object
implements Monitor

It's is a monitor that watches for the change of an expression, and then wakes up the associated thread (and, now and then, it gets stuck, i don't jnow why...)


Field Summary
(package private)  BitVector curValue
           
(package private) static int EVT_CHANGE
           
(package private) static int EVT_NEGEDGE
           
(package private) static int EVT_POSEDGE
           
(package private)  boolean isOn
           
(package private)  long lastTime
           
(package private)  BitVector lastValue
           
(package private)  int mask
           
(package private)  NameSpace ns
           
(package private)  Expression target
           
(package private)  java.lang.Object waiter
           
 
Constructor Summary
(package private) ValueChangeMonitor(NameSpace ns, Expression target, int mask)
           
 
Method Summary
(package private)  void attach(java.lang.Object semaphore)
           
(package private)  void consume()
           
(package private)  void detach()
           
(package private)  boolean isTriggd()
           
 java.lang.String toString()
          Convert this Object to a human-readable String.
 void trigger()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

ns

NameSpace ns

target

Expression target

lastValue

BitVector lastValue

curValue

BitVector curValue

lastTime

long lastTime

waiter

java.lang.Object waiter

isOn

volatile boolean isOn

EVT_CHANGE

static final int EVT_CHANGE
See Also:
Constant Field Values

EVT_POSEDGE

static final int EVT_POSEDGE
See Also:
Constant Field Values

EVT_NEGEDGE

static final int EVT_NEGEDGE
See Also:
Constant Field Values

mask

int mask
Constructor Detail

ValueChangeMonitor

ValueChangeMonitor(NameSpace ns,
                   Expression target,
                   int mask)
Method Detail

trigger

public void trigger()
             throws InterpretTimeException
Specified by:
trigger in interface Monitor

attach

void attach(java.lang.Object semaphore)

consume

void consume()

detach

void detach()

isTriggd

boolean isTriggd()

toString

public java.lang.String toString()
Description copied from class: java.lang.Object
Convert this Object to a human-readable String. There are no limits placed on how long this String should be or what it should contain. We suggest you make it as intuitive as possible to be able to place it into System.out.println() 55 and such.

It is typical, but not required, to ensure that this method never completes abruptly with a java.lang.RuntimeException.

This method will be called when performing string concatenation with this object. If the result is null, string concatenation will instead use "null".

The default implementation returns getClass().getName() + "@" + Integer.toHexString(hashCode()).