Packet constructor

Packet({
  1. Command? command,
  2. SignedCommand? signedCommand,
})

Implementation

factory Packet({
  Command? command,
  SignedCommand? signedCommand,
}) {
  final result = create();
  if (command != null) {
    result.command = command;
  }
  if (signedCommand != null) {
    result.signedCommand = signedCommand;
  }
  return result;
}