code: public static Geometry toGeometry(String wkt) throws WktException {
  		if (wkt != null) {
  			// First we detect if the string is WKT or EWKT:
  			String[] parts = wkt.split(";");
  			if (parts.length == 2) { // We assume it is EWKT:
  				Geometry geometry = parseWkt(parts[1]);
  				recursiveSetSrid(geometry, parseSrid(parts[0]));
  				return geometry;
  			}
  			return parseWkt(wkt);
  		}
  		throw new WktException(ERR_MSG + "illegal argument; no WKT");
  	}
docs: Parses a given WKT (or EWKT) string into a geometry object.
  
  @param wkt
  The Well Known Text to parse.
  @return Returns The resulting geometry from parsing the WKT.
  @throws WktException
  In case something went wrong while parsing. The WKT format must be respected.