SugarCubes v3.1 are 100% pure Java implementation, designed to work on a Java 1.1 compliant platform. Earlier version do not work because of the use of 1.1 specific Java API.
Note: In order to compile SugarCubes sources you need at least the JDK 1.1.8.
Bugs in previous versions of the compiler can lead to problems in the
compiling process.
Contents
The package inria.meije.rc.sugarcubes contains the programming
interface of the SugarCubes framework. The user founds in it Java
interfaces and classes needed for building and executing reactive
programms. The inner package
inria.meije.rc.sugarcubes.implementation contains classes
implementing reactive primitives of the SugarCubes and classes
implementing reactive machines and execution environment.
The package junior contains the programming
interface of the Junior interface to the SugarCubes framework.
The user founds in it Java interfaces and classes needed for
building and executing reactive programms using the Junior API.
The inner package junior.kernel implements the translation
of junior programs into SugarCubes equivalent programs.
The package inria.meije.rc.sugarcubes.implementation.io
contains implementation of helper classes to access standard output.
Installation
Just add SugarCubesv3.1b3.jar to your CLASSPATH and start developing great reactive programs.
New features in v3.1
Some modifications have been made since the previous distribution:
added a Kill instruction in addition to the Until instruction.
added emptyMachine constructors to the SC class in order to replace
in future versions of the SugarCubes the badly named voidMachine constructors.
added a junior interface to the SugarCubes which allows one to write SugarCubes
programs using the Junior API. It almost complies to the Junior semantics.
added an EventFreezable instruction in addition to the Freezable instruction
of Sugarcubes to comply to the Junior semantics.
added methods to the ReactiveEngine interface in order to deal with values of events
at the previous instant.
added a couple of variables to identify the SugarCubes version :
SC.version
SC.generation_date
don't forget to put these informations if you submit a bug report.
added an instruction to execute an atomic action at the end of the instant.
This is similar to a task executed at the end of an instant. But it is
defined into a program and so it can be controlled, preempted, etc ...
This will be also an efficient replacement to the Callback instruction, as at the
end of the instant one can ask for all the occurrences of the event and treat
all of them in one efficient loop. It can also discard values or implement
whatever policy in the treatment of the valued occurrences of one or more
events.
Modification of the mechanism of minimal time of a reaction : added a method
reactNotBlocking() which returns immediately after reaction but returns
and doesn't execute a new reaction until the minimal duration last.
The method returns the time remaining to wait until the next reaction ca take
place. if the value is negative the machine has terminated its program. If the
standard react method is called, the react block for the remaining time if
needed until processing the next reaction.
The global performances of the package should also increase since the 3.0 release.