EmployeeAdmin/src/main/java/org/gwt4e/mvp4g/example/employeeadmin/client/ui/user/list/UserListView.java
private <C> Column<UserBean, C> addColumn(Cell<C> cell,
                                            String headerText,
                                            final GetValue<C> getter,
                                            FieldUpdater<UserBean, C> fieldUpdater) {
    Column<UserBean, C> column = new Column<UserBean, C>(cell) {
      @Override
      public C getValue(UserBean object) {
        return getter.getValue(object);
      }
    };
    column.setFieldUpdater(fieldUpdater);
    grid.addColumn(column,
                   headerText);
    return column;
  }
/**
   * Add a column with a header.
   *
   * @param <C>        the cell type
   * @param cell       the cell used to render the column
   * @param headerText the header string
   * @param getter     the value getter for the cell
   */
Add a column with a header.
@param         the cell type
@param cell       the cell used to render the column
@param headerText the header string
@param getter     the value getter for the cell
Add a column with a header . @param the cell type @param cell the cell used to render the column @param headerText the header string @param getter the value getter for the cell
private <C> Column<UserBean, C> addColumn(Cell<C> cell,
                                            String headerText,
                                            final GetValue<C> getter,
                                            FieldUpdater<UserBean, C> fieldUpdater) {
    Column<UserBean, C> column = new Column<UserBean, C>(cell) {
      @Override
      public C getValue(UserBean object) {
        return getter.getValue(object);
      }
    };
    column.setFieldUpdater(fieldUpdater);
    grid.addColumn(column,
                   headerText);
    return column;
  }
private < C > Column < UserBean , C > addColumn ( Cell < C > cell , String headerText , final GetValue < C > getter , FieldUpdater < UserBean , C > fieldUpdater ) { Column < UserBean , C > column = new Column < UserBean , C > ( cell ) { @ Override public C getValue ( UserBean object ) { return getter . getValue ( object ) ; } } ; column . setFieldUpdater ( fieldUpdater ) ; grid . addColumn ( column , headerText ) ; return column ; }
Add a column with a header.
Add a column with a header .