geopackage-ts
    Preparing search index...

    Interface LineString

    Represents a line string geometry composed of two or more connected points.

    Coordinates are stored in a single flat array where each consecutive group of stride values (stride = 2 + Z + M) represents one vertex.

    const line: LineString = {
    type: 'LineString',
    hasZ: false,
    hasM: false,
    coordinates: [0, 0, 1, 1, 2, 0], // three 2D vertices
    };
    interface LineString {
        coordinates: number[];
        hasM: boolean;
        hasZ: boolean;
        type: "LineString";
    }
    Index

    Properties

    coordinates: number[]

    Flat array of coordinate values.

    Every stride consecutive numbers (where stride = 2 + Z + M) form one vertex: [x1, y1, x2, y2, ...] for 2D, [x1, y1, z1, x2, y2, z2, ...] for 3D, etc.

    hasM: boolean

    Whether the geometry includes M (measure) values.

    hasZ: boolean

    Whether the geometry includes Z (elevation/altitude) values.

    type: "LineString"

    Discriminant literal identifying this geometry as a LineString.