All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines
Xpetra_UseShortNamesOrdinal.hpp
Go to the documentation of this file.
00001 // @HEADER
00002 //
00003 // ***********************************************************************
00004 //
00005 //             Xpetra: A linear algebra interface package
00006 //                  Copyright 2012 Sandia Corporation
00007 //
00008 // Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
00009 // the U.S. Government retains certain rights in this software.
00010 //
00011 // Redistribution and use in source and binary forms, with or without
00012 // modification, are permitted provided that the following conditions are
00013 // met:
00014 //
00015 // 1. Redistributions of source code must retain the above copyright
00016 // notice, this list of conditions and the following disclaimer.
00017 //
00018 // 2. Redistributions in binary form must reproduce the above copyright
00019 // notice, this list of conditions and the following disclaimer in the
00020 // documentation and/or other materials provided with the distribution.
00021 //
00022 // 3. Neither the name of the Corporation nor the names of the
00023 // contributors may be used to endorse or promote products derived from
00024 // this software without specific prior written permission.
00025 //
00026 // THIS SOFTWARE IS PROVIDED BY SANDIA CORPORATION "AS IS" AND ANY
00027 // EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
00028 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
00029 // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SANDIA CORPORATION OR THE
00030 // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
00031 // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
00032 // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
00033 // PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
00034 // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
00035 // NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
00036 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00037 //
00038 // Questions? Contact
00039 //                    Jeremie Gaidamour (jngaida@sandia.gov)
00040 //                    Jonathan Hu       (jhu@sandia.gov)
00041 //                    Ray Tuminaro      (rstumin@sandia.gov)
00042 //
00043 // ***********************************************************************
00044 //
00045 // @HEADER
00046 // Get rid of template parameters
00047 
00048 // New definition of types using the types LocalOrdinal, GlobalOrdinal, Node, LocalMatOps of the current context.
00049 #ifdef XPETRA_MAP_SHORT
00050 typedef Xpetra::Map<LocalOrdinal, GlobalOrdinal, Node> Map;
00051 #endif
00052 
00053 #ifdef XPETRA_MAPFACTORY_SHORT
00054 typedef Xpetra::MapFactory<LocalOrdinal, GlobalOrdinal, Node> MapFactory;
00055 #endif
00056 
00057 #ifdef XPETRA_CRSGRAPH_SHORT
00058 typedef Xpetra::CrsGraph<LocalOrdinal, GlobalOrdinal, Node, LocalMatOps> CrsGraph;
00059 #endif
00060 
00061 #ifdef XPETRA_CRSGRAPHFACTORY_SHORT
00062 typedef Xpetra::CrsGraphFactory<LocalOrdinal, GlobalOrdinal, Node, LocalMatOps> CrsGraphFactory;
00063 #endif
00064 
00065 #ifdef XPETRA_VECTOR_SHORT
00066 typedef Xpetra::Vector<LocalOrdinal, LocalOrdinal, GlobalOrdinal, Node> LocalOrdinalVector;
00067 typedef Xpetra::Vector<GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node> GlobalOrdinalVector;
00068 typedef LocalOrdinalVector  LOVector;
00069 typedef GlobalOrdinalVector GOVector;
00070 #endif
00071 
00072 #ifdef XPETRA_MULTIVECTOR_SHORT
00073 typedef Xpetra::MultiVector<LocalOrdinal, LocalOrdinal, GlobalOrdinal, Node> LocalOrdinalMultiVector;
00074 typedef Xpetra::MultiVector<GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node> GlobalOrdinalMultiVector;
00075 typedef LocalOrdinalMultiVector  LOMultiVector;
00076 typedef GlobalOrdinalMultiVector GOMultiVector;
00077 #endif
00078 
00079 #ifdef XPETRA_VECTORFACTORY_SHORT
00080 typedef Xpetra::VectorFactory<LocalOrdinal, LocalOrdinal, GlobalOrdinal, Node> LocalOrdinalVectorFactory;
00081 typedef Xpetra::VectorFactory<GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node> GlobalOrdinalVectorFactory;
00082 typedef LocalOrdinalVectorFactory  LOVectorFactory;
00083 typedef GlobalOrdinalVectorFactory GOVectorFactory;
00084 #endif
00085 
00086 #ifdef XPETRA_MULTIVECTORFACTORY_SHORT
00087 typedef Xpetra::MultiVectorFactory<LocalOrdinal, LocalOrdinal, GlobalOrdinal, Node> LocalOrdinalMultiVectorFactory;
00088 typedef Xpetra::MultiVectorFactory<GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node> GlobalOrdinalMultiVectorFactory;
00089 typedef LocalOrdinalMultiVectorFactory  LOMultiVectorFactory;
00090 typedef GlobalOrdinalMultiVectorFactory GOMultiVectorFactory;
00091 #endif
00092 
00093 #ifdef XPETRA_IMPORT_SHORT
00094 typedef Xpetra::Import<LocalOrdinal, GlobalOrdinal, Node> Import;
00095 #endif
00096 
00097 #ifdef XPETRA_EXPORT_SHORT
00098 typedef Xpetra::Export<LocalOrdinal, GlobalOrdinal, Node> Export;
00099 #endif
00100 
00101 #ifdef XPETRA_IMPORTFACTORY_SHORT
00102 typedef Xpetra::ImportFactory<LocalOrdinal, GlobalOrdinal, Node> ImportFactory;
00103 #endif
00104 
00105 #ifdef XPETRA_EXPORTFACTORY_SHORT
00106 typedef Xpetra::ExportFactory<LocalOrdinal, GlobalOrdinal, Node> ExportFactory;
00107 #endif
00108 
00109 #ifdef XPETRA_TPETRAMAP_SHORT
00110 typedef Xpetra::TpetraMap<LocalOrdinal, GlobalOrdinal, Node> TpetraMap;
00111 #endif
00112 
00113 #ifdef XPETRA_TPETRACRSGRAPH_SHORT
00114 typedef Xpetra::TpetraCrsGraph<LocalOrdinal, GlobalOrdinal, Node, LocalMatOps> TpetraCrsGraph;
00115 #endif
00116 
00117 #ifdef XPETRA_STRIDEDMAP_SHORT
00118 typedef Xpetra::StridedMap<LocalOrdinal, GlobalOrdinal, Node> StridedMap;
00119 #endif
00120 
00121 #ifdef XPETRA_STRIDEDMAPFACTORY_SHORT
00122 typedef Xpetra::StridedMapFactory<LocalOrdinal, GlobalOrdinal, Node> StridedMapFactory;
00123 #endif
00124 
00125 // Note: There is no #ifndef/#define/#end in this header file because it can be included more than once (it can be included in methods templated by Scalar, LocalOrdinal, GlobalOrdinal, Node).
00126 
00127 // TODO: add namespace {} for shortcut types
00128 
00129 // Define convenient shortcut for data types
00130 typedef LocalOrdinal  LO;
00131 typedef GlobalOrdinal GO;
00132 typedef Node          NO;
00133 typedef LocalMatOps   LMO;
00134 
00135 // TODO: do the same for Epetra object (problem of namespace)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines