Sha256: 283cd1520f85588e941fefbe11123db605dff4a14b0da126cb6b1ea1e75d6c26

Contents?: true

Size: 1.13 KB

Versions: 7

Compression:

Stored size: 1.13 KB

Contents

# frozen_string_literal: true

# -----------------------------------------------------------------------------
#
# LinearRing feature interface
#
# -----------------------------------------------------------------------------

module RGeo
  module Feature
    # == SFS 1.1 Description
    #
    # A LinearRing is a LineString that is both closed and simple.
    #
    # == Notes
    #
    # LinearRing is defined as a module and is provided primarily
    # for the sake of documentation. Implementations need not necessarily
    # include this module itself. Therefore, you should not depend on the
    # kind_of? method to check type. Instead, use the provided check_type
    # class method (or === operator) defined in the Type module.

    module LinearRing
      include LineString
      extend Type

      # Returns +true+ if the ring is oriented in a counter clockwise direction
      # otherwise returns +false+.
      #
      # == Notes
      #
      # Not a standard SFS method for linear rings, but added for convenience.
      def ccw?
        raise Error::UnsupportedOperation, "Method LinearRing#ccw? not defined."
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
rgeo-3.0.0.pre.rc.3 lib/rgeo/feature/linear_ring.rb
rgeo-3.0.0.pre.rc.2 lib/rgeo/feature/linear_ring.rb
rgeo-3.0.0.pre.rc.1 lib/rgeo/feature/linear_ring.rb
rgeo-2.4.0 lib/rgeo/feature/linear_ring.rb
rgeo-2.3.1 lib/rgeo/feature/linear_ring.rb
rgeo-2.3.0 lib/rgeo/feature/linear_ring.rb
rgeo-2.2.0 lib/rgeo/feature/linear_ring.rb