jaxx.runtime.swing.renderer
Class MultiDecoratorTableCelleRenderer

java.lang.Object
  extended by jaxx.runtime.swing.renderer.MultiDecoratorTableCelleRenderer
All Implemented Interfaces:
TableCellRenderer

public class MultiDecoratorTableCelleRenderer
extends Object
implements TableCellRenderer

A TableCellRenderer which compute text with the matching decorator from decorators based on the type of value and leave the hand to the delegate to perform the visual renderer.

Since:
2.0.0
Author:
tchemit

Field Summary
protected  Decorator<?>[] decorators
          decorators for accepted types
protected  TableCellRenderer delegate
          Delegate cell renderer
protected  List<Class<?>> types
          accepted types
 
Constructor Summary
MultiDecoratorTableCelleRenderer(JXPathDecorator<?>... decorator)
           
MultiDecoratorTableCelleRenderer(TableCellRenderer delegate, JXPathDecorator<?>... decorator)
           
 
Method Summary
 Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasfocus, int row, int column)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

delegate

protected TableCellRenderer delegate
Delegate cell renderer


types

protected List<Class<?>> types
accepted types


decorators

protected Decorator<?>[] decorators
decorators for accepted types

Constructor Detail

MultiDecoratorTableCelleRenderer

public MultiDecoratorTableCelleRenderer(JXPathDecorator<?>... decorator)

MultiDecoratorTableCelleRenderer

public MultiDecoratorTableCelleRenderer(TableCellRenderer delegate,
                                        JXPathDecorator<?>... decorator)
Method Detail

getTableCellRendererComponent

public Component getTableCellRendererComponent(JTable table,
                                               Object value,
                                               boolean isSelected,
                                               boolean hasfocus,
                                               int row,
                                               int column)
Specified by:
getTableCellRendererComponent in interface TableCellRenderer


Copyright © 2008-2011 CodeLutin. All Rights Reserved.