--- android/TrainInfoService/src/dk/thoerup/traininfoservice/banedk/DepartureServlet.java 2010/07/07 18:54:52 968 +++ android/TrainInfoService/src/dk/thoerup/traininfoservice/banedk/DepartureServlet.java 2010/07/09 21:02:13 969 @@ -95,7 +95,7 @@ if (format.equalsIgnoreCase("xml")) { resp.setContentType("text/xml"); - resp.getWriter().print( formatXml(beans, stationName) ); + resp.getWriter().print( formatXml(beans, stationName, arrival) ); } else if (format.equalsIgnoreCase("html")) { String advStr = req.getParameter("advanced"); @@ -112,7 +112,7 @@ } - protected String formatXml(List beans, String stationName) throws ServletException{ + protected String formatXml(List beans, String stationName, boolean arrival) throws ServletException{ String xml = ""; try { DocumentBuilder builder = docBuilderFactory.newDocumentBuilder(); @@ -122,6 +122,7 @@ Document doc = impl.createDocument(null,null,null); Element root = doc.createElement("departureinfo"); root.setAttribute("station", stationName); + root.setAttribute("arrival", Boolean.toString(arrival) ); for (DepartureBean departure : beans) { Element train = doc.createElement("train");