matlab::data::Reference<SparseArray<T>>
Templated C++ class to get reference to SparseArray
Description
Use the Reference<SparseArray>
class to get a reference to a
SparseArray
element of a container object, such as a MATLAB® structure or cell array.
Class Details
Namespace: | matlab::data |
Include: | SparseArrayRef.hpp |
Template Parameters
|
Type of elements in |
Iterators
Begin Iterators
iterator begin()
const_iterator begin() const
const_iterator cbegin() const
|
Iterator to beginning of array, specified as
|
|
Iterator, specified as |
None
End Iterators
iterator end()
const_iterator end() const
const_iterator cend() const
|
Iterator to beginning of array, specified as
|
|
Iterator, specified as |
None
Member Functions
getNumberOfNonZeroElements
size_t getNumberOfNonZeroElements() const
Returns the number of nonzero elements in the array. Since sparse arrays only store nonzero elements, this method returns the actual array size. It is different from array dimensions that specify the full array size.
|
Number of nonzero elements in the array. |
None
Version History
Introduced in R2017b