DataCell constructor

const DataCell(Widget child, { bool placeholder: false, bool showEditIcon: false, VoidCallback onTap })

Creates an object to hold the data for a cell in a DataTable.

The first argument is the widget to show for the cell, typically a Text or DropdownButton widget; this becomes the child property and must not be null.

If the cell has no data, then a Text widget with placeholder text should be provided instead, and then the placeholder argument should be set to true.

Implementation

const DataCell(this.child, {
  this.placeholder = false,
  this.showEditIcon = false,
  this.onTap,
}) : assert(child != null);