Skip to the content.

phpGPX\Models\GpxFile

Class GpxFile Representation of GPX file.

Properties

$waypoints

public array<mixed,\phpGPX\Models\Point> $waypoints

A list of waypoints.

$routes

public array<mixed,\phpGPX\Models\Route> $routes

A list of routes.

$tracks

public array<mixed,\phpGPX\Models\Track> $tracks

A list of tracks.

$metadata

public \phpGPX\Models\Metadata $metadata

Metadata about the file.

The original GPX 1.1 attribute.

$extensions

public \phpGPX\Models\Extensions $extensions

$creator

public string $creator

Creator of GPX file.

Methods

__construct

mixed phpGPX\Models\GpxFile::__construct()

GpxFile constructor.

toArray

array phpGPX\Models\Summarizable::toArray()

Serialize object to array

toJSON

string phpGPX\Models\GpxFile::toJSON()

Return JSON representation of GPX file with statistics.

toXML

\DOMDocument phpGPX\Models\GpxFile::toXML()

Create XML representation of GPX file.

save

mixed phpGPX\Models\GpxFile::save(string $path, string $format)

Save data to file according to selected format.

Arguments