Coordinates.
For internal use, flat coordinates in combination with layout are also accepted.
Optionallayout: GeometryLayoutLayout.
ProtecteddisposedThe object has already been disposed.
ProtectedflatProtectedlayoutProtectedsimplifiedProtectedsimplifiedAbstractsimplifyGet a transformed and simplified version of the geometry.
ProtectedstrideProtectedapplyProtectedApply any properties from another object without triggering events.
The source object.
AbstractapplyApply a transform function to the coordinates of the geometry.
The geometry is modified in place.
If you do not want the geometry modified in place, first clone() it and
then use this function on the clone.
Transform function. Called with a flat array of geometry coordinates.
Make a complete copy of the geometry.
Clone.
AbstractclosestProtected AbstractcomputeDispatches an event and calls all listeners listening for events
of this type. The event parameter can either be a string or an
Object with a type property.
Event object.
false if anyone called preventDefault on the
event object or if any of the listeners returned false.
ProtecteddisposeReturn the coordinate at the provided fraction along the linestring.
The fraction is a number between 0 and 1, where 0 is the start of the
linestring and 1 is the end.
Fraction.
Optionaldest: CoordinateOptional coordinate whose values will be modified. If not provided, a new coordinate will be returned.
Coordinate of the interpolated point.
Returns the coordinate at m using linear interpolation, or null if no
such coordinate exists.
extrapolate controls extrapolation beyond the range of Ms in the
MultiLineString. If extrapolate is true then Ms less than the first
M will return the first coordinate and Ms greater than the last M will
return the last coordinate.
M.
Optionalextrapolate: booleanExtrapolate. Default is false.
Coordinate.
Create a simplified version of this geometry using the Douglas Peucker algorithm.
Squared tolerance.
Simplified geometry.
ProtectedgetProtectedSquared tolerance.
Simplified LineString.
AbstractgetAbstractintersectsProtectedonceProtectedonAbstractrotateAbstractscaleScale the geometry (with an optional origin). This modifies the geometry coordinates in place.
The scaling factor in the x-direction.
Optionalsy: numberThe scaling factor in the y-direction (defaults to sx).
Optionalanchor: CoordinateThe scale origin (defaults to the center of the geometry extent).
ProtectedsetSets a collection of key-value pairs. Note that this changes any existing properties and adds new ones (it does not remove any existing properties).
Values.
Optionalsilent: booleanUpdate without triggering an event.
Create a simplified version of this geometry. For linestrings, this uses the Douglas Peucker algorithm. For polygons, a quantization-based simplification is used to preserve topology.
The tolerance distance for simplification.
A new, simplified version of the original geometry.
AbstractsimplifyTransform each coordinate of the geometry from one coordinate reference
system to another. The geometry is modified in place.
For example, a line will be transformed to a line and a circle to a circle.
If you do not want the geometry modified in place, first clone() it and
then use this function on the clone.
The current projection. Can be a string identifier or a module:ol/proj/Projection~Projection object.
The desired projection. Can be a string identifier or a module:ol/proj/Projection~Projection object.
This geometry. Note that original geometry is modified in place.
AbstracttranslateProtectedun
Classdesc
Linestring geometry.
Api