Library 5

bugfix
This commit is contained in:
Alessandro Ferro
2021-06-02 10:02:21 +02:00
parent 980fce4cb7
commit 828ec16447
9 changed files with 139 additions and 50 deletions

View File

@@ -9,13 +9,15 @@
#include "../../list/list.hpp"
#include "../../vector/vector.hpp"
#include <iostream>
namespace lasd {
template <typename Data>
class MatrixCSR : virtual public List<std::pair<Data,ulong>>,
virtual public Matrix<Data>{ // Must extend Matrix<Data>
protected:
public: //CAMBIARE A PROTETTO !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
using Matrix<Data>::rows;
using Matrix<Data>::columns;
@@ -33,7 +35,7 @@ protected:
| next
*/
public:
//public:
// Default constructor
MatrixCSR();
@@ -79,8 +81,8 @@ public:
bool ExistsCell(const ulong&, const ulong&) const noexcept override; // Override Matrix member (should not throw exceptions)
Data& operator()(const ulong&, const ulong&) override; // Override Matrix member (mutable access to the element; throw out_of_range when out of range)
const Data& operator()(const ulong&, const ulong&) const override; // Override Matrix member (immutable access to the element; throw out_of_range when out of range and length_error when not present)
Data& operator()(const ulong, const ulong) override; // Override Matrix member (mutable access to the element; throw out_of_range when out of range)
const Data& operator()(const ulong, const ulong) const override; // Override Matrix member (immutable access to the element; throw out_of_range when out of range and length_error when not present)
/* ************************************************************************ */
@@ -102,6 +104,7 @@ public:
virtual void FoldPreOrder(const typename FoldableContainer<Data>::FoldFunctor, const void*, void*) const override; // Override FoldableContainer member
virtual void FoldPostOrder(const typename FoldableContainer<Data>::FoldFunctor, const void*, void*) const override; // Override FoldableContainer member
void debug();
};
/* ************************************************************************** */