All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.datastax.data.exploration.biz.datatable.DataRow Maven / Gradle / Ivy

The newest version!
package com.datastax.data.exploration.biz.datatable;

/**
 * 设置和获取某一行,某一列的值
 */
public class DataRow {

    private DataTable table;
    private int index;

    DataRow(DataTable table, int index) {
        this.table = table;
        this.index = index;
    }

    public String getData(int i) throws Exception {
        return this.table.getColumns().getColumn(i).getData(index);
    }

    public void setData(int i, String value) throws Exception {
        this.table.getColumns().getColumn(i).setData(index, value);
    }

    public String getData(String columnName) {
        return this.table.getColumns().getColumn(columnName).getData(index);
    }

    public void setData(String columnName, String value) {
        this.table.getColumns().getColumn(columnName).setData(index, value);
    }

    public Object getValue(String columnName) {
        return this.table.getColumns().getColumn(columnName).getValue(index);
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy