Added method for creating WKT given either a line or a polygon.