pamvotis.core
Class Params

java.lang.Object
  extended by pamvotis.core.Params

public class Params
extends java.lang.Object

Contains the parameters of a node, like coverage, position, data rate e.t.c

Author:
Dimitris El. Vassis

Constructor Summary
Params()
           
 
Method Summary
 int DistFrom(int fromx, int fromy)
          Calculates the distance of the specific node from another node.
 void InitParams(int id, int rate, int x, int y, int coverage, int ac, float aifsd, int cwMin, int cwMax)
          Initializes the parameters of a node.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Params

public Params()
Method Detail

InitParams

public void InitParams(int id,
                       int rate,
                       int x,
                       int y,
                       int coverage,
                       int ac,
                       float aifsd,
                       int cwMin,
                       int cwMax)
Initializes the parameters of a node.

Parameters:
id - The ID of the node
rate - The data rate of a node. Users should be careful when setting the data rate, as it must conform the data rates that the physical layer supports. Pamvotis supports data rate agility, meaning that the data rate can change according to the distance from another node, but users must pay attention to the data rates that can be supported by each physical layer.
x - The x-axis position coordinate in meters.
y - The y-axis position coordinate in meters.
coverage - The node's coverage in meters.
ac - The 802.11e access category 0,1,2,3
aifsd - The aifsd parameter, according to the access category
cwMin - The minimum contention window
cwMax - The maximum contention window

DistFrom

public int DistFrom(int fromx,
                    int fromy)
Calculates the distance of the specific node from another node.

Parameters:
fromx - The x-distance from the other node, e.g. specificNode.x-anotnerNode.x
fromy - The y-distance from the other node, e.g. specificNode.y-anotnerNode.y
Returns:
The distance from the other node in meters.