Commit 1e74c6d1 authored by Jakub Klinkovský's avatar Jakub Klinkovský
Browse files

Added method getLength to SparseRow

parent 8b374ff7
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -49,6 +49,9 @@ class SparseRow
      __cuda_callable__
      const Real& getElementValue( const Index& elementIndex ) const;

      __cuda_callable__
      Index getLength() const;

      void print( std::ostream& str ) const;

   protected:
+9 −0
Original line number Diff line number Diff line
@@ -98,6 +98,15 @@ getElementValue( const Index& elementIndex ) const
   return this->values[ elementIndex * step ];
}

template< typename Real, typename Index >
__cuda_callable__
Index
SparseRow< Real, Index >::
getLength() const
{
   return length;
}

template< typename Real, typename Index >
void
SparseRow< Real, Index >::