DRCL J-Sim API

drcl.net.traffic
Class traffic_Periodic

java.lang.Object
  extended bydrcl.DrclObj
      extended bydrcl.net.traffic.TrafficModel
          extended bydrcl.net.traffic.traffic_Periodic
All Implemented Interfaces:
java.lang.Cloneable, ObjectCloneable, ObjectDuplicable, java.io.Serializable, TrafficPeriodic

public class traffic_Periodic
extends TrafficModel
implements TrafficPeriodic

This class describes a periodic traffic model. It defines the following parameters:

C
The maximum number of bytes that are allowed in a period.
P
The period (second).
Maximum Packet Size
The maximum size of a packet (byte).

See Also:
Serialized Form

Field Summary
 int C
           
 int maxPacketSize
           
 double P
           
 
Constructor Summary
traffic_Periodic()
           
traffic_Periodic(int c_, double p_, int mtu_)
           
 
Method Summary
 void duplicate(java.lang.Object source_)
          opies the content of the source_ object to this object.
 int getBurst()
          Returns the maximum burstness that can be generated from this model instance (byte).
 int getC()
           
 double getLoad()
          Returns the load of this traffic model instance (bps).
 int getMaxPacketSize()
           
 int getMTU()
          Returns the maximum transmission unit (MTU) of this model instance (byte).
 double getPeriod()
          Returns the period in second.
 TrafficModel merge(TrafficModel that_)
          Merges this instance with the specified one and returns this instance.
 java.lang.String oneline()
          Prints and returns the parameters of this model instance in one line of String.
 void set(int c_, double p_, int mtu_)
           
 void setC(int c_)
           
 void setMaxPacketSize(int size_)
           
 void setPeriod(double p_)
           
 
Methods inherited from class drcl.DrclObj
clone, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

maxPacketSize

public int maxPacketSize

C

public int C

P

public double P
Constructor Detail

traffic_Periodic

public traffic_Periodic()

traffic_Periodic

public traffic_Periodic(int c_,
                        double p_,
                        int mtu_)
Method Detail

set

public void set(int c_,
                double p_,
                int mtu_)

getPeriod

public double getPeriod()
Description copied from interface: TrafficPeriodic
Returns the period in second.

Specified by:
getPeriod in interface TrafficPeriodic

getLoad

public double getLoad()
Description copied from class: TrafficModel
Returns the load of this traffic model instance (bps). It provides a general sense of how much traffic there is in this model instance.

Specified by:
getLoad in class TrafficModel

getBurst

public int getBurst()
Description copied from class: TrafficModel
Returns the maximum burstness that can be generated from this model instance (byte).

Specified by:
getBurst in class TrafficModel

merge

public TrafficModel merge(TrafficModel that_)
Description copied from class: TrafficModel
Merges this instance with the specified one and returns this instance.

Specified by:
merge in class TrafficModel

duplicate

public void duplicate(java.lang.Object source_)
Description copied from class: DrclObj
opies the content of the source_ object to this object. he subclass must implement this method to realize DrclObj.clone().

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

oneline

public java.lang.String oneline()
Description copied from class: TrafficModel
Prints and returns the parameters of this model instance in one line of String.

Specified by:
oneline in class TrafficModel

setMaxPacketSize

public void setMaxPacketSize(int size_)

getMaxPacketSize

public int getMaxPacketSize()

setC

public void setC(int c_)

getC

public int getC()

setPeriod

public void setPeriod(double p_)

getMTU

public int getMTU()
Description copied from class: TrafficModel
Returns the maximum transmission unit (MTU) of this model instance (byte).

Specified by:
getMTU in class TrafficModel

DRCL J-Sim API

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