NS3-GUI-HELPER V1.2.0
A code generator for NS-3 Scripts
Loading...
Searching...
No Matches
GuiRenderers.TopologyPainter Class Reference
Inheritance diagram for GuiRenderers.TopologyPainter:

Public Member Functions

 TopologyPainter (ArrayList< NodePainter > n, ArrayList< P2pLinkPainter > l)
 
 TopologyPainter (ArrayList< NodePainter > n, ArrayList< P2pLinkPainter > l, int w, int h)
 
void paint (Graphics g)
 
Dimension getPreferredSize ()
 
void addNode (NodePainter node)
 
void addLink (P2pLinkPainter link)
 
void addLink (CsmaLinkPainter link)
 
void addLink (WifiLinkPainter link)
 
void addRefNode (NodePainter node)
 
void addAndPrintRefNode (NodePainter node)
 
void addAndPrintNode (NodePainter node)
 
void addAndPrintLink (CsmaLinkPainter link)
 
void addAndPrintLink (P2pLinkPainter link)
 
void addAndPrintLink (WifiLinkPainter link)
 
int pointCollideWithAny (int x, int y)
 
void enableView (int s, int c)
 
ArrayList< NodePaintergetNodes ()
 
void setNodes (ArrayList< NodePainter > nodes)
 
ArrayList< P2pLinkPaintergetLinks ()
 
void setLinks (ArrayList< P2pLinkPainter > links)
 
ArrayList< NodePaintergetReferenceNodes ()
 
void setReferenceNodes (ArrayList< NodePainter > referenceNodes)
 
ArrayList< CsmaLinkPaintergetLinks_csma ()
 
void setLinks_csma (ArrayList< CsmaLinkPainter > links_csma)
 

Detailed Description

for painting the objects on the canvas this will be centrally responsible entity

Definition at line 14 of file TopologyPainter.java.

Constructor & Destructor Documentation

◆ TopologyPainter() [1/2]

GuiRenderers.TopologyPainter.TopologyPainter ( ArrayList< NodePainter > n,
ArrayList< P2pLinkPainter > l )

to create an object of type Topology Painter

Parameters
nlist of nodes
llist of links
See also
TopologyPainter::TopologyPainter(ArrayList, ArrayList, int, int)
Since
0.3.0

Definition at line 69 of file TopologyPainter.java.

◆ TopologyPainter() [2/2]

GuiRenderers.TopologyPainter.TopologyPainter ( ArrayList< NodePainter > n,
ArrayList< P2pLinkPainter > l,
int w,
int h )

to create an object of type Topology Painter

Parameters
nlist of nodes
llist of links
wthe width of the canvas
hthe height of the canvas
See also
TopologyPainter::TopologyPainter(ArrayList, ArrayList)
Since
0.3.0

Definition at line 83 of file TopologyPainter.java.

Member Function Documentation

◆ addAndPrintLink() [1/3]

void GuiRenderers.TopologyPainter.addAndPrintLink ( CsmaLinkPainter link)

to add the link and direct painting

Parameters
linkthe link to be added
Since
0.3.0

Definition at line 253 of file TopologyPainter.java.

◆ addAndPrintLink() [2/3]

void GuiRenderers.TopologyPainter.addAndPrintLink ( P2pLinkPainter link)

to add the link and direct painting

Parameters
linkthe link to be added
Since
0.3.0

Definition at line 265 of file TopologyPainter.java.

◆ addAndPrintLink() [3/3]

void GuiRenderers.TopologyPainter.addAndPrintLink ( WifiLinkPainter link)

to add the link and direct painting

Parameters
linkthe link to be added
Since
1.2.0

Definition at line 277 of file TopologyPainter.java.

◆ addAndPrintNode()

void GuiRenderers.TopologyPainter.addAndPrintNode ( NodePainter node)

to add the node and direct painting

Parameters
nodethe node to be added
Since
0.3.0

Definition at line 241 of file TopologyPainter.java.

◆ addAndPrintRefNode()

void GuiRenderers.TopologyPainter.addAndPrintRefNode ( NodePainter node)

to add the reference node and directly painting

Parameters
nodethe node to be added
Since
1.1.0

Definition at line 229 of file TopologyPainter.java.

◆ addLink() [1/3]

void GuiRenderers.TopologyPainter.addLink ( CsmaLinkPainter link)

to add the CSMA link for painting

Parameters
linkthe link to be added
See also
TopologyPainter::addLink(P2pLinkPainter)
Since
0.3.0

Definition at line 194 of file TopologyPainter.java.

◆ addLink() [2/3]

void GuiRenderers.TopologyPainter.addLink ( P2pLinkPainter link)

to add the P2P link for painting

Parameters
linkthe link to be added
See also
TopologyPainter::addLink(CsmaLinkPainter)
Since
0.3.0

Definition at line 181 of file TopologyPainter.java.

◆ addLink() [3/3]

void GuiRenderers.TopologyPainter.addLink ( WifiLinkPainter link)

to add the Wi-Fi link for painting

Parameters
linkthe link to be added
Since
1.2.0

Definition at line 206 of file TopologyPainter.java.

◆ addNode()

void GuiRenderers.TopologyPainter.addNode ( NodePainter node)

to add nodes for painting

Parameters
nodethe node to be added
Since
0.3.0

Definition at line 169 of file TopologyPainter.java.

◆ addRefNode()

void GuiRenderers.TopologyPainter.addRefNode ( NodePainter node)

to add the reference node

Parameters
nodethe node to be added
Since
1.1.0

Definition at line 218 of file TopologyPainter.java.

◆ enableView()

void GuiRenderers.TopologyPainter.enableView ( int s,
int c )

to enabling highlighting of the server and client node

Parameters
sserver index
cclient index
Since
1.0.0

Definition at line 313 of file TopologyPainter.java.

◆ getLinks()

ArrayList< P2pLinkPainter > GuiRenderers.TopologyPainter.getLinks ( )

Definition at line 351 of file TopologyPainter.java.

◆ getLinks_csma()

ArrayList< CsmaLinkPainter > GuiRenderers.TopologyPainter.getLinks_csma ( )

Definition at line 371 of file TopologyPainter.java.

◆ getNodes()

ArrayList< NodePainter > GuiRenderers.TopologyPainter.getNodes ( )

Definition at line 341 of file TopologyPainter.java.

◆ getPreferredSize()

Dimension GuiRenderers.TopologyPainter.getPreferredSize ( )

Definition at line 158 of file TopologyPainter.java.

◆ getReferenceNodes()

ArrayList< NodePainter > GuiRenderers.TopologyPainter.getReferenceNodes ( )

Definition at line 361 of file TopologyPainter.java.

◆ paint()

void GuiRenderers.TopologyPainter.paint ( Graphics g)

to paint the objects on the canvas

Parameters
gthe graphics in the CANVAS
Since
0.3.0

Definition at line 104 of file TopologyPainter.java.

◆ pointCollideWithAny()

int GuiRenderers.TopologyPainter.pointCollideWithAny ( int x,
int y )

to get the index of node, with which the mouse is collided

Parameters
xx-position of the mouse
yy-position of the mouse
Returns
the integer value, representing the index of the first collided node, and it will return -1, in case not collided with any of the node
Since
0.3.0

Definition at line 292 of file TopologyPainter.java.

◆ setLinks()

void GuiRenderers.TopologyPainter.setLinks ( ArrayList< P2pLinkPainter > links)

Definition at line 356 of file TopologyPainter.java.

◆ setLinks_csma()

void GuiRenderers.TopologyPainter.setLinks_csma ( ArrayList< CsmaLinkPainter > links_csma)

Definition at line 376 of file TopologyPainter.java.

◆ setNodes()

void GuiRenderers.TopologyPainter.setNodes ( ArrayList< NodePainter > nodes)

Definition at line 346 of file TopologyPainter.java.

◆ setReferenceNodes()

void GuiRenderers.TopologyPainter.setReferenceNodes ( ArrayList< NodePainter > referenceNodes)

Definition at line 366 of file TopologyPainter.java.


The documentation for this class was generated from the following file: