FormCast.datetime constructor

FormCast.datetime({
  1. TextStyle? style,
  2. VoidCallback? onTap,
  3. FocusNode? focusNode,
  4. bool autofocus = false,
  5. bool? enableFeedback,
  6. EdgeInsetsGeometry? padding,
  7. bool hideDefaultSuffixIcon = false,
  8. DateTime? initialPickerDateTime,
  9. CupertinoDatePickerOptions? cupertinoDatePickerOptions,
  10. MaterialDatePickerOptions? materialDatePickerOptions,
  11. MaterialTimePickerOptions? materialTimePickerOptions,
  12. InputDecoration? decoration,
  13. DateFormat? dateFormat,
  14. DateTime? firstDate,
  15. DateTime? lastDate,
  16. DateTimeFieldPickerMode mode = DateTimeFieldPickerMode.dateAndTime,
  17. DateTimeFieldPickerPlatform pickerPlatform = DateTimeFieldPickerPlatform.adaptive,
})

Cast to datetime

Implementation

FormCast.datetime({
  TextStyle? style,
  VoidCallback? onTap,
  FocusNode? focusNode,
  bool autofocus = false,
  bool? enableFeedback,
  EdgeInsetsGeometry? padding,
  bool hideDefaultSuffixIcon = false,
  DateTime? initialPickerDateTime,
  CupertinoDatePickerOptions? cupertinoDatePickerOptions,
  MaterialDatePickerOptions? materialDatePickerOptions,
  MaterialTimePickerOptions? materialTimePickerOptions,
  InputDecoration? decoration,
  DateFormat? dateFormat,
  DateTime? firstDate,
  DateTime? lastDate,
  DateTimeFieldPickerMode mode = DateTimeFieldPickerMode.dateAndTime,
  DateTimeFieldPickerPlatform pickerPlatform =
      DateTimeFieldPickerPlatform.adaptive,
}) {
  this.type = "datetime";
  this.metaData = {};
  this.metaData['style'] = style;
  this.metaData['onTap'] = onTap;
  this.metaData['focusNode'] = focusNode;
  this.metaData['autofocus'] = autofocus;
  this.metaData['enableFeedback'] = enableFeedback;
  this.metaData['padding'] = padding;
  this.metaData['hideDefaultSuffixIcon'] = hideDefaultSuffixIcon;
  this.metaData['initialPickerDateTime'] = initialPickerDateTime;
  this.metaData['cupertinoDatePickerOptions'] = cupertinoDatePickerOptions;
  this.metaData['materialDatePickerOptions'] = materialDatePickerOptions;
  this.metaData['materialTimePickerOptions'] = materialTimePickerOptions;
  this.metaData['decoration'] = decoration;
  this.metaData['dateFormat'] = dateFormat;
  this.metaData['firstDate'] = firstDate;
  this.metaData['lastDate'] = lastDate;
  this.metaData['mode'] = mode;
  this.metaData['pickerPlatform'] = pickerPlatform;
}