Stan Math Library  2.14.0
reverse mode automatic differentiation
Public Types | Public Member Functions | List of all members
stan::VectorViewMvt< const T, is_array, throw_if_accessed > Class Template Reference

VectorViewMvt with const correctness. More...

#include <VectorViewMvt.hpp>

Public Types

typedef scalar_type_pre< T >::type matrix_t
 

Public Member Functions

 VectorViewMvt (const matrix_t &m)
 
 VectorViewMvt (const std::vector< matrix_t > &vm)
 
const matrix_toperator[] (int i) const
 Allows the structure to be accessed like an array. More...
 

Detailed Description

template<typename T, bool is_array, bool throw_if_accessed>
class stan::VectorViewMvt< const T, is_array, throw_if_accessed >

VectorViewMvt with const correctness.

Definition at line 72 of file VectorViewMvt.hpp.

Member Typedef Documentation

§ matrix_t

template<typename T , bool is_array, bool throw_if_accessed>
typedef scalar_type_pre<T>::type stan::VectorViewMvt< const T, is_array, throw_if_accessed >::matrix_t

Definition at line 74 of file VectorViewMvt.hpp.

Constructor & Destructor Documentation

§ VectorViewMvt() [1/2]

template<typename T , bool is_array, bool throw_if_accessed>
stan::VectorViewMvt< const T, is_array, throw_if_accessed >::VectorViewMvt ( const matrix_t m)
inlineexplicit

Definition at line 76 of file VectorViewMvt.hpp.

§ VectorViewMvt() [2/2]

template<typename T , bool is_array, bool throw_if_accessed>
stan::VectorViewMvt< const T, is_array, throw_if_accessed >::VectorViewMvt ( const std::vector< matrix_t > &  vm)
inlineexplicit

Definition at line 78 of file VectorViewMvt.hpp.

Member Function Documentation

§ operator[]()

template<typename T , bool is_array, bool throw_if_accessed>
const matrix_t& stan::VectorViewMvt< const T, is_array, throw_if_accessed >::operator[] ( int  i) const
inline

Allows the structure to be accessed like an array.

If is_array is false, this will return the matrix it was constructed with. If is_array is true, This does not check bounds and will likely segfault if the index is out of range.

Parameters
iindex. Only used if access is true.
Returns
Reference to a matrix.
Exceptions
std::out_of_rangeif the template parameter, throw_if_accessed, is true.

Definition at line 91 of file VectorViewMvt.hpp.


The documentation for this class was generated from the following file:

     [ Stan Home Page ] © 2011–2016, Stan Development Team.