/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package uk.co.gardennotebook;

import javafx.scene.control.TableCell;
import uk.co.gardennotebook.fxbean.INotebookBean;

/**
 *
 * @author andy
 */
public class NotebookNonEditCellType<S extends INotebookBean, T> extends NotebookEditCellType<S, T>
{
    @Override
	protected boolean mayEdit(S rowItem, T cellItem)
	{
		return false;
	}
    
    @Override
	protected void updateViewMode(S rowItem, T cellItem)
    {
        setText(getTextValue(cellItem));
    }
    
    protected String getTextValue(T cellItem)
    {
        return cellItem.toString();
    }
    
}
