public int getTotalSeconds() {
        final float s = nodes.size() < 2 ? 0 : nodes.get(nodes.size() - 1).getTime() - nodes.get(0).getTime();
        return (int) (s + 0.5);
    }
writes the track in binary-format to a file

@param filename the filename to write to
main/src/main/java/cgeo/geocaching/brouter/core/OsmTrack.java