Thyra_TpetraVectorSpace to expose getter for underlying Tpetra object
Created by: bartgol
I want to be able to extract the underlying Tpetra map from a vector space
Motivation and Context
The Tpetra adapter offer the possibility to extract the Tpetra object for Vector, MultiVector, and LinearOp. However, such capability does not exist for VectorSpace. This is unfortunate. For (Multi)Vector, one can survive without this capability (at least on host), since there are methods in parent classes that allow extraction of local data or subviews. However, there is no Thyra equivalent of Global ID and Local ID, so one needs to get the underlying map from Thyra, in order to access that information.
Simply add a method like this (copied and adapted from other adapters):
/** \brief Get the embedded non-const Tpetra::Vector. */ RCP<const Tpetra::Map<LocalOrdinal,GlobalOrdinal,Node> > getConstTpetraMap() const;
I can set up a quick PR for this, if the proposed addition is deemed reasonable. I can also add a quick check in the tpetra adapters tests.