GNU Octave  6.2.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
octave::index_exception Class Referenceabstract

#include "lo-array-errwarn.h"

Inheritance diagram for octave::index_exception:
Collaboration diagram for octave::index_exception:

Public Member Functions

 index_exception (const std::string &index, octave_idx_type nd=0, octave_idx_type dim=-1, const char *var="")
 
 ~index_exception (void)=default
 
virtual const char * err_id (void) const =0
 
void set_pos (octave_idx_type nd_arg, octave_idx_type dim_arg)
 
void set_pos_if_unset (octave_idx_type nd_arg, octave_idx_type dim_arg)
 
void set_var (const std::string &var_arg="")
 
virtual void update_message (void)
 

Protected Member Functions

std::string expression (void) const
 

Protected Attributes

octave_idx_type m_dim
 
octave_idx_type m_nd
 
std::string m_var
 

Private Attributes

std::string m_index
 

Detailed Description

Definition at line 44 of file lo-array-errwarn.h.

Constructor & Destructor Documentation

◆ index_exception()

octave::index_exception::index_exception ( const std::string &  index,
octave_idx_type  nd = 0,
octave_idx_type  dim = -1,
const char *  var = "" 
)
inline

Definition at line 48 of file lo-array-errwarn.h.

References expression().

◆ ~index_exception()

octave::index_exception::~index_exception ( void  )
default

Member Function Documentation

◆ err_id()

virtual const char* octave::index_exception::err_id ( void  ) const
pure virtual

◆ expression()

std::string octave::index_exception::expression ( void  ) const
protected

◆ set_pos()

void octave::index_exception::set_pos ( octave_idx_type  nd_arg,
octave_idx_type  dim_arg 
)
inline

Definition at line 64 of file lo-array-errwarn.h.

References m_dim, m_nd, and update_message().

Referenced by Cell::assign(), and Cell::delete_elements().

◆ set_pos_if_unset()

◆ set_var()

void octave::index_exception::set_var ( const std::string &  var_arg = "")
inline

◆ update_message()

virtual void octave::index_exception::update_message ( void  )
inlinevirtual

Reimplemented in octave::out_of_range, octave::invalid_index, and octave::complex_index_exception.

Definition at line 61 of file lo-array-errwarn.h.

References expression().

Referenced by set_pos(), set_pos_if_unset(), and set_var().

Member Data Documentation

◆ m_dim

octave_idx_type octave::index_exception::m_dim
protected

Definition at line 105 of file lo-array-errwarn.h.

Referenced by expression(), set_pos(), and set_pos_if_unset().

◆ m_index

std::string octave::index_exception::m_index
private

Definition at line 94 of file lo-array-errwarn.h.

Referenced by expression().

◆ m_nd

octave_idx_type octave::index_exception::m_nd
protected

Definition at line 102 of file lo-array-errwarn.h.

Referenced by expression(), set_pos(), and set_pos_if_unset().

◆ m_var

std::string octave::index_exception::m_var
protected

Definition at line 108 of file lo-array-errwarn.h.

Referenced by expression(), and set_var().


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