createFromArray() public static method

public static createFromArray ( $config ) : Ellipsoid
$config
return Ellipsoid
コード例 #1
0
ファイル: HaversineTest.php プロジェクト: jasonshaw/phpgeo
 /**
  * Sets up the fixture, for example, opens a network connection.
  * This method is called before a test is executed.
  */
 protected function setUp()
 {
     $ellipsoidConfig = array('name' => 'WGS-84', 'a' => 6378137.0, 'f' => 298.257223563);
     $this->ellipsoid = Ellipsoid::createFromArray($ellipsoidConfig);
     $this->calculator = new Haversine();
 }
コード例 #2
0
ファイル: VincentyTest.php プロジェクト: mjaschen/phpgeo
 /**
  * Sets up the fixture, for example, opens a network connection.
  * This method is called before a test is executed.
  */
 protected function setUp()
 {
     $ellipsoidConfig = ['name' => 'WGS-84', 'a' => 6378137.0, 'f' => 298.257223563];
     $this->ellipsoid = Ellipsoid::createFromArray($ellipsoidConfig);
 }
コード例 #3
0
ファイル: CoordinateTest.php プロジェクト: martinsv/phpgeo
 /**
  * Sets up the fixture, for example, opens a network connection.
  * This method is called before a test is executed.
  */
 protected function setUp()
 {
     $ellipsoidConfig = array('name' => 'WGS-84', 'a' => 6378137.0, 'f' => 298.257223563);
     $this->ellipsoid = Ellipsoid::createFromArray($ellipsoidConfig);
     $this->coordinate = new Coordinate(52.5, 13.5, $this->ellipsoid);
 }