PHP Class Treffynnon\Navigator\Coordinate\DmsParser

Inheritance: extends ParserAbstract
Show file Open project: treffynnon/navigator Class Usage Examples

Protected Properties

Property Type Description
$input_format string A regular expression to run on the DMS string to extract its component parts
$output_format string The sprintf output format to use when printing the value

Public Methods

Method Description
get ( float $coord ) : string Get a string representation of the coordinate in DMS notation
parse ( string $coord ) : float Used when setting a value in the Coordinate class.

Method Details

get() public method

Get a string representation of the coordinate in DMS notation
public get ( float $coord ) : string
$coord float
return string

parse() public method

Used when setting a value in the Coordinate class.
public parse ( string $coord ) : float
$coord string
return float

Property Details

$input_format protected property

A regular expression to run on the DMS string to extract its component parts
protected string $input_format
return string

$output_format protected property

The sprintf output format to use when printing the value
protected string $output_format
return string