Skip to the content.

phpGPX\phpGPX

Class phpGPX

Constants

JSON_FORMAT

const JSON_FORMAT = 'json'

XML_FORMAT

const XML_FORMAT = 'xml'

PACKAGE_NAME

const PACKAGE_NAME = 'phpGPX'

VERSION

const VERSION = '1.0'

Properties

$CALCULATE_STATS

public boolean $CALCULATE_STATS = true

Create Stats object for each track, segment and route

$SORT_BY_TIMESTAMP

public boolean $SORT_BY_TIMESTAMP = false

Additional sort based on timestamp in Routes & Tracks on XML read.

Disabled by default, data should be already sorted.

$DATETIME_FORMAT

public string $DATETIME_FORMAT = 'c'

Default DateTime output format in JSON serialization.

$DATETIME_TIMEZONE_OUTPUT

public string $DATETIME_TIMEZONE_OUTPUT = 'UTC'

Default timezone for display.

Data are always stored in UTC timezone.

$PRETTY_PRINT

public boolean $PRETTY_PRINT = true

Pretty print.

Methods

load

\phpGPX\Models\GpxFile phpGPX\phpGPX::load($path)

Load GPX file.

Arguments

parse

\phpGPX\Models\GpxFile phpGPX\phpGPX::parse($xml)

Parse GPX data string.

Arguments

getSignature

string phpGPX\phpGPX::getSignature()

Create library signature from name and version.