Basic Polynomial Algebra Subprograms (BPAS)  v. 1.791
BPASPolynomialTesters.hpp
1 
2 #ifndef _BPAS_POLYNOMIAL_TESTERS_
3 #define _BPAS_POLYNOMIAL_TESTERS_
4 
5 #include "../Ring/BPASIntegralDomain.hpp"
6 #include "../Ring/BPASGCDDomain.hpp"
7 
8 
9 //forward declares
10 
11 template <class Ring, class Dervied>
12 class BPASBasePolynomial;
13 
14 template <class Ring, class Dervied>
16 
17 template <class Ring, class Dervied>
18 class BPASGCDPolynomial;
19 
20 /**
21  * Via conditional inheritance, determine if the ground ring
22  * template parameter Ring is an integral domain
23  * or not. If so, the resulting polynomial is a BPASIntegralPolynomial
24  * and forms an integral domain.
25  *
26  * This tester is used by BPASPolynomial for compile-time type
27  * resolution.
28  */
29 template <class Ring, class Derived>
30 class BPASIntegralPolynomialTester : public std::conditional<std::is_base_of<BPASIntegralDomain<Ring>, Ring>::value, BPASIntegralPolynomial<Ring, Derived>, BPASBasePolynomial<Ring, Derived>>::type {};
31 
32 
33 /**
34  * Via conditional inheritance, determine if the ground ring
35  * template parameter Ring is a GCD domain
36  * or not. If so, the resulting polynomial is a BPASGCDPolynomial
37  * and forms a GCD domain.
38  *
39  * This tester is used by BPASPolynomial for compile-time type
40  * resolution.
41  */
42 template <class Ring, class Derived>
43 class BPASGCDPolynomialTester: public std::conditional<std::is_base_of<BPASGCDDomain<Ring>, Ring>::value, BPASGCDPolynomial<Ring, Derived>, BPASIntegralPolynomialTester<Ring, Derived> >::type {};
44 
45 
46 #endif
Via conditional inheritance, determine if the ground ring template parameter Ring is an integral doma...
Definition: BPASPolynomialTesters.hpp:30
An abstract class defining the interface of polynomial over an arbitrary BPASRing.
Definition: BPASPolynomial.hpp:47
An abstract class defining the interface of a polynomial ring which is also an GCD domain...
Definition: BPASGCDPolynomial.hpp:19
An abstract class defining the interface of a polynomial ring which is also an integral domain...
Definition: BPASIntegralPolynomial.hpp:19
Via conditional inheritance, determine if the ground ring template parameter Ring is a GCD domain or ...
Definition: BPASPolynomialTesters.hpp:43