hgeometry-0.8.0.0: Geometric Algorithms, Data structures, and Data types.

Copyright(C) Frank Staals
Licensesee the LICENSE file
MaintainerFrank Staals
Safe HaskellNone
LanguageHaskell2010

Algorithms.Geometry.Sweep

Description

Helper types and functions for implementing Sweep line algorithms.

Synopsis

Documentation

newtype Tagged (s :: *) a Source #

Constructors

Tagged 

Fields

Instances
Eq a => Eq (Tagged s a) Source # 
Instance details

Defined in Algorithms.Geometry.Sweep

Methods

(==) :: Tagged s a -> Tagged s a -> Bool #

(/=) :: Tagged s a -> Tagged s a -> Bool #

Ord a => Ord (Tagged s a) Source # 
Instance details

Defined in Algorithms.Geometry.Sweep

Methods

compare :: Tagged s a -> Tagged s a -> Ordering #

(<) :: Tagged s a -> Tagged s a -> Bool #

(<=) :: Tagged s a -> Tagged s a -> Bool #

(>) :: Tagged s a -> Tagged s a -> Bool #

(>=) :: Tagged s a -> Tagged s a -> Bool #

max :: Tagged s a -> Tagged s a -> Tagged s a #

min :: Tagged s a -> Tagged s a -> Tagged s a #

Show a => Show (Tagged s a) Source # 
Instance details

Defined in Algorithms.Geometry.Sweep

Methods

showsPrec :: Int -> Tagged s a -> ShowS #

show :: Tagged s a -> String #

showList :: [Tagged s a] -> ShowS #

tag :: proxy s -> a -> Tagged s a Source #

newtype Timed s t a Source #

Represent a computation that needs a particular time as input.

Constructors

Timed 

Fields

Instances
(Reifies s t, Ord k) => Eq (Timed s t k) Source # 
Instance details

Defined in Algorithms.Geometry.Sweep

Methods

(==) :: Timed s t k -> Timed s t k -> Bool #

(/=) :: Timed s t k -> Timed s t k -> Bool #

(Reifies s t, Ord k) => Ord (Timed s t k) Source # 
Instance details

Defined in Algorithms.Geometry.Sweep

Methods

compare :: Timed s t k -> Timed s t k -> Ordering #

(<) :: Timed s t k -> Timed s t k -> Bool #

(<=) :: Timed s t k -> Timed s t k -> Bool #

(>) :: Timed s t k -> Timed s t k -> Bool #

(>=) :: Timed s t k -> Timed s t k -> Bool #

max :: Timed s t k -> Timed s t k -> Timed s t k #

min :: Timed s t k -> Timed s t k -> Timed s t k #

compare_ :: forall s t k. (Ord k, Reifies s t) => Timed s t k -> Timed s t k -> Ordering Source #

Comparison function for timed values

coerceTo :: proxy s -> f (Timed s' t k) v -> f (Timed s t k) v Source #

Coerce timed values

unTagged :: f (Timed s t k) v -> f (Timed () t k) v Source #

runAt :: forall s0 t k r f v. Ord k => t -> f (Timed s0 t k) v -> (forall s. Reifies s t => f (Timed s t k) v -> r) -> r Source #

Runs a computation at a given time.

constT :: proxy s -> Int -> Timed s Int Int Source #

test2M :: Reifies s Int => proxy s -> Map (Timed s Int Int) String Source #

query :: forall s v. Ord (Timed s Int Int) => Map (Timed s Int Int) v -> Maybe v Source #