# Class: module:org/locationtech/jts/io/WKTReader

## module:org/locationtech/jts/io/WKTReader(geometryFactory)

Converts a geometry in Well-Known Text format to a `Geometry`.

`WKTReader` supports extracting `Geometry` objects from either `Reader`s or `String`s. This allows it to function as a parser to read `Geometry` objects from text blocks embedded in other data formats (e.g. XML).

## Constructor

#### new module:org/locationtech/jts/io/WKTReader(geometryFactory)

A `WKTReader` is parameterized by a `GeometryFactory`, to allow it to create `Geometry` objects of the appropriate implementation. In particular, the `GeometryFactory` determines the `PrecisionModel` and `SRID` that is used.

##### Parameters:

Name | Type | Description
--- | --- | ---
`geometryFactory` | GeometryFactory |

Source:
  - org/locationtech/jts/io/WKTReader.js, line 25

### Methods

#### read(wkt) → {Geometry}

Reads a Well-Known Text representation of a `Geometry`

##### Parameters:

Name | Type | Description
--- | --- | ---
`wkt` | string | a string (see the OpenGIS Simple Features Specification).

Source:
  - org/locationtech/jts/io/WKTReader.js, line 39

##### Returns:

a `Geometry` read from `string.`

Type
  Geometry