You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

20 lines
456 B

import { checkColumnIndex } from '../util';
import BaseView from './base';
export default class MatrixColumnView extends BaseView {
constructor(matrix, column) {
checkColumnIndex(matrix, column);
super(matrix, matrix.rows, 1);
this.column = column;
}
set(rowIndex, columnIndex, value) {
this.matrix.set(rowIndex, this.column, value);
return this;
}
get(rowIndex) {
return this.matrix.get(rowIndex, this.column);
}
}