Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046 #include "Xpetra_EpetraMultiVector.hpp"
00047
00048 #include "Xpetra_EpetraImport.hpp"
00049 #include "Xpetra_EpetraExport.hpp"
00050 #include "Xpetra_Exceptions.hpp"
00051
00052 #include "Xpetra_EpetraVector.hpp"
00053
00054 #include "Epetra_SerialComm.h"
00055
00056 namespace Xpetra {
00057
00058
00059 template<class GlobalOrdinal>
00060 const Epetra_MultiVector & toEpetra(const MultiVector<double, int, GlobalOrdinal> & x) {
00061 XPETRA_DYNAMIC_CAST(const EpetraMultiVectorT<GlobalOrdinal>, x, tX, "toEpetra");
00062 return *tX.getEpetra_MultiVector();
00063 }
00064
00065 template<class GlobalOrdinal>
00066 Epetra_MultiVector & toEpetra(MultiVector<double, int, GlobalOrdinal> & x) {
00067 XPETRA_DYNAMIC_CAST( EpetraMultiVectorT<GlobalOrdinal>, x, tX, "toEpetra");
00068 return *tX.getEpetra_MultiVector();
00069 }
00070
00071
00072 template<class GlobalOrdinal>
00073 RCP<MultiVector<double, int, GlobalOrdinal> > toXpetra(RCP<Epetra_MultiVector> vec) {
00074 if (!vec.is_null())
00075 return rcp(new EpetraMultiVectorT<GlobalOrdinal>(vec));
00076
00077 return Teuchos::null;
00078 }
00079
00080 #ifndef XPETRA_EPETRA_NO_32BIT_GLOBAL_INDICES
00081 template RCP<MultiVector<double, int, int> > toXpetra<int>(RCP<Epetra_MultiVector>);
00082 template const Epetra_MultiVector & toEpetra(const MultiVector<double, int, int> &);
00083 template Epetra_MultiVector & toEpetra(MultiVector<double, int, int> &);
00084 #endif
00085
00086 #ifndef XPETRA_EPETRA_NO_64BIT_GLOBAL_INDICES
00087 template RCP<MultiVector<double, int, long long> > toXpetra<long long>(RCP<Epetra_MultiVector>);
00088 template const Epetra_MultiVector & toEpetra(const MultiVector<double, int, long long> &);
00089 template Epetra_MultiVector & toEpetra(MultiVector<double, int, long long> &);
00090 #endif
00091
00092 }