Skip to content

Commit

Permalink
Merge pull request #177 from xch-dev/split-bindings
Browse files Browse the repository at this point in the history
Split bindings into multiple files
  • Loading branch information
Rigidity authored Feb 25, 2025
2 parents 181a7e0 + 26d2160 commit 045d199
Show file tree
Hide file tree
Showing 17 changed files with 2,204 additions and 2,165 deletions.
1,758 changes: 0 additions & 1,758 deletions bindings.json

Large diffs are not rendered by default.

21 changes: 21 additions & 0 deletions bindings/address.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"Address": {
"type": "class",
"new": true,
"fields": {
"puzzle_hash": "Bytes32",
"prefix": "String"
},
"methods": {
"encode": {
"return": "String"
},
"decode": {
"type": "factory",
"args": {
"address": "String"
}
}
}
}
}
146 changes: 146 additions & 0 deletions bindings/bls.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,146 @@
{
"SecretKey": {
"type": "class",
"methods": {
"from_seed": {
"type": "factory",
"args": {
"seed": "Bytes"
}
},
"from_bytes": {
"type": "factory",
"args": {
"bytes": "Bytes32"
}
},
"to_bytes": {
"return": "Bytes32"
},
"public_key": {
"return": "PublicKey"
},
"sign": {
"args": {
"message": "Bytes"
},
"return": "Signature"
},
"derive_unhardened": {
"args": {
"index": "u32"
},
"return": "SecretKey"
},
"derive_hardened": {
"args": {
"index": "u32"
},
"return": "SecretKey"
},
"derive_unhardened_path": {
"args": {
"path": "Vec<u32>"
},
"return": "SecretKey"
},
"derive_hardened_path": {
"args": {
"path": "Vec<u32>"
},
"return": "SecretKey"
},
"derive_synthetic": {
"return": "SecretKey"
},
"derive_synthetic_hidden": {
"args": {
"hidden_puzzle_hash": "Bytes32"
},
"return": "SecretKey"
}
}
},
"PublicKey": {
"type": "class",
"methods": {
"infinity": {
"type": "factory"
},
"aggregate": {
"type": "factory",
"args": {
"public_keys": "Vec<PublicKey>"
}
},
"from_bytes": {
"type": "factory",
"args": {
"bytes": "Bytes48"
}
},
"to_bytes": {
"return": "Bytes48"
},
"fingerprint": {
"return": "u32"
},
"is_infinity": {
"return": "bool"
},
"is_valid": {
"return": "bool"
},
"derive_unhardened": {
"args": {
"index": "u32"
},
"return": "PublicKey"
},
"derive_unhardened_path": {
"args": {
"path": "Vec<u32>"
},
"return": "PublicKey"
},
"derive_synthetic": {
"return": "PublicKey"
},
"derive_synthetic_hidden": {
"args": {
"hidden_puzzle_hash": "Bytes32"
},
"return": "PublicKey"
}
}
},
"Signature": {
"type": "class",
"methods": {
"infinity": {
"type": "factory"
},
"aggregate": {
"type": "factory",
"args": {
"signatures": "Vec<Signature>"
}
},
"from_bytes": {
"type": "factory",
"args": {
"bytes": "Bytes96"
}
},
"to_bytes": {
"return": "Bytes96"
},
"is_infinity": {
"return": "bool"
},
"is_valid": {
"return": "bool"
}
}
}
}
Loading

0 comments on commit 045d199

Please sign in to comment.