Header constructor

Header({
  1. Consensus? version,
  2. String? chainId,
  3. Int64? height,
  4. Timestamp? time,
  5. BlockID? lastBlockId,
  6. List<int>? lastCommitHash,
  7. List<int>? dataHash,
  8. List<int>? validatorsHash,
  9. List<int>? nextValidatorsHash,
  10. List<int>? consensusHash,
  11. List<int>? appHash,
  12. List<int>? lastResultsHash,
  13. List<int>? evidenceHash,
  14. List<int>? proposerAddress,
})

Implementation

factory Header({
  $2.Consensus? version,
  $core.String? chainId,
  $fixnum.Int64? height,
  $3.Timestamp? time,
  BlockID? lastBlockId,
  $core.List<$core.int>? lastCommitHash,
  $core.List<$core.int>? dataHash,
  $core.List<$core.int>? validatorsHash,
  $core.List<$core.int>? nextValidatorsHash,
  $core.List<$core.int>? consensusHash,
  $core.List<$core.int>? appHash,
  $core.List<$core.int>? lastResultsHash,
  $core.List<$core.int>? evidenceHash,
  $core.List<$core.int>? proposerAddress,
}) {
  final _result = create();
  if (version != null) {
    _result.version = version;
  }
  if (chainId != null) {
    _result.chainId = chainId;
  }
  if (height != null) {
    _result.height = height;
  }
  if (time != null) {
    _result.time = time;
  }
  if (lastBlockId != null) {
    _result.lastBlockId = lastBlockId;
  }
  if (lastCommitHash != null) {
    _result.lastCommitHash = lastCommitHash;
  }
  if (dataHash != null) {
    _result.dataHash = dataHash;
  }
  if (validatorsHash != null) {
    _result.validatorsHash = validatorsHash;
  }
  if (nextValidatorsHash != null) {
    _result.nextValidatorsHash = nextValidatorsHash;
  }
  if (consensusHash != null) {
    _result.consensusHash = consensusHash;
  }
  if (appHash != null) {
    _result.appHash = appHash;
  }
  if (lastResultsHash != null) {
    _result.lastResultsHash = lastResultsHash;
  }
  if (evidenceHash != null) {
    _result.evidenceHash = evidenceHash;
  }
  if (proposerAddress != null) {
    _result.proposerAddress = proposerAddress;
  }
  return _result;
}