Concept

SegmentDelaunayGraphSite_2

Definition

The concept SegmentDelaunayGraphSite_2 provides the requirements for the sites of a segment Delaunay graph.

Refines

DefaultConstructible
CopyConstructible
Assignable

Types

SegmentDelaunayGraphSite_2::Point_2
The point type.

SegmentDelaunayGraphSite_2::Segment_2
The segment type.

SegmentDelaunayGraphSite_2::FT
The field number type.

SegmentDelaunayGraphSite_2::RT
The ring number type.

Creation

In addition to the default and copy constructors the following static methods are available for constructing sites:

SegmentDelaunayGraphSite_2 s.construct_site_2 ( Point_2 p) Constructs a site from a point: the site represents the point p.
SegmentDelaunayGraphSite_2 s.construct_site_2 ( Point_2 p1, Point_2 p2)
Constructs a site from two points: the site represents the (open) segment (p1,p2).
SegmentDelaunayGraphSite_2 s.construct_site_2 ( Point_2 p1, Point_2 p2, Point_2 q1, Point_2 q2)
Constructs a site from four points: the site represents the point of intersection of the segments (p1,p2) and (q1,q2).
SegmentDelaunayGraphSite_2 s.construct_site_2 ( Point_2 p1, Point_2 p2, Point_2 q1, Point_2 q2, bool b)
Constructs a site from four points and a boolean: the site represents a segment. If b is true the endpoints are p1 and p × , otherwise p × and p2. p × is the point of intersection of the segments (p1,p2),(q1,q2).
SegmentDelaunayGraphSite_2 s.construct_site_2 ( Point_2 p1, Point_2 p2, Point_2 q1, Point_2 q2, Point_2 r1, Point_2 r2)
Constructs a site from six points: the site represents the segment with endpoints the points of intersection of the pairs of segments (p1,p2),(q1,q2) and (p1,p2),(r1,r2).

Predicates

bool s.is_defined () Returns true if the site represents a valid point or segment.
bool s.is_point () Returns true if the site represents a point.
bool s.is_segment () Returns true if the site represents a segment.
bool s.is_input () Returns true if the site represents an input point or a segment defined by two input points. Returns false if it represents a point of intersection of two segments, or if it represents a segment, at least one endpoint of which is a point of intersection of two segments.
bool s.is_input ( unsigned int i) Returns true if the i-th endpoint of the site is an input point. Returns false if the i-th endpoint of the site is the intersection of two segments.
Precondition: i must be at most 1, and s.is_segment() must be true.

Access Functions

Point_2 s.point () const Returns the point represented by the site s.
Precondition:  s.is_point() must be true.
Segment_2 s.segment () const Returns the segment represented by the site s.
Precondition:  s.is_segment() must be true.
Point_2 s.source () const Returns the source endpoint of the segment. Note that this method can construct an inexact point if the number type used is inexact.
Precondition: s.is_segment() must be true.
Point_2 s.target () const Returns the target endpoint of the segment. Note that this method can construct an inexact point if the number type used is inexact.
Precondition: s.is_segment() must be true.
SegmentDelaunayGraphSite_2 s.supporting_site () Returns a segment site object representing the segment that supports the segment represented by the site. Both endpoints of the returned site are input points.
Precondition: s.is_segment() must be true.
SegmentDelaunayGraphSite_2 s.supporting_site ( unsigned int i)
Returns a segment site object representing the i-th segment that supports the point of intersection represented by the site. Both endpoints of the returned site are input points.
Precondition: i must be at most 1, s.is_point() must be true and s.is_input() must be false.
SegmentDelaunayGraphSite_2 s.crossing_site ( unsigned int i)
Returns a segment site object representing the i-th segment that supports the i-th endpoint of the site which is not the supporting segment of the site. Both endpoints of the returned site are input points.
Precondition: i must be at most 1, s.is_segment() must be true and s.is_input(i) must be false.
SegmentDelaunayGraphSite_2 s.source_site () Returns a point site object representing the source point of the site.
Precondition: s.is_segment() must be true.
SegmentDelaunayGraphSite_2 s.target_site () Returns a point site object representing the target point of the site.
Precondition: s.is_segment() must be true.
Point_2 s.source_of_supporting_site () Returns the source point of the supporting site of the this site.
Precondition: is_segment() must be true.
Point_2 s.target_of_supporting_site () Returns the target point of the supporting site of the this site.
Precondition: is_segment() must be true.
Point_2 s.source_of_supporting_site ( unsigned int i)
Returns the source point of the i-th supporting site of the this site.
Precondition: is_point() must be true, is_input() must be false and i must either be 0 or 1.
Point_2 s.target_of_supporting_site ( unsigned int i)
Returns the target point of the i-th supporting site of the this site.
Precondition: is_point() must be true, is_input() must be false and i must either be 0 or 1.
Point_2 s.source_of_crossing_site ( unsigned int i)
Returns the source point of the i-th crossing site of the this site.
Precondition: is_segment() must be true, is_input(i) must be false and i must either be 0 or 1.
Point_2 s.target_of_crossing_site ( unsigned int i)
Returns the target point of the i-th supporting site of the this site.
Precondition: is_segment() must be true, is_input(i) must be false and i must either be 0 or 1.

Has Models

CGAL::Segment_Delaunay_graph_site_2<K>

See Also

SegmentDelaunayGraphTraits_2
CGAL::Segment_Delaunay_graph_site_2<K>
CGAL::Segment_Delaunay_graph_traits_2<K,MTag>
CGAL::Segment_Delaunay_graph_traits_without_intersections_2<K,MTag>
CGAL::Segment_Delaunay_graph_filtered_traits_2<CK,CM,EK,EM,FK,FM>
CGAL::Segment_Delaunay_graph_filtered_traits_without_intersections_2<CK,CM,EK,EM,FK,FM>