public static function fromNative()
    {
        $args = \func_get_args();

        if (\count($args) < 2 || \count($args) > 3) {
            throw new \BadMethodCallException('You must provide 2 to 3 arguments: 1) latitude, 2) longitude, 3) valid ellipsoid type (optional)');
        }

        $coordinate = new BaseCoordinate(array($args[0], $args[1]));
        $latitude  = Latitude::fromNative($coordinate->getLatitude());
        $longitude = Longitude::fromNative($coordinate->getLongitude());

        $nativeEllipsoid = isset($args[2]) ? $args[2] : null;
        $ellipsoid = Ellipsoid::fromNative($nativeEllipsoid);

        return new self($latitude, $longitude, $ellipsoid);
    }
public static function fromNative()
    {
        $args = \func_get_args();

        if (\count($args) < 2 || \count($args) > 3) {
            throw new \BadMethodCallException('You must provide 2 to 3 arguments: 1) latitude, 2) longitude, 3) valid ellipsoid type (optional)');
        }

        $coordinate = new BaseCoordinate(array($args[0], $args[1]));
        $latitude  = Latitude::fromNative($coordinate->getLatitude());
        $longitude = Longitude::fromNative($coordinate->getLongitude());

        $nativeEllipsoid = isset($args[2]) ? $args[2] : null;
        $ellipsoid = Ellipsoid::fromNative($nativeEllipsoid);

        return new self($latitude, $longitude, $ellipsoid);
    }
public static function fromNative ( ) { $ args = \ func_get_args ( ) ; if ( \ count ( $ args ) < 2 || \ count ( $ args ) > 3 ) { throw new \ BadMethodCallException ( 'You must provide 2 to 3 arguments: 1) latitude, 2) longitude, 3) valid ellipsoid type (optional)' ) ; } $ coordinate = new BaseCoordinate ( array ( $ args [ 0 ] , $ args [ 1 ] ) ) ; $ latitude = Latitude :: fromNative ( $ coordinate -> getLatitude ( ) ) ; $ longitude = Longitude :: fromNative ( $ coordinate -> getLongitude ( ) ) ; $ nativeEllipsoid = isset ( $ args [ 2 ] ) ? $ args [ 2 ] : null ; $ ellipsoid = Ellipsoid :: fromNative ( $ nativeEllipsoid ) ; return new self ( $ latitude , $ longitude , $ ellipsoid ) ; }
Returns a new Coordinate object from native PHP arguments

@return self
@throws \BadMethodCallException
Returns a new Coordinate object from native PHP arguments