J-Sim v1.2.1-p7 API

drcl.intserv
Class SchedulerConfig

java.lang.Object
  extended bydrcl.comp.Contract
      extended bydrcl.intserv.SchedulerConfig

public class SchedulerConfig
extends Contract

The SchedulerConfiguration contract. This contract defines three services at the reactor:

AdspecProcessing
The initiator sends a SpecAd and in response, the reactor sends back the upated adspec.
FlowspecAddition
The initiator sends a message that consists of:
  1. an integer of value 0 (the "add" command);
  2. the set of ToS values (long[]) associated with the flowspec, could be null;
  3. the set of ToS mask values (long[]) associated with the ToS values, could be null, and
  4. the flowspec (SpecFlow).
In response, the reactor returns null and the handle number is set in the flowspec if the flowspec is sucessfully installed, or returns another flowspec that reflects the availability of the resources if failed.
FlowspecModification
The initiator sends a message that has the same format as a FlowspecAddition except that the first field is an integer of value 1 (the "modify" command). The second and the third fields are not used. The response is the same as that of FlowspecAddition. In case that the request is failed, the previous installation is intact.
FlowspecRemoval
The initiator sends a message that consists of:
  1. an integer of value 2 (the "remove" command);
  2. the handle of the flowspec to be removed
In response, the reactor removes the flowspec and returns the removed flowspec.
FlowspecQuery
The initiator sends a message that has the same format as a FlowspecRemoval except that the first field is an integer of value 3 (the "query" command). Use negative handle to query all the installed flowspecs. In response, the reactor returns the queried flowspec(s).


Nested Class Summary
static class SchedulerConfig.Message
           
 
Field Summary
static int ADD
           
static SchedulerConfig INSTANCE
           
static int MODIFY
           
static int QUERY
           
static int REMOVE
           
 
Fields inherited from class drcl.comp.Contract
Role_INITIATOR, Role_PEER, Role_REACTOR
 
Constructor Summary
SchedulerConfig()
           
SchedulerConfig(int role_)
           
 
Method Summary
static SpecFlow add(long[] tos_, long[] tosmask_, SpecFlow fspec_, Port out_)
           
 java.lang.Object getContractContent()
          Returns the content of this contract (format?).
 java.lang.String getName()
           
static SpecFlow modify(SpecFlow fspec_, Port out_)
           
static SpecFlow query(int handle_, Port out_)
           
static SpecFlow[] queryAll(Port out_)
           
static SpecFlow remove(int handle_, Port out_)
           
 
Methods inherited from class drcl.comp.Contract
getRole, match, setRole
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INSTANCE

public static final SchedulerConfig INSTANCE

ADD

public static final int ADD
See Also:
Constant Field Values

MODIFY

public static final int MODIFY
See Also:
Constant Field Values

REMOVE

public static final int REMOVE
See Also:
Constant Field Values

QUERY

public static final int QUERY
See Also:
Constant Field Values
Constructor Detail

SchedulerConfig

public SchedulerConfig()

SchedulerConfig

public SchedulerConfig(int role_)
Method Detail

getName

public java.lang.String getName()
Specified by:
getName in class Contract

getContractContent

public java.lang.Object getContractContent()
Description copied from class: Contract
Returns the content of this contract (format?).

Specified by:
getContractContent in class Contract

add

public static SpecFlow add(long[] tos_,
                           long[] tosmask_,
                           SpecFlow fspec_,
                           Port out_)

modify

public static SpecFlow modify(SpecFlow fspec_,
                              Port out_)

remove

public static SpecFlow remove(int handle_,
                              Port out_)

query

public static SpecFlow query(int handle_,
                             Port out_)

queryAll

public static SpecFlow[] queryAll(Port out_)

J-Sim v1.2.1-p7 API

Copyright © 1998-2003 Distributed Real-time Computing Lab (DRCL). All Rights Reserved.     ~ To J-Sim Home ~