source: tmcsimulator/trunk/src/atmsdriver/model/Highway.java @ 212

Revision 212, 888 bytes checked in by jtorres, 9 years ago (diff)

branches/FEPSimulator/tests/HighwaysParserTest.cpp: Unit test for HighwaysParser?.cpp. HighwaysTest?.java: now passing toXML(), added test for toCondensedFormat() method. LoadHighwaysTest?.java: passing. LoadSadDotsTest?.java: conformed to changes, not passing. Highway.java/Highways.java: converted class attributes to List instead of ArrayList?. Highways.java: corrected toCondensedFormat() method comments and added comments throughout file.

Line 
1package atmsdriver.model;
2
3import java.util.ArrayList;
4import java.util.List;
5
6/**
7 * Highway represents a freeway that has two directions of traffic. A highway is
8 * identified by its highway number.  A highway contains lane detector stations,
9 * called Stations, along its length.
10 *
11 * @author jdalbey
12 */
13final public class Highway
14{
15    /** The identifying number for this highway, e.g., 101 */
16    public final Integer routeNumber;
17    /** The ordered list of stations (lane detector stations) on this highway */
18    public final List<Station> stations;
19
20    /** Construct a highway
21     *
22     * @param highwayNum integer identifier for this highway
23     * @param stations ordered list of stations on this highway
24     */
25    public Highway(Integer routeNumber, ArrayList<Station> stations)
26    {
27        this.routeNumber = routeNumber;
28        this.stations = stations;
29    }
30}
Note: See TracBrowser for help on using the repository browser.