45 #ifndef AMESOS2_VECTORTRAITS_HPP
46 #define AMESOS2_VECTORTRAITS_HPP
50 #include <Tpetra_MultiVector.hpp>
53 #ifdef HAVE_AMESOS2_EPETRA
54 # include <Epetra_MultiVector.h>
61 template <
class Vector>
62 struct VectorTraits {};
68 template <
typename Scalar,
69 typename LocalOrdinal,
70 typename GlobalOrdinal,
73 Tpetra::MultiVector<Scalar,
77 typedef Scalar scalar_t;
78 typedef LocalOrdinal local_ordinal_t;
79 typedef GlobalOrdinal global_ordinal_t;
82 typedef Tpetra::MultiVector<Scalar, LocalOrdinal, GlobalOrdinal, Node> multivector_type;
83 typedef typename multivector_type::impl_scalar_type ptr_scalar_type;
86 template <
typename Scalar,
87 typename ExecutionSpace >
89 Kokkos::View<Scalar**,Kokkos::LayoutLeft,ExecutionSpace> > {
90 typedef Scalar scalar_t;
91 typedef int local_ordinal_t;
92 typedef Tpetra::Map<>::global_ordinal_type global_ordinal_t;
93 typedef Tpetra::Map<>::node_type node_t;
95 typedef Kokkos::View<Scalar**,Kokkos::LayoutLeft,ExecutionSpace> multivector_type;
96 typedef Scalar ptr_scalar_type;
100 #ifdef HAVE_AMESOS2_EPETRA
103 struct VectorTraits<Epetra_MultiVector> {
104 typedef double scalar_t;
105 typedef int local_ordinal_t;
106 typedef Tpetra::Map<>::global_ordinal_type global_ordinal_t;
107 typedef Tpetra::Map<>::node_type node_t;
109 typedef Epetra_MultiVector multivector_type;
110 typedef double ptr_scalar_type;
117 #endif // AMESOS2_VECTORTRAITS_HPP