Classes | |
| class | Teuchos::any |
| Modified boost::any class, which is a container for a templated value. More... | |
| class | Teuchos::bad_any_cast |
| Thrown if any_cast is attempted between two incompatable types. More... | |
| class | Teuchos::Array< T > |
| Array is a templated array class derived from the STL vector, but with index boundschecking and an extended interface. More... | |
| class | Teuchos::ArrayArg< N, T > |
| Utility class that allows arrays to be passed into argument list. More... | |
| class | Teuchos::basic_oblackholestream< _CharT, _Traits > |
| class | Teuchos::BLAS< OrdinalType, ScalarType > |
| The Templated BLAS Wrapper Class. More... | |
| class | Teuchos::CommandLineProcessor |
Class that helps parse command line input arguments from (argc,argv[]) and set options. More... | |
| class | Teuchos::CommandLineProcessor::ParseError |
| Thrown if a parse exception occurs and throwExceptions==true. More... | |
| class | Teuchos::CommandLineProcessor::HelpPrinted |
| Thrown if --help was specified and throwExceptions==true. More... | |
| class | Teuchos::CommandLineProcessor::UnrecognizedOption |
| Thrown if an unrecognized option was found and throwExceptions==true. More... | |
| struct | Teuchos::CommandLineProcessor::opt_val_val_t |
| struct | Teuchos::CommandLineProcessor::opt_doc_t |
| struct | Teuchos::CommandLineProcessor::enum_opt_data_t |
| class | Teuchos::CompileTimeAssert< Test > |
| If instantiated (for Test!=0) then this should not compile! More... | |
| class | Teuchos::CompileTimeAssert< 0 > |
| If instantiated (i.e. Test==0) then this will compile! More... | |
| class | Teuchos::CompObject |
| Functionality and data that is common to all computational classes. More... | |
| class | Teuchos::m_bad_cast |
| We create this class so that we may throw a bad_cast when appropriate and still use the TEST_FOR_EXCEPTION macro. More... | |
| class | Teuchos::FileInputSource |
| Instantiation of XMLInputSource class for reading XML from a file. More... | |
| class | Teuchos::FileInputStream |
| Instantiation of XMLInputStream class for reading an entire document from a file. More... | |
| class | Teuchos::Flops |
| The Teuchos Floating Point Operations Class. More... | |
| class | Teuchos::HashSet< Key > |
| Templated hashtable-based set. More... | |
| class | Teuchos::HashPair< Key, Value > |
| Helper class for Teuchos::Hashtable, representing a single <key, value> pair. More... | |
| class | Teuchos::Hashtable< Key, Value > |
| Templated hashtable class. More... | |
| class | Teuchos::HashUtils |
| Utilities for generating hashcodes. More... | |
| struct | Teuchos::UndefinedLAPACKRoutine< T > |
| class | Teuchos::LAPACK< OrdinalType, ScalarType > |
| The Templated LAPACK Wrapper Class. More... | |
| class | Teuchos::MPIComm |
| Object representation of an MPI communicator. More... | |
| class | Teuchos::MPIContainerComm< T > |
| Object representation of an MPI communicator for templated containers. More... | |
| class | Teuchos::MPISession |
| This class provides methods for initializing, finalizing, and querying the global MPI session. More... | |
| class | Teuchos::MPITraits< T > |
| Templated traits class that binds MPI types to C++ types. More... | |
| class | Teuchos::Object |
| The base Teuchos class. More... | |
| struct | Teuchos::UndefinedOrdinalTraits< T > |
This is the default structure used by OrdinalTraits<T> to produce a compile time error when the specialization does not exist for type T. More... | |
| struct | Teuchos::OrdinalTraits< T > |
| This structure defines some basic traits for the ordinal field type. More... | |
| class | Teuchos::ParameterEntry |
| This object is held as the "value" in the Teuchos::ParameterList map. More... | |
| class | Teuchos::ParameterList |
| The Teuchos::ParameterList class provides a templated parameter list. More... | |
| class | Teuchos::ParameterXMLFileReader |
| Reader for getting parameter lists from XML files. More... | |
| class | Teuchos::PrimitiveTypeTraits< T > |
| A templated traits class for decomposing object into an array of primitive objects. More... | |
| class | Teuchos::RawMPITraits< T > |
| Templated class that returns raw MPI data types. More... | |
| class | Teuchos::DeallocDelete< T > |
Deallocator for new which calls delete. More... | |
| class | Teuchos::DeallocArrayDelete< T > |
Deallocator for new [] which calls delete []. More... | |
| class | Teuchos::RefCountPtr< T > |
| Templated class for reference counted smart pointers (see description). More... | |
| struct | Teuchos::UndefinedScalarTraits< T > |
This is the default structure used by ScalarTraits<T> to produce a compile time error when the specialization does not exist for type T. More... | |
| struct | Teuchos::ScalarTraits< T > |
| This structure defines some basic traits for a scalar field type. More... | |
| class | Teuchos::SerialDenseMatrix< OrdinalType, ScalarType > |
| This class creates and provides basic support for dense rectangular matrix of templated type. More... | |
| class | Teuchos::SerialDenseVector< OrdinalType, ScalarType > |
| This class creates and provides basic support for dense vectors of templated type as a specialization of Teuchos::SerialDenseMatrix. Additional methods for the SerialDenseVector class, like mathematical methods, can be found documented in SerialDenseMatrix. More... | |
| class | Teuchos::StringInputSource |
| Instantiation of XMLInputSource class for reading XML from a string. More... | |
| class | Teuchos::StringInputStream |
| Instantiation of XMLInputStream for reading an entire document from a string. More... | |
| class | Teuchos::StrUtils |
| Provides string manipulation utilities that are not provided in the standard C++ string class. More... | |
| class | Teuchos::Time |
| Basic wall-clock timer class. More... | |
| class | Teuchos::TimeMonitor |
| A timer class that starts when constructed and stops when the destructor is called. More... | |
| class | Teuchos::TreeBuildingXMLHandler |
| TreeBuildingXMLHandler assembles a XMLObject from your XML input. More... | |
| class | Teuchos::Utils |
| This class provides some basic string and floating-point utilities for Teuchos. More... | |
| class | Teuchos::RawWorkspace |
| Encapulsation object for raw temporary workspace that has been allocated. More... | |
| class | Teuchos::Workspace< T > |
| Templated class for workspace creation. More... | |
| class | Teuchos::WorkspaceStore |
| Workspace encapsulation class. More... | |
| class | Teuchos::WorkspaceStoreInitializeable |
| WorkspaceStore class that can be used to actually reinitialize memory. More... | |
| class | Teuchos::XMLInputSource |
| XMLInputSource represents a source of XML input that can be parsed to produce an XMLObject. More... | |
| class | Teuchos::XMLInputStream |
| XMLInputStream represents an XML input stream that can be used by a XMLInputSource. More... | |
| class | Teuchos::XMLObject |
| Representation of an XML data tree. XMLObject is a ref-counted handle to a XMLObjectImplem object, allowing storage by reference. More... | |
| class | Teuchos::XMLObjectImplem |
| The XMLObjectImplem class takes care of the low-level implementation details of XMLObject. More... | |
| class | Teuchos::XMLParameterListReader |
| Writes an XML object to a parameter list. More... | |
| class | Teuchos::XMLParameterListWriter |
| Writes a ParameterList to an XML object. More... | |
| class | Teuchos::map |
| This class creates a basic map object for platforms where the std::map is deficient, otherwise the std::map is injected into the Teuchos namespace. More... | |
Typedefs | |
| typedef basic_oblackholestream< char, std::char_traits< char > > | oblackholestream |
Enumerations | |
| enum | ESide { LEFT_SIDE, RIGHT_SIDE } |
| enum | ETransp { NO_TRANS, TRANS, CONJ_TRANS } |
| enum | EUplo { UPPER_TRI, LOWER_TRI } |
| enum | EDiag { UNIT_DIAG, NON_UNIT_DIAG } |
| enum | DataAccess { Copy, View } |
| enum | ENull { null } |
Used to initialize a RefCountPtr object to NULL using an implicit conversion! More... | |
| enum | EPrePostDestruction { PRE_DESTROY, POST_DESTROY } |
| Used to specify a pre or post destruction of extra data. More... | |
Functions | |
| template<class T> | |
| ostream & | operator<< (ostream &os, const Array< T > &array) |
| template<class T> | |
| int | hashCode (const Array< T > &array) |
| template<class T> | |
| std::string | toString (const Array< T > &array) |
| template<class T> | |
| ArrayArg< 1, T > | arrayArg (T t1) |
| Return an array with 1 member. | |
| template<class T> | |
| ArrayArg< 2, T > | arrayArg (T t1, T t2) |
| Return an array with 2 members. | |
| template<class T> | |
| ArrayArg< 3, T > | arrayArg (T t1, T t2, T t3) |
| Return an array with 3 members. | |
| template<class T> | |
| ArrayArg< 4, T > | arrayArg (T t1, T t2, T t3, T t4) |
| Return an array with 4 members. | |
| template<class T> | |
| ArrayArg< 5, T > | arrayArg (T t1, T t2, T t3, T t4, T t5) |
| Return an array with 5 members. | |
| template<class T> | |
| ArrayArg< 6, T > | arrayArg (T t1, T t2, T t3, T t4, T t5, T t6) |
| Return an array with 6 members. | |
| void | dyn_cast_throw_exception (const char type_from_name[], const char type_from_concr_name[], const char type_to_name[]) |
| We throw a m_bad_cast, which is a subclass of bad_cast. | |
| template<class T_To, class T_From> | |
| T_To & | dyn_cast (T_From &from) |
Dynamic casting utility function meant to replace dynamic_cast<T&> by throwing a better documented error message. | |
| template<class T> | |
| const T & | getConst (T &t) |
| Return a constant reference to an object given a non-const reference. | |
| template<class Key> | |
| string | toString (const HashSet< Key > &h) |
| template<class Key> | |
| ostream & | operator<< (ostream &os, const HashSet< Key > &h) |
| template<class Key, class Value> | |
| string | toString (const Hashtable< Key, Value > &h) |
| template<class Key, class Value> | |
| ostream & | operator<< (ostream &os, const Hashtable< Key, Value > &h) |
| template<class T> | |
| RefCountPtr< T > | rcp (T *p, bool owns_mem=true) |
Create a RefCountPtr object properly typed. | |
| template<class T, class Dealloc_T> | |
| RefCountPtr< T > | rcp (T *p, Dealloc_T dealloc, bool owns_mem) |
| Initialize from a raw pointer with a deallocation policy. | |
| template<class T2, class T1> | |
| RefCountPtr< T2 > | rcp_implicit_cast (const RefCountPtr< T1 > &p1) |
Implicit cast of underlying RefCountPtr type from T1* to T2*. | |
| template<class T2, class T1> | |
| RefCountPtr< T2 > | rcp_static_cast (const RefCountPtr< T1 > &p1) |
Static cast of underlying RefCountPtr type from T1* to T2*. | |
| template<class T2, class T1> | |
| RefCountPtr< T2 > | rcp_const_cast (const RefCountPtr< T1 > &p1) |
Constant cast of underlying RefCountPtr type from T1* to T2*. | |
| template<class T2, class T1> | |
| RefCountPtr< T2 > | rcp_dynamic_cast (const RefCountPtr< T1 > &p1, bool throw_on_fail=false) |
Dynamic cast of underlying RefCountPtr type from T1* to T2*. | |
| template<class T1, class T2> | |
| void | set_extra_data (const T1 &extra_data, const std::string &name, RefCountPtr< T2 > *p, bool force_unique=true, EPrePostDestruction destroy_when=POST_DESTROY) |
Set extra data associated with a RefCountPtr object. | |
| template<class T1, class T2> | |
| T1 & | get_extra_data (RefCountPtr< T2 > &p, const std::string &name) |
Get a non-const reference to extra data associated with a RefCountPtr object. | |
| template<class T1, class T2> | |
| const T1 & | get_extra_data (const RefCountPtr< T2 > &p, const std::string &name) |
Get a const reference to extra data associated with a RefCountPtr object. | |
| template<class Dealloc_T, class T> | |
| Dealloc_T & | get_dealloc (RefCountPtr< T > &p) |
Return a non-const reference to the underlying deallocator object. | |
| template<class Dealloc_T, class T> | |
| const Dealloc_T & | get_dealloc (const RefCountPtr< T > &p) |
Return a const reference to the underlying deallocator object. | |
| string | Teuchos_Version () |
| void | set_default_workspace_store (const Teuchos::RefCountPtr< WorkspaceStore > &default_workspace_store) |
| Set pointer to global workspace object. | |
| Teuchos::RefCountPtr< WorkspaceStore > | get_default_workspace_store () |
Get the global workspace object set by set_default_workspace_store(). | |
| void | print_memory_usage_stats (const WorkspaceStore *workspace_store, std::ostream &out) |
| Print statistics on memory usage. | |
Variables | |
| const char | ESideChar [] = {'L' , 'R' } |
| const char | ETranspChar [] = {'N' , 'T' , 'C' } |
| const char | EUploChar [] = {'U' , 'L' } |
| const char | EDiagChar [] = {'U' , 'N' } |
| float | flt_nan = +0.0/sin(0.0) |
| double | dbl_nan = +0.0/sin(0.0) |
|
|
Definition at line 38 of file Teuchos_oblackholestream.hpp. |
|
|
Definition at line 45 of file Teuchos_BLAS_types.hpp. |
|
|
Definition at line 50 of file Teuchos_BLAS_types.hpp. |
|
|
Definition at line 56 of file Teuchos_BLAS_types.hpp. |
|
|
Definition at line 61 of file Teuchos_BLAS_types.hpp. |
|
|
If set to Copy, user data will be copied at construction. If set to View, user data will be encapsulated and used throughout the life of the object.
Definition at line 47 of file Teuchos_DataAccess.hpp. |
|
||||||||||||||||
|
Definition at line 148 of file Teuchos_Array.hpp. |
|
||||||||||
|
Definition at line 153 of file Teuchos_Array.hpp. |
|
||||||||||
|
Definition at line 177 of file Teuchos_Array.hpp. |
|
||||||||||||||||
|
We throw a m_bad_cast, which is a subclass of bad_cast. This is necessary, since bad_cast lacks the appropriate constructor for use with the TEST_FOR_EXCEPTION macro. Definition at line 36 of file Teuchos_dyn_cast.cpp. |
|
||||||||||
|
Dynamic casting utility function meant to replace
Existing uses of the built-in
C &c = dynamic_cast<C&>(a); are easily replaced as:
C &c = dyn_cast<C>(a); and that is it. One could write a perl script to do this automatically.
This utility function is designed to cast an object reference of type Consider the following class hierarchy:
class A {}; class B : public A {}; class C : public A {}; Now consider the following program: int main( int argc, char* argv[] ) { B b; A &a = b; try { std::cout << "\nTrying: dynamic_cast<C&>(a);\n"; dynamic_cast<C&>(a); } catch( const std::bad_cast &e ) { std::cout << "\nCaught std::bad_cast exception e where e.what() = \"" << e.what() << "\"\n"; } try { std::cout << "\nTrying: Teuchos::dyn_cast<C>(a);\n"; Teuchos::dyn_cast<C>(a); } catch( const std::bad_cast &e ) { std::cout << "\nCaught std::bad_cast exception e where e.what() = \"" << e.what() << "\"\n"; } return 0; } The above program will print something that looks like (compiled with g++ for example):
Trying: dynamic_cast<C&>(a); Caught std::bad_cast exception e where e.what() = "St8bad_cast" Trying: Teuchos::dyn_cast<C>(a); Caught std::bad_cast exception e where e.what() = "../../../../packages/teuchos/src/Teuchos_dyn_cast.cpp:46: true: dyn_cast<1C>(1A) : Error, the object with the concrete type '1B' (passed in through the interface type '1A') does not support the interface '1C' and the dynamic cast failed!"
The above program shows that the standard implementation of
Note that this function is inlined and does not incur any significant runtime performance penalty over the raw Definition at line 147 of file Teuchos_dyn_cast.hpp. |
|
||||||||||
|
Return a constant reference to an object given a non-const reference. This function just provides a shorthand notation for const_cast<const T&>(t) getCost(t) Definition at line 47 of file Teuchos_getConst.hpp. |
|
||||||||||
|
Definition at line 99 of file Teuchos_HashSet.hpp. |
|
||||||||||||||||
|
Definition at line 255 of file Teuchos_HashSet.hpp. |
|
||||||||||
|
Definition at line 246 of file Teuchos_Hashtable.hpp. |
|
||||||||||||||||
|
Definition at line 324 of file Teuchos_Hashtable.hpp. |
|
|
Definition at line 36 of file Teuchos_Version.hpp. |
|
|
Definition at line 31 of file Teuchos_BLAS.cpp. |
|
|
Definition at line 32 of file Teuchos_BLAS.cpp. |
|
|
Definition at line 33 of file Teuchos_BLAS.cpp. |
|
|
Definition at line 34 of file Teuchos_BLAS.cpp. |
|
|
Definition at line 38 of file Teuchos_ScalarTraits.cpp. |
|
|
Definition at line 39 of file Teuchos_ScalarTraits.cpp. |
1.3.9.1