X-Git-Url: http://jaekl.net/gitweb/?p=frank.git;a=blobdiff_plain;f=report%2Fnet%2Fjaekl%2Ffrank%2Foctranspo%2FStopInfo.html;fp=report%2Fnet%2Fjaekl%2Ffrank%2Foctranspo%2FStopInfo.html;h=0000000000000000000000000000000000000000;hp=4e65791f19b1d19f931b3c9284d6a2363024b7c6;hb=c35af9e511e8390a66ca76331c3af43d0f0f7464;hpb=24f097b0fe78fa44f99b9f6f2e51a8e689d86a4a diff --git a/report/net/jaekl/frank/octranspo/StopInfo.html b/report/net/jaekl/frank/octranspo/StopInfo.html deleted file mode 100644 index 4e65791..0000000 --- a/report/net/jaekl/frank/octranspo/StopInfo.html +++ /dev/null @@ -1,528 +0,0 @@ - - -tests coverage - - - - - - - - - -
-Frames -No Frames -
-

- - - - - - - - - - - - - - - -
 %method%block%branch%line
net.jaekl.frank.octranspo.StopInfo
100%(9/9)
83%(24/29)
64%(14/22)
100%(32/32)
-

-

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
hit countmethod namemethod modifiersmethod signature
1<clinit>[static]void <clinit>()
5<init>[public]void <init>(java.lang.String,java.lang.String[],java.lang.Object[][])
11endContents[public]void endContents(java.lang.String,java.lang.String,java.lang.String,java.lang.String)
5endExternal[public]void endExternal(java.lang.String,java.lang.String,java.lang.String)
5getDescr[public]java.lang.String getDescr()
3getError[public]java.lang.String getError()
7getNumRoutes[public]int getNumRoutes()
6getRoute[public]net.jaekl.frank.octranspo.Route getRoute(int)
5getStopNo[public]int getStopNo()
-

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 1 
 package net.jaekl.frank.octranspo;
 2 
 
 3 
 import java.util.ArrayList;
 4 
 
 5 
 import net.jaekl.qd.xml.ParseResult;
 6 
 import net.jaekl.qd.xml.XmlParseException;
 7 
 
 8 Block: 1/1 
 public class StopInfo extends ParseResult
 9 
 {
 10 
 	// potential child tag names
 11 Block: 1/1 
 	public static String STOP_NO = "StopNo";
 12 
 	public static String DESCRIPTION = "StopDescription";	// Present in RouteSummary
 13 
 	public static String STOP_LABEL = "StopLabel";			// What NextTrips calls StopDescription
 14 
 	public static String ERROR = "Error";
 15 
 	public static String ROUTES = "Routes";
 16 
 	public static String ROUTE = "Route";
 17 
 
 18 
 	// data returned inside our element
 19 
 	int m_stopNo;
 20 
 	String m_descr;
 21 
 	String m_error;
 22 
 	ArrayList<Route> m_routes;
 23 
 
 24 
 	// Constructor
 25 
 	public StopInfo(String rootTagName, String[] internal, Object[][] external) {
 26 Block: 1/1 
 		super(rootTagName, internal, external);
 27 
 
 28 
 		m_stopNo = 0;
 29 
 		m_descr = "";
 30 
 		m_error = "";
 31 
 		m_routes = new ArrayList<Route>();
 32 
 	}
 33 
 
 34 
 	// -----------------------------
 35 
 	// Public methods to access data
 36 
 
 37 Block: 1/1 
 	public int getStopNo() { return m_stopNo; }
 38 Block: 1/1 
 	public String getDescr() { return m_descr; }
 39 Block: 1/1 
 	public String getError() { return m_error; }
 40 Block: 1/1 
 	public int getNumRoutes() { return m_routes.size(); }
 41 Block: 1/1 
 	public Route getRoute(int idx) { return m_routes.get(idx); }
 42 
 
 43 
 	// --------------------------
 44 
 	// ParseResult implementation
 45 
 
 46 
 	@Override
 47 
 	public void endContents(String uri, String localName, String qName, String chars) throws XmlParseException
 48 
 	{
 49 Block: 1/1 
 		assert (null != localName);
 50 
 
 51 Block: 1/1 Branch: 1/2 
 		if (localName.equals(STOP_NO)) {
 52 Block: 1/1 Branch: 1/1 
 			m_stopNo = Integer.parseInt(chars);
 53 
 		}
 54 Block: 1/1 Branch: 1/1 
 		else if (localName.equals(DESCRIPTION) || localName.equals(STOP_LABEL)) {
 55 Block: 1/1 Branch: 2/2 
 			m_descr = chars;
 56 
 		}
 57 Block: 1/1 Branch: 1/1 
 		else if (localName.equals(ERROR)) {
 58 Block: 1/1 Branch: 1/1 
 			m_error = chars;
 59 
 		}
 60 Block: 1/1 Branch: 1/1 
 	}
 61 
 	
 62 
 	@Override
 63 
 	public void endExternal(String uri, String localName, String qName) throws XmlParseException
 64 
 	{
 65 Block: 1/1 
 		if (localName.equals(ROUTE)) {
 66 Block: 1/1 Branch: 1/1 
 			ParseResult[] collected = collectParsedChildren(Route.class);
 67 
 			for (ParseResult pr : collected) {
 68 Block: 1/1 Branch: 1/1 
 				assert (pr instanceof Route);
 69 Block: 1/1 Branch: 1/2 
 				m_routes.add((Route)pr);
 70 
 			}
 71 
 		}
 72 Block: 1/1 Branch: 1/2 
 	}
 73 
 	
 74 
 	
 75 
 }
 76 
 
-

-

Report generated 11/12/14 11:31 PM
- -