Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def get_fields(cls):
return {
1: ('version', p.UVarintType, 0),
2: ('type', p.UVarintType, 0),
3: ('nonce', p.UVarintType, 0),
4: ('gas_price', p.UVarintType, 0),
5: ('gas_limit', p.UVarintType, 0),
6: ('payer', p.UnicodeType, 0),
7: ('tx_attributes', OntologyTxAttribute, p.FLAG_REPEATED),
}
def get_fields(cls) -> Dict:
return {
1: ('amount', p.UVarintType, 0),
2: ('destination', p.UnicodeType, 0),
3: ('destination_tag', p.UVarintType, 0),
}
def get_fields(cls):
return {
1: ('signature_index', p.UVarintType, 0),
2: ('signature', p.BytesType, 0),
3: ('serialized_tx', p.BytesType, 0),
}
def get_fields(cls):
return {
1: ('address', p.UnicodeType, 0),
2: ('address_n', p.UVarintType, p.FLAG_REPEATED),
3: ('amount', p.UVarintType, 0), # required
4: ('script_type', p.UVarintType, 0), # required
5: ('multisig', MultisigRedeemScriptType, 0),
6: ('op_return_data', p.BytesType, 0),
7: ('decred_script_version', p.UVarintType, 0),
8: ('block_hash_bip115', p.BytesType, 0),
9: ('block_height_bip115', p.UVarintType, 0),
}
def get_fields(cls) -> Dict:
return {
1: ('source_account', p.UnicodeType, 0),
2: ('selling_asset', StellarAssetType, 0),
3: ('buying_asset', StellarAssetType, 0),
4: ('amount', p.SVarintType, 0),
5: ('price_n', p.UVarintType, 0),
6: ('price_d', p.UVarintType, 0),
7: ('offer_id', p.UVarintType, 0),
}
def get_fields(cls) -> Dict:
return {
1: ('payer', p.UVarintType, 0),
2: ('receiver', p.UVarintType, 0),
3: ('quantity', EosAsset, 0),
}
def get_fields(cls) -> Dict:
return {
1: ('display_random', p.BoolType, 0),
2: ('strength', p.UVarintType, 0), # default=256
3: ('passphrase_protection', p.BoolType, 0),
4: ('pin_protection', p.BoolType, 0),
5: ('language', p.UnicodeType, 0), # default=en-US
6: ('label', p.UnicodeType, 0),
7: ('u2f_counter', p.UVarintType, 0),
8: ('skip_backup', p.BoolType, 0),
9: ('no_backup', p.BoolType, 0),
10: ('backup_type', p.EnumType("BackupType", (0, 1, 2)), 0), # default=Bip39
}
def get_fields(cls) -> Dict:
return {
1: ('outputs_count', p.UVarintType, 0), # required
2: ('inputs_count', p.UVarintType, 0), # required
3: ('coin_name', p.UnicodeType, 0), # default=Bitcoin
4: ('version', p.UVarintType, 0), # default=1
5: ('lock_time', p.UVarintType, 0), # default=0
6: ('expiry', p.UVarintType, 0),
7: ('overwintered', p.BoolType, 0),
8: ('version_group_id', p.UVarintType, 0),
9: ('timestamp', p.UVarintType, 0),
10: ('branch_id', p.UVarintType, 0),
}
def get_fields(cls) -> Dict:
return {
1: ('account', p.UVarintType, 0),
2: ('code', p.UVarintType, 0),
3: ('type', p.UVarintType, 0),
4: ('requirement', p.UVarintType, 0),
}
def get_fields(cls):
return {
1: ('address_n', p.UVarintType, p.FLAG_REPEATED),
2: ('data', p.BytesType, 0),
3: ('global_commitment', p.BytesType, 0),
4: ('global_pubkey', p.BytesType, 0),
}