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

com.github.bordertech.wcomponents.addons.table.TableColumn Maven / Gradle / Ivy

The newest version!
package com.github.bordertech.wcomponents.addons.table;

import com.github.bordertech.wcomponents.WComponent;
import com.github.bordertech.wcomponents.WTableColumn;
import java.io.Serializable;
import java.util.Comparator;

/**
 * Table column renderer and bean value definitions.
 *
 * @param  the table column value
 * @param  the row bean type
 * @author Jonathan Austin
 */
public interface TableColumn extends Serializable {

	/**
	 * @param bean the row bean
	 * @return the value for this column
	 */
	V getValue(final T bean);

	/**
	 * @param bean the row bean
	 * @param value the new value
	 */
	void setValue(final T bean, final V value);

	/**
	 * @return the column comparator
	 */
	Comparator getComparator();

	/**
	 * @return true if column is editable
	 */
	boolean isEditable();

	/**
	 * @return the column id used in config
	 */
	String getColumnId();

	/**
	 * @return the column label
	 */
	String getColumnLabel();

	/**
	 * @return an instance of the renderer
	 */
	WComponent getRenderer();

	/**
	 * @return the column width
	 */
	int getWidth();

	/**
	 * @return the column alignment
	 */
	WTableColumn.Alignment getAlignment();
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy