CGAL 5.6.2 - 2D Arrangements
CGAL::Arrangement_with_history_2< Traits, Dcel > Class Template Reference

#include <CGAL/Arrangement_with_history_2.h>

Inherits from

CGAL::Arrangement_on_surface_with_history_2< Traits, Default_planar_topology< Traits, Dcel >::Traits >.

Definition

An object arr of the class Arrangement_with_history_2 represents the planar subdivision induced by a set of input curves \( \cal C\). The arrangement is represented as a doubly-connected edge-list (DCEL). As is the case for the Arrangement_2<Traits,Dcel>, each DCEL vertex is associated with a point and each edge is associated with an \( x\)-monotone curve whose interior is disjoint from all other curves and points. Each such \( x\)-monotone curve is a subcurve of some \( C \in \cal C\), or may represent an overlap among several curves in \( \cal C\).

The Arrangement_with_history_2 class-template extends the Arrangement_2 class-template by keeping an additional container of input curves representing \( \cal C\), and by maintaining a cross-mapping between these curves and the arrangement edges they induce. This way it is possible to determine the inducing curve(s) of each arrangement edge. This mapping also allows the traversal of input curves, and the traversal of edges induced by each curve.

The Arrangement_with_history_2 template has two parameters:

  • The Traits template-parameter should be instantiated with a model of the ArrangementTraits_2 concept. The traits class defines the Curve_2 type, which represents an input curve. It also defines the types of \( x\)-monotone curves and two-dimensional points, namely ArrangementTraits_2::X_monotone_curve_2 and ArrangementTraits_2::Point_2, respectively, and supports basic geometric predicates on them.
  • The Dcel template-parameter should be instantiated with a class that is a model of the ArrangementDcelWithRebind concept. The value of this parameter is by default Arr_default_dcel<Traits>.
See also
ArrangementDcel
Arr_default_dcel<Traits>
ArrangementTraits_2
Arrangement_2<Traits,Dcel>
insertion functions
removal functions
overlaying arrangements
Examples:
Arrangement_on_surface_2/curve_history.cpp, Arrangement_on_surface_2/edge_manipulation_curve_history.cpp, and Arrangement_on_surface_2/io_curve_history.cpp.

Types

typedef Traits Geometry_traits
 the geometry traits class.
 
typedef Default_planar_topology< Geometry_traits, Dcel >::Traits Topology_traits
 The topology traits.
 
typedef Arrangement_on_surface_with_history_2< Geometry_traits, Topology_traitsBase
 The base arrangement on surface type.
 

Types inherited from the base Arrangement_on_surface_2_with_history_2.

typedef Base::Point_2 Point_2
 
typedef Base::X_monotone_curve_2 X_monotone_curve_2
 
typedef Base::Curve_2 Curve_2
 
typedef Base::Size Size
 
typedef Base::Curve_handle Curve_handle
 
typedef Base::Curve_iterator Curve_iterator
 
typedef Base::Induced_edge_iterator Induced_edge_iterator
 
typedef Base::Originating_curve_iterator Originating_curve_iterator
 

Creation

 Arrangement_with_history_2 ()
 constructs an empty arrangement containing one unbounded face, which corresponds to the whole plane.
 
 Arrangement_with_history_2 (const Arrangement_with_history_2< Traits, Dcel > &other)
 copy constructor. More...
 
 Arrangement_with_history_2 (const Traits *traits)
 constructs an empty arrangement that uses the given traits instance for performing the geometric predicates.
 

Assignment Methods

Arrangement_with_history_2< Traits, Dcel > & operator= (other)
 assignment operator. More...
 
void assign (const Arrangement_with_history_2< Traits, Dcel > &other)
 assigns the contents of another arrangement. More...
 
void clear ()
 clears the arrangement. More...
 

Access Functions

Traits * traits ()
 obtains the traits object used by the arrangement instance. More...
 

Constructor & Destructor Documentation

◆ Arrangement_with_history_2()

template<typename Traits , typename Dcel >
CGAL::Arrangement_with_history_2< Traits, Dcel >::Arrangement_with_history_2 ( const Arrangement_with_history_2< Traits, Dcel > &  other)

copy constructor.

Member Function Documentation

◆ assign()

template<typename Traits , typename Dcel >
void CGAL::Arrangement_with_history_2< Traits, Dcel >::assign ( const Arrangement_with_history_2< Traits, Dcel > &  other)

assigns the contents of another arrangement.

◆ clear()

template<typename Traits , typename Dcel >
void CGAL::Arrangement_with_history_2< Traits, Dcel >::clear ( )

clears the arrangement.

◆ operator=()

template<typename Traits , typename Dcel >
Arrangement_with_history_2<Traits, Dcel>& CGAL::Arrangement_with_history_2< Traits, Dcel >::operator= ( other  )

assignment operator.

◆ traits()

template<typename Traits , typename Dcel >
Traits* CGAL::Arrangement_with_history_2< Traits, Dcel >::traits ( )

obtains the traits object used by the arrangement instance.

A const version is also available.