ProposalCreateContract.fromJson constructor
Create a new ProposalCreateContract instance by parsing a JSON map.
Implementation
factory ProposalCreateContract.fromJson(Map<String, dynamic> json) {
return ProposalCreateContract(
ownerAddress: OnChainUtils.parseTronAddress(
value: json['owner_address'], name: 'owner_address'),
parameters: OnChainUtils.parseMap<dynamic, dynamic>(
value: json['parameters'], name: 'parameters') ==
null
? null
: (json['parameters'] as Map).map(
(key, value) => MapEntry<BigInt, BigInt>(
OnChainUtils.parseBigInt(value: key, name: 'parameters'),
OnChainUtils.parseBigInt(value: value, name: 'parameters')),
),
);
}