KJB
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Namespaces | Macros | Functions
xml.cpp File Reference

Implementation of GPX format input and output. More...

#include <l/l_sys_lib.h>
#include <l/l_sys_mal.h>
#include <l/l_sys_io.h>
#include <l/l_error.h>
#include <l/l_debug.h>
#include <l/l_global.h>
#include <l/l_string.h>
#include <l_cpp/l_util.h>
#include <l_cpp/l_exception.h>
#include <l_cpp/l_stdio_wrap.h>
#include <sstream>
#include <topo_cpp/LatLong-UTMconversion.h>
#include <topo_cpp/xml.h>

Namespaces

 kjb
 Classes and functions for dealing with trajectory files.
 
 kjb::TopoFusion
 this namespace hold structures and code written by Scott Morris.
 

Macros

#define LATF   "lat=\"%.7f\""
 
#define LONF   "lon=\"%.6f\""
 
#define LATLONF   LATF " " LONF
 
#define DbgLog   kjb_c::test_pso
 
#define FILE_PEEK(buf)
 copy a short stretch of file into a character array buffer. More...
 

Functions

int kjb::TopoFusion::readTrack_GPX (const std::string &filename, layer *l)
 read a track from a named file into the pointed-to layer More...
 
int kjb::TopoFusion::writeTrack_GPX (const std::string &filename, const layer &l)
 write a track (stored in the indicated layer) into a named file More...
 

Detailed Description

Implementation of GPX format input and output.

Author
Scott Morris
Alan Morris
Andrew Predoehl
Warning
This is SO not threadsafe.

Originally from TopoFusion.

I (Andrew) made many superficial changes to port it into the KJB library. Also I added the table of leap seconds, and the policy of using them.

Macro Definition Documentation

#define DbgLog   kjb_c::test_pso

TopoFusion macro for debug messages

#define FILE_PEEK (   buf)
Value:
do \
{ \
using namespace kjb_c; \
ASSERT( xmlFile ); \
ASSERT( xmlPosition < xmlSize ); \
kjb_strncpy( (buf), xmlFile + xmlPosition, sizeof(buf) ); \
} while( 0 )
#define ASSERT(condition, message)
Definition: Assert.h:45

copy a short stretch of file into a character array buffer.

#define LATF   "lat=\"%.7f\""

printf-style format for latitude data

#define LATLONF   LATF " " LONF

printf-style format for lat,lon data

#define LONF   "lon=\"%.6f\""

printf-style format for longitude data