Conditions | 2 |
Paths | 2 |
Total Lines | 14 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 6 |
Changes | 0 |
1 | <?php |
||
28 | * |
||
29 | * @return ImageOverlay |
||
30 | * @throws ParseException |
||
31 | */ |
||
32 | public function parse( $value ) { |
||
33 | $parameters = explode( '~', $value ); |
||
34 | $imageParameters = explode( ':', $parameters[0], 3 ); |
||
35 | |||
36 | if ( count( $imageParameters ) === 3 ) { |
||
37 | $boundsNorthEast = $this->stringToLatLongValue( $imageParameters[0] ); |
||
38 | $boundsSouthWest = $this->stringToLatLongValue( $imageParameters[1] ); |
||
39 | $imageUrl = \MapsMapper::getFileUrl( $imageParameters[2] ); |
||
|
|||
40 | |||
41 | return new ImageOverlay( $boundsNorthEast, $boundsSouthWest, $imageUrl ); |
||
42 | } |
||
58 |
This method has been deprecated.