All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class syd.Daemon

java.lang.Object
   |
   +----syd.Daemon

public class Daemon
extends Object
This is the main program of the syd package


Constructor Index

 o Daemon()

Method Index

 o best_clock()
ACCESSOR: selects one of the logical clocks based on some policy (work on progress...)
 o is_verbose()
ACCESSOR: tests whether this daemon was asked to be verbose
 o load_descriptions(String[])
MUTATOR: loads the session descriptions from the command line and from the (optional) configuration file.
 o logical_clocks_report()
ACCESSOR: builds a report of the current state of the clocks controlled by this Daemon
 o main(String[])
 o restart_one()
MUTATOR: restarts one of the logical clock synchronization sessions.
 o start_all()
MUTATOR: Starts all sessions: prints on the standard output a message as the operation proceeds (one line).

Constructors

 o Daemon
 public Daemon()

Methods

 o main
 public static void main(String argv[]) throws Exception
 o load_descriptions
 public static void load_descriptions(String s[]) throws ConfigurationLineException, IOException, DataConsistencyException, CommandLineException
MUTATOR: loads the session descriptions from the command line and from the (optional) configuration file. Prints two message lines.

Parameters:
s - the array of Strings containing the command line arguments
 o restart_one
 public static int restart_one() throws InterruptedException
MUTATOR: restarts one of the logical clock synchronization sessions. Returns the index of the restarted session. The policy is fair, but random.

Returns:
an int indicating the restarted session, or -1 if all sessions are active
 o start_all
 public static void start_all() throws InterruptedException
MUTATOR: Starts all sessions: prints on the standard output a message as the operation proceeds (one line).

 o is_verbose
 public static boolean is_verbose()
ACCESSOR: tests whether this daemon was asked to be verbose

Returns:
a boolean that is true if daemon is verbose
 o best_clock
 public static byte[] best_clock()
ACCESSOR: selects one of the logical clocks based on some policy (work on progress...)

Returns:
the encoding of a selected logical clock among those managed by this daemon if at least one clock is in contact, otherwise the null pointer
See Also:
encode
 o logical_clocks_report
 public static String logical_clocks_report()
ACCESSOR: builds a report of the current state of the clocks controlled by this Daemon

Returns:
a String that represents the logicalclocks

All Packages  Class Hierarchy  This Package  Previous  Next  Index