RTOp Package Browser (Single Doxygen Collection)
Version of the Day
|
Class for a changeable sub-vector. More...
#include <RTOpPack_Types.hpp>
Public Member Functions | |
SubVectorView () | |
SubVectorView (const ArrayRCP< Scalar > &values_in) | |
SubVectorView (Ordinal globalOffset_in, Ordinal subDim_in, const ArrayRCP< Scalar > &values_in, ptrdiff_t stride_in) | |
SubVectorView (Ordinal subDim_in) | |
SubVectorView (const SubVectorView< Scalar > &sv) | |
void | initialize (Ordinal globalOffset_in, Ordinal subDim_in, const ArrayRCP< Scalar > &values_in, ptrdiff_t stride_in) |
const ArrayRCP< Scalar > | values () const |
Scalar & | operator[] (Ordinal i) const |
Zero-based indexing (Preconditions: values()!=NULL && (0 <= i < subDim()) ). More... | |
Scalar & | operator() (Ordinal i) const |
Zero-based indexing (Preconditions: values()!=NULL && (0 <= i < subDim()) ). More... | |
![]() | |
ConstSubVectorView () | |
ConstSubVectorView (const ArrayRCP< const Scalar > &values_in) | |
ConstSubVectorView (Ordinal globalOffset_in, Ordinal subDim_in, const ArrayRCP< const Scalar > &values_in, ptrdiff_t stride_in) | |
ConstSubVectorView (const ConstSubVectorView< Scalar > &sv) | |
void | initialize (Ordinal globalOffset_in, Ordinal subDim_in, const ArrayRCP< const Scalar > &values_in, ptrdiff_t stride_in) |
void | uninitialize () |
void | setGlobalOffset (Ordinal globalOffset_in) |
Ordinal | globalOffset () const |
Ordinal | subDim () const |
const ArrayRCP< const Scalar > | values () const |
ptrdiff_t | stride () const |
const Scalar & | operator[] (Ordinal i) const |
Zero-based indexing (Preconditions: values()!=NULL && (0 <= i < subDim()) ). More... | |
const Scalar & | operator() (Ordinal i) const |
Zero-based indexing (Preconditions: values()!=NULL && (0 <= i < subDim()) ). More... | |
Additional Inherited Members | |
![]() | |
template<class Scalar > | |
std::ostream & | operator<< (std::ostream &out, const ConstSubVectorView< Scalar > &sv) |
Class for a changeable sub-vector.
This class derives from ConstSubVectorView
and adds methods to change the data. Note, a const SubVectorView
object allows clients to change the values in the underlying subvector. The meaning of const
in this context is that the view of the data can not change.
WARNING! the default copy constructor and assignment operators are allowed which results in only pointer copy, not deep copy. This means this class has shallow copy semantics. You have been warned!
NOTE: It is perfectly safe to derive this class from ConstSubVectorView even through it does not have a virtual destructor. That is because this derived class has no data members that would cause problems in slicing or memory leaks when deleting.
Definition at line 215 of file RTOpPack_Types.hpp.
|
inline |
Definition at line 218 of file RTOpPack_Types.hpp.
|
inline |
Definition at line 220 of file RTOpPack_Types.hpp.
|
inline |
Definition at line 224 of file RTOpPack_Types.hpp.
|
inline |
Definition at line 229 of file RTOpPack_Types.hpp.
|
inline |
Definition at line 233 of file RTOpPack_Types.hpp.
|
inline |
Definition at line 237 of file RTOpPack_Types.hpp.
|
inline |
Definition at line 241 of file RTOpPack_Types.hpp.
|
inline |
Zero-based indexing (Preconditions: values()!=NULL && (0 <= i < subDim())
).
Definition at line 245 of file RTOpPack_Types.hpp.
|
inline |
Zero-based indexing (Preconditions: values()!=NULL && (0 <= i < subDim())
).
Definition at line 249 of file RTOpPack_Types.hpp.