?? overview-2.html.svn-base
字號:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<HTML>
<HEAD>
<META NAME="GENERATOR" CONTENT="SGML-Tools 1.0.6">
<TITLE>A quick overview of JNS: Packages</TITLE>
<LINK HREF="Overview-3.html" REL=next>
<LINK HREF="Overview-1.html" REL=previous>
<LINK HREF="Overview.html#toc2" REL=contents>
</HEAD>
<BODY>
<A HREF="Overview-3.html">Next</A>
<A HREF="Overview-1.html">Previous</A>
<A HREF="Overview.html#toc2">Contents</A>
<HR>
<H2><A NAME="s2">2. Packages</A></H2>
<P>JNS, like every modern piece of software, is not one huge piece of code but
partitioned into subsystems. The packages in JNS are divided by functionality:
<UL>
<LI><B>jns.element</B> - contains the static elements of the network,
nodes, links, etc. Read the "Structure" file included here for a beginner's
introduction on the way networks are built in JNS.</LI>
<LI><B>jns.agent</B> - contains the interfaces for agents. If you are
building a new protocol, it has to implement one of them. Your protocol might
be quite fancy so <CODE>CL_Agent</CODE> or <CODE>CO_Agent</CODE> might be too
restrictive for you. In that case, you still have to implement <CODE>Agent</CODE>
because, as you will see, your protocol has to attach to a lower level
protocol using this interface.</LI>
<LI><B>jns.trace</B> - contains everything that is necessary to snoop at
what is going on in the network. A class is provided to turn events in the
network into output suitable for use with <I>Javis</I> or <I>NAM</I>.</LI>
<LI><B>jns.command</B> - not a very interesting package, apart from the
<CODE>Command</CODE> abstract class which you will almost certainly extend if you
write a new protocol. You can use this to schedule calls to your functions
with the simulator.</LI>
<LI><B>jns.util</B> - utilities, tools, etc. Contains an implementation
of a Queue data structure (not a networking queue!), a priority queue, the
<CODE>IPAddr</CODE> class, the <CODE>Preferences</CODE> class, etc. Feel free to use
them in your algorithms (everybody who has the Simulator has those classes,
so practice some code reuse).</LI>
</UL>
<P>
<P>
<HR>
<A HREF="Overview-3.html">Next</A>
<A HREF="Overview-1.html">Previous</A>
<A HREF="Overview.html#toc2">Contents</A>
</BODY>
</HTML>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -