Flood::Vector< Type > Class Template Reference

#include <Vector.h>

List of all members.

Public Member Functions

 Vector (void)
 Vector (int)
 Vector (int, const Type &)
 Vector (const char *)
 Vector (const Vector &)
virtual ~Vector (void)
Vectoroperator= (const Vector &)
Type & operator[] (int)
const Type & operator[] (int) const
Vector< Type > operator+ (const Type &) const
Vector< Type > operator+ (const Vector< Type > &) const
Vector< Type > operator- (const Type &) const
Vector< Type > operator- (const Vector< Type > &) const
Vector< Type > operator* (const Type &) const
Vector< Type > operator* (const Vector< Type > &) const
Vector< Type > operator/ (const Type &) const
Vector< Type > operator/ (const Vector< Type > &) const
void operator+= (const Type &) const
void operator+= (const Vector< Type > &) const
void operator-= (const Type &) const
void operator-= (const Vector< Type > &) const
void operator*= (const Type &) const
void operator*= (const Vector< Type > &) const
void operator/= (const Type &) const
void operator/= (const Vector< Type > &) const
bool operator== (const Vector< Type > &) const
bool operator== (const Type &) const
bool operator!= (const Vector< Type > &) const
bool operator!= (const Type &) const
bool operator> (const Vector< Type > &) const
bool operator> (const Type &) const
bool operator< (const Vector< Type > &) const
bool operator< (const Type &) const
bool operator>= (const Vector< Type > &) const
bool operator>= (const Type &) const
bool operator<= (const Vector< Type > &) const
bool operator<= (const Type &) const
Type * begin () const
Type * end () const
int get_size (void) const
bool get_display (void) const
void set (void)
void set (int)
void set (int, const Type &)
void set (const Vector &)
void set (const char *)
void set_size (int)
void set_size (int, const Type &)
void set_display (bool)
void resize (int)
bool is_zero (void) const
void insert (int, const Vector< Type > &) const
Vector< Type > extract (int, int) const
Vector< Type > assemble (const Vector< Type > &) const
void initialize (const Type &) const
void initialize_sequential (void) const
void initialize_uniform (void) const
void initialize_uniform (double, double) const
void initialize_uniform (const Vector< double > &, const Vector< double > &) const
void initialize_normal (void) const
void initialize_normal (double, double) const
void initialize_normal (const Vector< double > &, const Vector< double > &) const
Type dot (const Vector< Type > &) const
Vector< Type > dot (const Matrix< Type > &) const
Matrix< Type > outer (const Vector< Type > &) const
Type calculate_sum (void) const
Type calculate_product (void) const
double calculate_mean (void) const
double calculate_standard_deviation (void) const
Vector< double > calculate_mean_standard_deviation (void) const
Type calculate_minimum (void) const
Type calculate_maximum (void) const
Vector< Type > calculate_minimum_maximum (void) const
int calculate_minimal_index (void) const
int calculate_maximal_index (void) const
Vector< int > calculate_minimal_maximal_index (void) const
double calculate_norm (void) const
Vector< Type > calculate_lower_bounded (const Type &) const
Vector< Type > calculate_lower_bounded (const Vector< Type > &) const
Vector< Type > calculate_upper_bounded (const Type &) const
Vector< Type > calculate_upper_bounded (const Vector< Type > &) const
Vector< Type > calculate_lower_upper_bounded (const Type &, const Type &) const
Vector< Type > calculate_lower_upper_bounded (const Vector< Type > &, const Vector< Type > &) const
void apply_lower_bound (const Type &)
void apply_lower_bound (const Vector< Type > &)
void apply_upper_bound (const Type &)
void apply_upper_bound (const Vector< Type > &)
void apply_lower_upper_bounds (const Type &, const Type &)
void apply_lower_upper_bounds (const Vector< Type > &, const Vector< Type > &)
std::string to_XML (bool)
void save (const char *)
void save_data (const char *)
void load (const char *)
void load_data (const char *)


Detailed Description

template<class Type>
class Flood::Vector< Type >

This template class defines a vector for general purpose use. This vector also implements some mathematical methods which can be useful.

Definition at line 40 of file Vector.h.


Constructor & Destructor Documentation

template<class Type >
Flood::Vector< Type >::Vector ( void   )  [inline, explicit]

Default constructor. It creates a vector of size zero.

Definition at line 255 of file Vector.h.

template<class Type >
Flood::Vector< Type >::Vector ( int  new_size  )  [inline, explicit]

General constructor. It creates a vector of size n, containing n copies of the default value for Type.

Parameters:
new_size Size of vector.

Definition at line 267 of file Vector.h.

template<class Type>
Flood::Vector< Type >::Vector ( int  new_size,
const Type &  value 
) [inline, explicit]

Constant reference initialization constructor. It creates a vector of size n, containing n copies of the type value of Type.

Parameters:
new_size Size of Vector.
value Initialization value of Type.

Definition at line 296 of file Vector.h.

template<class Type>
Flood::Vector< Type >::Vector ( const char *  filename  )  [inline, explicit]

File constructor. It creates a vector object by loading its members from a XML-type file.

Parameters:
filename Name of vector XML-type file.

Definition at line 328 of file Vector.h.

template<class Type>
Flood::Vector< Type >::Vector ( const Vector< Type > &  other_vector  )  [inline]

Copy constructor. It creates a copy of an existing Vector.

Parameters:
other_vector Vector to be copied.

Definition at line 342 of file Vector.h.

template<class Type >
Flood::Vector< Type >::~Vector ( void   )  [inline, virtual]

Destructor.

Definition at line 362 of file Vector.h.


Member Function Documentation

template<class Type>
Vector< Type > Flood::Vector< Type >::assemble ( const Vector< Type > &  other_vector  )  const [inline]

Assemble two vectors.

Parameters:
other_vector Vector to be assembled to this vector.

Definition at line 2958 of file Vector.h.

template<class Type >
Type * Flood::Vector< Type >::begin ( void   )  const [inline]

This method returns a vector to the first element in the container.

Definition at line 2545 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::calculate_lower_bounded ( const Vector< Type > &  lower_bound  )  const [inline]

This method bounds the elements of the vector if they fall below their corresponding lower bound values.

Parameters:
lower_bound Lower bound values.

Definition at line 1714 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::calculate_lower_bounded ( const Type &  lower_bound  )  const [inline]

This method bounds the elements of the vector if they fall below a lower bound value.

Parameters:
lower_bound Lower bound values.

Definition at line 1692 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::calculate_lower_upper_bounded ( const Vector< Type > &  lower_bound,
const Vector< Type > &  upper_bound 
) const [inline]

This method bounds the elements of the vector if they fall above or below their corresponding lower or upper bound values, respectively.

Parameters:
lower_bound Lower bound values.
upper_bound Upper bound values.

Definition at line 1864 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::calculate_lower_upper_bounded ( const Type &  lower_bound,
const Type &  upper_bound 
) const [inline]

This method bounds the elements of the vector if they fall above or below their lower or upper bound values, respectively.

Parameters:
lower_bound Lower bound value.
upper_bound Upper bound value.

Definition at line 1832 of file Vector.h.

template<class Type >
int Flood::Vector< Type >::calculate_maximal_index ( void   )  const [inline]

This method returns the index of the largest element in the vector.

Definition at line 1467 of file Vector.h.

template<class Type >
Type Flood::Vector< Type >::calculate_maximum ( void   )  const [inline]

This method returns the largest element in the vector.

Definition at line 1392 of file Vector.h.

template<class Type >
double Flood::Vector< Type >::calculate_mean ( void   )  const [inline]

This method returns the mean of the elements in the vector.

Definition at line 1561 of file Vector.h.

template<class Type >
Vector< double > Flood::Vector< Type >::calculate_mean_standard_deviation ( void   )  const [inline]

This method returns the mean and the standard deviation of the elements in the vector.

Definition at line 1628 of file Vector.h.

template<class Type >
int Flood::Vector< Type >::calculate_minimal_index ( void   )  const [inline]

This method returns the index of the smallest element in the vector.

Definition at line 1444 of file Vector.h.

template<class Type >
Vector< int > Flood::Vector< Type >::calculate_minimal_maximal_index ( void   )  const [inline]

This method returns a vector with the indexes of the smallest and the largest elements in the vector.

Definition at line 1490 of file Vector.h.

template<class Type >
Type Flood::Vector< Type >::calculate_minimum ( void   )  const [inline]

This method returns the smallest element in the vector.

Definition at line 1371 of file Vector.h.

template<class Type >
Vector< Type > Flood::Vector< Type >::calculate_minimum_maximum ( void   )  const [inline]

This method returns a vector containing the smallest and the largest elements in the vector.

Definition at line 1413 of file Vector.h.

template<class Type >
double Flood::Vector< Type >::calculate_norm ( void   )  const [inline]

This element returns the vector norm.

Definition at line 1669 of file Vector.h.

template<class Type >
Type Flood::Vector< Type >::calculate_product ( void   )  const [inline]

This method returns the product of the elements in the vector.

Definition at line 1543 of file Vector.h.

template<class Type >
double Flood::Vector< Type >::calculate_standard_deviation ( void   )  const [inline]

This method returns the standard deviation of the elements in the vector.

Definition at line 1591 of file Vector.h.

template<class Type >
Type Flood::Vector< Type >::calculate_sum ( void   )  const [inline]

This method returns the sum of the elements in the vector.

Definition at line 1525 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::calculate_upper_bounded ( const Vector< Type > &  upper_bound  )  const [inline]

This method bounds the elements of the vector if they fall above their corresponding upper bound values.

Parameters:
upper_bound Upper bound values.

Definition at line 1785 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::calculate_upper_bounded ( const Type &  upper_bound  )  const [inline]

This method bounds the elements of the vector if they fall above an upper bound value.

Parameters:
upper_bound Upper bound value.

Definition at line 1759 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::dot ( const Matrix< Type > &  matrix  )  const [inline]

This method returns the dot product of this vector with a matrix. The number of rows of the matrix must be equal to the size of the vector.

Parameters:
matrix matrix to be multiplied to this vector.

Definition at line 2182 of file Vector.h.

template<class Type>
Type Flood::Vector< Type >::dot ( const Vector< Type > &  other_vector  )  const [inline]

Dot product vector*vector arithmetic operator.

Parameters:
other_vector vector to be multiplied to this vector.

Definition at line 2225 of file Vector.h.

template<class Type >
Type * Flood::Vector< Type >::end ( void   )  const [inline]

This method returns a vector to the last element in the container.

Definition at line 2556 of file Vector.h.

template<class Type >
Vector< Type > Flood::Vector< Type >::extract ( int  position,
int  other_size 
) const [inline]

Extract a vector of a given size from a given position

Parameters:
position Extraction position.
other_size Size of vector to be extracted.

Definition at line 2924 of file Vector.h.

template<class Type >
bool Flood::Vector< Type >::get_display ( void   )  const [inline]

This method returns true if messages from this class are to be displayed on the screen, or false if messages from this class are not to be displayed on the screen.

Definition at line 881 of file Vector.h.

template<class Type >
int Flood::Vector< Type >::get_size ( void   )  const [inline]

This method returns the number of elements in the vector.

Definition at line 869 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::initialize ( const Type &  value  )  const [inline]

This method initializes all the elements of the vector with a given value.

Parameters:
value Type value.

Definition at line 1159 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::initialize_normal ( const Vector< double > &  mean,
const Vector< double > &  standard_deviation 
) const [inline]

This method assigns random values to each element in the vector. These are taken from normal distributions with given means and standard deviations for each element.

Parameters:
mean Mean values of normal distributions.
standard_deviation Standard deviation values of normal distributions.

Definition at line 1329 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::initialize_normal ( double  mean,
double  standard_deviation 
) const [inline]

This method assigns random values to each element in the vector. These are taken from a normal distribution with single mean and standard deviation values for all the elements.

Parameters:
mean Mean value of uniform distribution.
standard_deviation Standard deviation value of uniform distribution.

Definition at line 1297 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::initialize_normal ( void   )  const [inline]

This method assigns random values to each element in the vector. These are taken from a normal distribution with mean 0 and standard deviation 1.

Definition at line 1280 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::initialize_sequential ( void   )  const [inline]

This method initializes all the elements of the vector in a sequential order.

Definition at line 1173 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::initialize_uniform ( const Vector< double > &  minimum,
const Vector< double > &  maximum 
) const [inline]

This method assigns a random value comprised between given minimum and a maximum values to every element in the vector.

Parameters:
minimum Minimum initialization values.
maximum Maximum initialization values.

Definition at line 1236 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::initialize_uniform ( double  minimum,
double  maximum 
) const [inline]

This method assigns a random value comprised between a minimum value and a maximum value to each element in the vector.

Parameters:
minimum Minimum initialization value.
maximum Maximum initialization value.

Definition at line 1204 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::initialize_uniform ( void   )  const [inline]

This method assigns a random value comprised between -1 and 1 to each element in the vector.

Definition at line 1187 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::insert ( int  position,
const Vector< Type > &  other_vector 
) const [inline]

Insert another vector starting from a given position.

Parameters:
position Insertion position.
other_vector Vector to be inserted.

Definition at line 2891 of file Vector.h.

template<class Type >
bool Flood::Vector< Type >::is_zero ( void   )  const [inline]

This method returns true if the vector is empty, i.e., has size zero, and false otherwise.

Definition at line 892 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::load ( const char *  filename  )  [inline]

This method loads the members of a vector from an XML-type file. Please be careful with the file format, which is specified in the user's guide.

Parameters:
filename Name of vector file.

Definition at line 2656 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::load_data ( const char *  filename  )  [inline]

This method loads the elements of a vector from a data file. The file format is as follows: element_0 element_1 ... element_N-1

Parameters:
filename Filename.

Definition at line 2780 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator!= ( const Type &  value  )  const [inline]

Not equivalent relational operator between this vector and a Type value. It produces true if some element of this vector is not equal to the Type value, and false otherwise.

Parameters:
value Type value to be compared with.

Definition at line 605 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator!= ( const Vector< Type > &  other_vector  )  const [inline]

Not equivalent relational operator between this vector and other vector. It produces true if the two vectors have any not equal element, and false otherwise.

Parameters:
other_vector vector to be compared with.

Definition at line 566 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::operator* ( const Vector< Type > &  other_vector  )  const [inline]

Element by element product vector*vector arithmetic operator.

Parameters:
other_vector vector to be multiplied to this vector.

Definition at line 2144 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::operator* ( const Type &  scalar  )  const [inline]

Product vector*scalar arithmetic operator.

Parameters:
scalar Scalar value to be multiplied to this vector.

Definition at line 2125 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::operator*= ( const Vector< Type > &  other_vector  )  const [inline]

Vector product and assignment operator.

Parameters:
other_vector Vector to be multiplied to this vector.

Definition at line 2467 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::operator*= ( const Type &  value  )  const [inline]

Scalar product and assignment operator.

Parameters:
value Scalar value to be multiplied to this vector.

Definition at line 2452 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::operator+ ( const Vector< Type > &  other_vector  )  const [inline]

Sum vector+vector arithmetic operator.

Parameters:
other_vector Vector to be added to this vector.

Definition at line 2032 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::operator+ ( const Type &  scalar  )  const [inline]

Sum vector+scalar arithmetic operator.

Parameters:
scalar Scalar value to be added to this vector.

Definition at line 2013 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::operator+= ( const Vector< Type > &  other_vector  )  const [inline]

Vector sum and assignment operator.

Parameters:
other_vector Vector to be added to this vector.

Definition at line 2373 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::operator+= ( const Type &  value  )  const [inline]

Scalar sum and assignment operator.

Parameters:
value Scalar value to be added to this vector.

Definition at line 2358 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::operator- ( const Vector< Type > &  other_vector  )  const [inline]

Difference vector-vector arithmetic operator.

Parameters:
other_vector vector to be subtracted to this vector.

Definition at line 2088 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::operator- ( const Type &  scalar  )  const [inline]

Difference vector-scalar arithmetic operator.

Parameters:
scalar Scalar value to be subtracted to this vector.

Definition at line 2069 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::operator-= ( const Vector< Type > &  other_vector  )  const [inline]

Vector rest and assignment operator.

Parameters:
other_vector Vector to be subtracted to this vector.

Definition at line 2420 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::operator-= ( const Type &  value  )  const [inline]

Scalar rest and assignment operator.

Parameters:
value Scalar value to be subtracted to this vector.

Definition at line 2405 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::operator/ ( const Vector< Type > &  other_vector  )  const [inline]

Cocient vector/vector arithmetic operator.

Parameters:
other_vector vector to be divided to this vector.

Definition at line 2322 of file Vector.h.

template<class Type>
Vector< Type > Flood::Vector< Type >::operator/ ( const Type &  scalar  )  const [inline]

Cocient vector/scalar arithmetic operator.

Parameters:
scalar Scalar value to be divided to this vector.

Definition at line 2303 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::operator/= ( const Vector< Type > &  other_vector  )  const [inline]

Vector division and assignment operator.

Parameters:
other_vector Vector to be divided to this vector.

Definition at line 2514 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::operator/= ( const Type &  value  )  const [inline]

Scalar division and assignment operator.

Parameters:
value Scalar value to be divided to this vector.

Definition at line 2499 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator< ( const Type &  value  )  const [inline]

Less than relational operator between this vector and a Type value. It produces true if all the elements of this vector are less than the Type value, and false otherwise.

Parameters:
value Type value to be compared with.

Definition at line 727 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator< ( const Vector< Type > &  other_vector  )  const [inline]

Less than relational operator between this vector and other vector. It produces true if all the elements of this vector are less than the corresponding elements of the other vector, and false otherwise.

Parameters:
other_vector vector to be compared with.

Definition at line 688 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator<= ( const Type &  value  )  const [inline]

Less than or equal to than relational operator between this vector and a Type value. It produces true if all the elements of this vector are less than or equal to the Type value, and false otherwise.

Parameters:
value Type value to be compared with.

Definition at line 848 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator<= ( const Vector< Type > &  other_vector  )  const [inline]

Less than or equal to relational operator between this vector and other vector. It produces true if all the elements of this vector are less than or equal to the corresponding elements of the other vector, and false otherwise.

Parameters:
other_vector vector to be compared with.

Definition at line 809 of file Vector.h.

template<class Type >
Vector< Type > & Flood::Vector< Type >::operator= ( const Vector< Type > &  other_vector  )  [inline]

Assignment operator. It assigns to the current vector the members of an existing vector.

Parameters:
other_vector vector to be assigned.

Definition at line 377 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator== ( const Type &  value  )  const [inline]

Equivalent relational operator between this vector and a Type value. It produces true if all the elements of this vector are equal to the Type value, and false otherwise.

Parameters:
value Type value to be compared with.

Definition at line 545 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator== ( const Vector< Type > &  other_vector  )  const [inline]

Equivalent relational operator between this vector and other vector. It produces true if all the elements of the two vectors are equal, and false otherwise.

Parameters:
other_vector vector to be compared with.

Definition at line 506 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator> ( const Type &  value  )  const [inline]

Greater than relational operator between this vector and a Type value. It produces true if all the elements of this vector are greater than the Type value, and false otherwise.

Parameters:
value Type value to be compared with.

Definition at line 666 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator> ( const Vector< Type > &  other_vector  )  const [inline]

Greater than relational operator between this vector and other vector. It produces true if all the elements of this vector are greater than the corresponding elements of the other vector, and false otherwise.

Parameters:
other_vector vector to be compared with.

Definition at line 627 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator>= ( const Type &  value  )  const [inline]

Greater than or equal to than relational operator between this vector and a Type value. It produces true if all the elements of this vector are greater than or equal to the Type value, and false otherwise.

Parameters:
value Type value to be compared with.

Definition at line 787 of file Vector.h.

template<class Type>
bool Flood::Vector< Type >::operator>= ( const Vector< Type > &  other_vector  )  const [inline]

Greater than or equal to relational operator between this vector and other vector. It produces true if all the elements of this vector are greater than or equal to the corresponding elements of the other vector, and false otherwise.

Parameters:
other_vector vector to be compared with.

Definition at line 749 of file Vector.h.

template<class Type >
const Type & Flood::Vector< Type >::operator[] ( int  i  )  const [inline]

Reference operator. It returns an element of the vector.

Parameters:
i Index of element.

Definition at line 462 of file Vector.h.

template<class Type >
Type & Flood::Vector< Type >::operator[] ( int  i  )  [inline]

Reference operator. It returns an element of the vector.

Parameters:
i Index of element.

Definition at line 419 of file Vector.h.

template<class Type>
Matrix< Type > Flood::Vector< Type >::outer ( const Vector< Type > &  other_vector  )  const [inline]

Outer product vector*vector arithmetic operator.

Parameters:
other_vector vector to be multiplied to this vector.

Definition at line 2261 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::resize ( int  new_size  )  [inline]

This method sets a new size in the vector. It also initializes the elements of the new data with their corresponding previous values.

Parameters:
new_size New number of elements.

Definition at line 1117 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::save ( const char *  filename  )  [inline]

This method saves to a XML-type file the elements of the vector. The file format is as follows: element_0 element_1 ... element_N-1

Parameters:
filename Name of vector XML-type file.

Definition at line 2816 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::save_data ( const char *  filename  )  [inline]

This method saves to a data file the elements of the vector. The file format is as follows: element_0 element_1 ... element_N-1

Parameters:
filename Filename.

Definition at line 2851 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::set ( const char *  filename  )  [inline]

This method sets all the members of a vector object by loading them from an XML-type file. The format is specified in the user's guide.

Parameters:
filename Name of vector file.

Definition at line 1038 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::set ( const Vector< Type > &  other_vector  )  [inline]

This method sets the members of this object with the values of another vector.

Parameters:
other_vector Object to set this vector.

Definition at line 999 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::set ( int  new_size,
const Type &  new_value 
) [inline]

This method sets a new size to the vector and initializes all its elements with a given value. It also sets the display value to true.

Parameters:
new_size Size for the vector.
new_value Value for all the elements.

Definition at line 970 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::set ( int  new_size  )  [inline]

This method sets a new size to the vector. It does not initialize the data. It also sets the display value to true.

Parameters:
new_size Size for the vector.

Definition at line 931 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::set ( void   )  [inline]

This method sets the size of a vector to zero. It also sets the display value to true.

Definition at line 911 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::set_display ( bool  new_display  )  [inline]

This method sets a new display value. If it is set to true messages from this class are to be displayed on the screen; if it is set to false messages from this class are not to be displayed on the screen.

Parameters:
new_display Display value.

Definition at line 1052 of file Vector.h.

template<class Type>
void Flood::Vector< Type >::set_size ( int  new_size,
const Type &  new_value 
) [inline]

This method sets a new size in the vector. It also initializes the elements with a given value.

Parameters:
new_size Number of elements.
new_value Initialization value.

Definition at line 1103 of file Vector.h.

template<class Type >
void Flood::Vector< Type >::set_size ( int  new_size  )  [inline]

This method sets a new size in the vector. It does not initialize the new vector.

Parameters:
new_size New number of elements.

Definition at line 1065 of file Vector.h.

template<class Type >
std::string Flood::Vector< Type >::to_XML ( bool  show_declaration  )  [inline]

This method returns a string representation of a vector object. It contains the members in an XML-type format.

Parameters:
show_declaration True if an XML-type declaration is to be included at the beginning.

Definition at line 2609 of file Vector.h.


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

Generated on Fri Jul 30 09:52:01 2010 for Flood by  doxygen 1.5.9