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

com.woorea.openstack.console.utils.TableModel Maven / Gradle / Ivy

The newest version!
package com.woorea.openstack.console.utils;

import java.util.List;

public abstract class TableModel {
	
	protected List data;
	
	public TableModel(List data) {
		this.data = data;
	}
	
	public abstract Column[] getHeaders();

	public final String[][] getRows() {
		String[][] rows = new String[data.size()][];
		for(int i = 0; i < data.size(); i++) {
			rows[i] = getRow(data.get(i));
		}
		return rows;
	}
	
	public abstract String[] getRow(T data);
	
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy