30 lines
582 B
PHP
30 lines
582 B
PHP
<?php
|
|
|
|
namespace Arma\Internal;
|
|
|
|
/**
|
|
* Interface for diagonal subview of matrices (Mat and SpMat).
|
|
*
|
|
* @package Arma\Internal
|
|
*/
|
|
interface Diagonal extends Base, NonResizable, Subview
|
|
{
|
|
/**
|
|
* Read/write access to the n-th element.
|
|
*
|
|
* @param int $idx
|
|
* @return Scalar
|
|
*/
|
|
function __invoke($idx);
|
|
|
|
/**
|
|
* Read/write access to the n-th element.
|
|
*
|
|
* Without a bounds check. Not recommended for use unless your code has been thoroughly debugged.
|
|
*
|
|
* @param int $idx
|
|
* @return Scalar
|
|
*/
|
|
function at($idx);
|
|
}
|