function testSetPointsAndSridInConstructor()
 {
     $points = array($this->testPointOne, $this->testPointTwo);
     $testLineString = new KVDgis_GeomLineString(31300, $points);
     $this->assertEquals($testLineString->getAsText(), 'LINESTRING(178000 212000, 100000 150000)');
     $this->assertEquals(31300, $testLineString->getSrid());
 }
 /**
  * createFromText
  *
  * @since   16 mei 2009
  * @throws  InvalidArgumentException    Indien de string ongeldig is.
  * @param   string              $wkt
  * @return  KVDgis_GeomGeometry
  */
 public static function createFromText($wkt)
 {
     if ($wkt == 'EMPTY') {
         $g = new KVDgis_GeomPoint();
         return $g;
     } elseif (substr($wkt, 0, 5) == 'POINT') {
         $g = new KVDgis_GeomPoint();
     } elseif (substr($wkt, 0, 10) == 'MULTIPOINT') {
         $g = new KVDgis_GeomMultipoint();
     } elseif (substr($wkt, 0, 7) == 'POLYGON') {
         $g = new KVDgis_GeomPolygon();
     } elseif (substr($wkt, 0, 12) == 'MULTIPOLYGON') {
         $g = new KVDgis_GeomMultiPolygon();
     } elseif (substr($wkt, 0, 10) == 'LINESTRING') {
         $g = new KVDgis_GeomLineString();
     } else {
         throw new InvalidArgumentException('Ongeldige Well-Known Text string: ' . $wkt . "\n. Het door u opgegeven type wordt niet ondersteund.");
     }
     $g->setGeometryFromText($wkt);
     return $g;
 }