mirror of https://github.com/CGAL/cgal
moved doc from Algebraic Foundations to Number_types
This commit is contained in:
parent
31a9993481
commit
405d31d68f
|
|
@ -0,0 +1,22 @@
|
|||
\begin{ccRefFunctionObjectClass}{Is_valid<T>}
|
||||
|
||||
\ccDefinition
|
||||
|
||||
Not all values of a type need to be valid. The function object
|
||||
class \ccRefName\ checks this. \\
|
||||
|
||||
For example, an expression like
|
||||
\ccStyle{NT(0)/NT(0)} can result in an invalid number.
|
||||
Routines may have as a precondition that all values are valid.
|
||||
|
||||
\ccInclude{CGAL/utils_classes.h}
|
||||
|
||||
|
||||
\ccIsModel
|
||||
\ccRefConceptPage{AdaptableFunctor}
|
||||
|
||||
\ccCreationVariable{operator()}
|
||||
\ccMethod{bool operator()(const T& x);}
|
||||
{returns if the argument is valid.}
|
||||
|
||||
\end{ccRefFunctionObjectClass}
|
||||
|
|
@ -0,0 +1,29 @@
|
|||
\begin{ccRefFunctionObjectClass}{Max<T,Compare>}
|
||||
|
||||
\ccDefinition
|
||||
|
||||
The function object class \ccRefName\ returns the larger of two values.
|
||||
The default value for \ccc{Compare} is \ccc{std::less}.\\
|
||||
|
||||
Note that \ccc{T} must be a model of \ccc{LessThanComparable}
|
||||
in case \ccc{std::less} is used.
|
||||
|
||||
\ccInclude{CGAL/utils_classes.h}
|
||||
|
||||
\ccIsModel
|
||||
\ccRefConceptPage{AdaptableFunctor}
|
||||
|
||||
\ccCreation
|
||||
\ccCreationVariable{max}
|
||||
\ccConstructor{Max();}{ default constructor. }
|
||||
\ccGlue
|
||||
\ccConstructor{Max(Compare c);}
|
||||
{The constructed object will use \ccc{c} to compare the arguments. }
|
||||
|
||||
\ccOperations
|
||||
\ccCreationVariable{operator()}
|
||||
\ccMethod{T operator()(const T& x, const T& y);}
|
||||
{returns the larger of \ccc{x} and \ccc{y},
|
||||
with respect to the order induced by \ccc{Compare}. }
|
||||
|
||||
\end{ccRefFunctionObjectClass}
|
||||
|
|
@ -0,0 +1,29 @@
|
|||
\begin{ccRefFunctionObjectClass}{Min<T,Compare>}
|
||||
|
||||
\ccDefinition
|
||||
|
||||
The function object class \ccRefName\ returns the smaller of two values.
|
||||
The default value for \ccc{Compare} is \ccc{std::less}.\\
|
||||
|
||||
Note that \ccc{T} must be a model of \ccc{LessThanComparable}
|
||||
in case \ccc{std::less} is used.
|
||||
|
||||
\ccInclude{CGAL/utils_classes.h}
|
||||
|
||||
\ccIsModel
|
||||
\ccRefConceptPage{AdaptableFunctor}
|
||||
|
||||
\ccCreation
|
||||
\ccCreationVariable{min}
|
||||
\ccConstructor{Min();}{ default constructor. }
|
||||
\ccGlue
|
||||
\ccConstructor{Min(Compare c);}
|
||||
{The constructed object will use \ccc{c} to compare the arguments. }
|
||||
|
||||
\ccOperations
|
||||
\ccCreationVariable{operator()}
|
||||
\ccMethod{T operator()(const T& x, const T& y);}
|
||||
{returns the larger of \ccc{x} and \ccc{y},
|
||||
with respect to the order induced by \ccc{Compare}. }
|
||||
|
||||
\end{ccRefFunctionObjectClass}
|
||||
|
|
@ -56,4 +56,11 @@
|
|||
\ccRefIdfierPage{CGAL::Root_of_traits_2<RT>}\\
|
||||
\ccRefIdfierPage{CGAL::make_root_of_2}\\
|
||||
|
||||
\subsection*{Utilities}
|
||||
\ccRefIdfierPage{Min}\\
|
||||
\ccRefIdfierPage{Max}\\
|
||||
\ccRefIdfierPage{Is_valid}\\
|
||||
\ccRefIdfierPage{min}\\
|
||||
\ccRefIdfierPage{max}\\
|
||||
\ccRefIdfierPage{is_valid}\\
|
||||
%% EOF
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
\begin{ccRefFunction}{is_valid}
|
||||
|
||||
\ccDefinition
|
||||
|
||||
Not all values of a type need to be valid.
|
||||
The function \ccRefName\ returns whether the argument is valid.
|
||||
|
||||
\ccInclude{CGAL/utils.h}
|
||||
|
||||
\ccFunction{bool is_valid(const T& x);}{}
|
||||
|
||||
\ccSeeAlso
|
||||
|
||||
\ccRefIdfierPage{Is_valid}\\
|
||||
|
||||
\end{ccRefFunction}
|
||||
|
|
@ -32,6 +32,14 @@
|
|||
\input{NumberTypeSupport_ref/Number_type_checker.tex}
|
||||
\input{NumberTypeSupport_ref/Sqrt_extension.tex}
|
||||
|
||||
%functors
|
||||
\input{NumberTypeSupport_ref/Max_functor.tex}
|
||||
\input{NumberTypeSupport_ref/Min_functor.tex}
|
||||
\input{NumberTypeSupport_ref/Is_valid_functor.tex}
|
||||
%functions
|
||||
\input{NumberTypeSupport_ref/max.tex}
|
||||
\input{NumberTypeSupport_ref/min.tex}
|
||||
\input{NumberTypeSupport_ref/is_valid.tex}
|
||||
|
||||
\input{NumberTypeSupport_ref/Rational_traits.tex }
|
||||
\input{NumberTypeSupport_ref/simplest_rational_in_interval.tex }
|
||||
|
|
|
|||
|
|
@ -0,0 +1,13 @@
|
|||
\begin{ccRefFunction}{max}
|
||||
|
||||
\ccDefinition
|
||||
|
||||
The function \ccRefName\ returns the larger of two values.
|
||||
|
||||
\ccInclude{CGAL/utils.h}
|
||||
|
||||
\ccFunction{T max(const T& x, const T& y);}{}
|
||||
|
||||
\ccRefIdfierPage{Max}\\
|
||||
|
||||
\end{ccRefFunction}
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
\begin{ccRefFunction}{min}
|
||||
|
||||
\ccDefinition
|
||||
|
||||
The function \ccRefName\ returns the smaller of two values.
|
||||
|
||||
\ccInclude{CGAL/utils.h}
|
||||
|
||||
\ccFunction{T min(const T& x, const T& y);}{}
|
||||
|
||||
\ccSeeAlso
|
||||
|
||||
\ccRefIdfierPage{Min}\\
|
||||
|
||||
\end{ccRefFunction}
|
||||
Loading…
Reference in New Issue