DRCL J-Sim API

drcl.inet.sensorsim
Class TargetAgent

java.lang.Object
  extended bydrcl.DrclObj
      extended bydrcl.comp.Component
          extended bydrcl.net.Module
              extended bydrcl.inet.sensorsim.TargetAgent
All Implemented Interfaces:
ActiveComponent, java.lang.Cloneable, ObjectCloneable, ObjectDuplicable, java.io.Serializable

public class TargetAgent
extends Module
implements ActiveComponent

This class implements a target node in a wireless sensor network.

Version:
1.0, 12/19/2003
Author:
Ahmed Sobeih
See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class drcl.comp.Component
Component.Locks
 
Field Summary
static double BCAST_RATE
           
static double M_PI
           
static double MEAN
           
static double SAMPLE_RATE
           
static long SEED_RNG
           
static double SIN_FREQ
           
static int TARGET_GAUSSIAN
           
static int TARGET_SINUSOIDAL
           
static double VAR
           
 
Fields inherited from class drcl.net.Module
downPort, PortGroup_DOWN, PortGroup_UP, upPort
 
Fields inherited from class drcl.comp.Component
FLAG_COMPONENT_NOTIFICATION, FLAG_DEBUG_ENABLED, FLAG_DIRECT_OUTPUT_ENABLED, FLAG_ENABLED, FLAG_ERROR_ENABLED, FLAG_EVENT_ENABLED, FLAG_GARBAGE_DISPLAY_ENABLED, FLAG_GARBAGE_ENABLED, FLAG_PORT_NOTIFICATION, FLAG_STARTED, FLAG_STOPPED, FLAG_TRACE_ENABLED, FLAG_UNDEFINED_START, id, infoPort, locks, name, parent, PortGroup_DEFAULT_GROUP, PortGroup_EVENT, PortGroup_SERVICE, Root, Trace_DATA, Trace_SEND
 
Constructor Summary
TargetAgent()
           
 
Method Summary
 void duplicate(java.lang.Object source_)
          Duplicates the content of source_, including ID, name, child components and connections among them, to this component.
 java.lang.String getName()
          Returns the (informational) name of the component.
 void setBcastRate(double bcastRate_)
          Sets the broadcast rate with which the target node generates stimuli.
 void setSampleRate(double sampleRate_)
          Sets the sample rate with which the target node generates stimuli.
 int setTargetType(java.lang.String type_, double value)
          Sets how stimuli are generated: gaussian or sinusoidal.
 
Methods inherited from class drcl.net.Module
cancelTimeout, setTimeout, setTimeoutAt
 
Methods inherited from class drcl.comp.Component
addComponent, addComponent, addEventPort, addEventPort, addForkPort, addPort, addPort, addPort, addPort, addPort, addPort, addPort, addPort, addServerPort, addServerPort, cancelFork, connect, containsComponent, containsComponent, containsPort, debug, disconnectAll, disconnectAllPeers, disconnectAllPorts, drop, drop, error, error, expose, exposeEventPorts, exposePort, exposePort, exposePort, exposePort, exposePort, findAvailable, findAvailable, findAvailable, fork, forkAt, getAllComponents, getAllPorts, getAllPorts, getAllWiresInside, getAllWiresInsideOut, getAllWiresOut, getComponent, getComponentFlag, getComponentFlag, getContract, getContractHT, getContractHT, getDebugFlagsInBinary, getDebugLevelNames, getID, getParent, getPort, getPort, getRoot, getTime, iduplicate, info, isAncestorOf, isContainer, isDebugEnabled, isDebugEnabledAt, isDirectlyRelatedTo, isDirectOutputEnabled, isEnabled, isErrorNoticeEnabled, isEventExportEnabled, isGarbageDisplayEnabled, isGarbageEnabled, isPortRemovable, isStarted, isStopped, isTraceEnabled, lock, notify, notifyAll, operate, reboot, removeAll, removeAllComponents, removeAllPorts, removeAllPorts, removeComponent, removeComponent, removePort, removePort, removePort, reset, resume, run, sduplicate, send, sendAt, setComponentFlag, setComponentFlag, setDebugEnabled, setDebugEnabled, setDebugEnabledAt, setDebugEnabledAt, setDebugEnabledAt, setDirectOutputEnabled, setDirectOutputEnabled, setEnabled, setErrorNoticeEnabled, setErrorNoticeEnabled, setEventExportEnabled, setEventExportEnabled, setExecutionBoundary, setGarbageDisplayEnabled, setGarbageDisplayEnabled, setGarbageEnabled, setGarbageEnabled, setID, setID, setName, setPort, setPort, setTraceEnabled, setTraceEnabled, sleepFor, sleepUntil, stop, toString, unexpose, unlock, useLocalForkManager, useLocalForkManager, wait
 
Methods inherited from class drcl.DrclObj
clone
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TARGET_GAUSSIAN

public static final int TARGET_GAUSSIAN
See Also:
Constant Field Values

TARGET_SINUSOIDAL

public static final int TARGET_SINUSOIDAL
See Also:
Constant Field Values

BCAST_RATE

public static final double BCAST_RATE
See Also:
Constant Field Values

SAMPLE_RATE

public static final double SAMPLE_RATE
See Also:
Constant Field Values

MEAN

public static final double MEAN
See Also:
Constant Field Values

VAR

public static final double VAR
See Also:
Constant Field Values

SIN_FREQ

public static final double SIN_FREQ
See Also:
Constant Field Values

M_PI

public static final double M_PI
See Also:
Constant Field Values

SEED_RNG

public static final long SEED_RNG
See Also:
Constant Field Values
Constructor Detail

TargetAgent

public TargetAgent()
Method Detail

getName

public java.lang.String getName()
Description copied from class: Component
Returns the (informational) name of the component.

Overrides:
getName in class Component

duplicate

public void duplicate(java.lang.Object source_)
Description copied from class: Component
Duplicates the content of source_, including ID, name, child components and connections among them, to this component. Subclasses need to override this method to copy its own variables.

Specified by:
duplicate in interface ObjectDuplicable
Overrides:
duplicate in class Module

setSampleRate

public void setSampleRate(double sampleRate_)
Sets the sample rate with which the target node generates stimuli.


setBcastRate

public void setBcastRate(double bcastRate_)
Sets the broadcast rate with which the target node generates stimuli.


setTargetType

public int setTargetType(java.lang.String type_,
                         double value)
Sets how stimuli are generated: gaussian or sinusoidal.


DRCL J-Sim API

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