Sets the given property for a matrix object.


func sparse_set_matrix_property(_ A: UnsafeMutableRawPointer!, _ pname: sparse_matrix_property) -> sparse_status



The sparse matrix object.


The property name to set to true. See sparse_matrix_property for options.

Return Value

SPARSE_SUCCESS when property is successfully set, otherwise return SPARSE_CANNOT_SET_PROPERTY.


The matrix object must not have had values inserted, else SPARSE_CANNOT_SET_PROPERTY is returned and the property is not set.Certain groups of properties are mutually exclusive and setting multiple values within a group is undefined.

See Also

General Sparse Matrix Management Operations

func sparse_commit(UnsafeMutableRawPointer!) -> sparse_status

Forces any values recently added to the matrix to be put into the internal sparse storage format.

func sparse_matrix_destroy(UnsafeMutableRawPointer!) -> sparse_status

Releases any memory associated with the matrix object.

func sparse_get_matrix_nonzero_count(UnsafeMutableRawPointer!) -> Int

Returns the number of nonzero values of a matrix.

func sparse_get_matrix_nonzero_count_for_row(UnsafeMutableRawPointer!, sparse_index) -> Int

Returns the number of nonzero values in a specified row of a matrix.

func sparse_get_matrix_nonzero_count_for_column(UnsafeMutableRawPointer!, sparse_index) -> Int

Returns the number of nonzero values in a specified column of a matrix.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software