abstract class GeoJSON::PseudoGeometry

Overview

A PseudoGeometry is a geometry element in a GeoJSON feature.

This class is really just a union of Geometry and GeometryCollection with built-in JSON parsing logic.

Direct Known Subclasses

Defined in:

geojson/geometry/pseudo_geometry.cr

Constructors

Class Method Summary

Instance methods inherited from class GeoJSON::Base

type : String type

Constructor Detail

def self.new(parser : JSON::PullParser) #

Creates a new PseudoGeometry from the given parser.

This static class method automatically chooses the correct PseudoGeometry class (Geometry or GeometryCollection) to create.


[View source]

Class Method Detail

def self.from_json(geometry_json) #

Creates a Geometry or GeometryCollection from the given GeoJSON string.


[View source]