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