https://github.com/louisbrunner/cip7tocip13
Transform a CIP 7 number in a CIP 13 one
https://github.com/louisbrunner/cip7tocip13
Last synced: 9 months ago
JSON representation
Transform a CIP 7 number in a CIP 13 one
- Host: GitHub
- URL: https://github.com/louisbrunner/cip7tocip13
- Owner: LouisBrunner
- License: mit
- Created: 2014-04-02T18:53:48.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2015-04-09T23:36:13.000Z (about 11 years ago)
- Last Synced: 2025-02-23T09:23:26.220Z (over 1 year ago)
- Language: Java
- Homepage:
- Size: 119 KB
- Stars: 1
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
CIP7toCIP13
===========
Transform a CIP 7 number in a CIP 13 one.
Language: Java, Ruby
Usage
=====
Just call the `cip7tocip13` function with your CIP 7 number as argument.
You can also call the `check_cip13` function to check if your CIP 13 number is valid, or directly `compute_checksum` to generate a new checksum.
Example (Java)
==============
cip7tocip13
-----------
`cip13 = CIP7toCIP13.CIP7ToCIP13("3358854") # returns "3400933588540"`
check_cip13
-----------
`valid = CIP7toCIP13.checkCIP13("3400933588540") # returns true`
compute_checksum
----------------
`digit = CIP7toCIP13.computeChecksum("340093358854") # returns "0"`
Example (Ruby)
==============
cip7tocip13
-----------
`cip13 = CIP7toCIP13.cip7tocip13(3358854) # returns 3400933588540`
check_cip13
-----------
`valid = CIP7toCIP13.check_cip13(3400933588540) # returns true`
compute_checksum
----------------
`digit = CIP7toCIP13.compute_checksum(340093358854) # returns 0`
References
==========
http://www.ucdcip.org/telechargements/CIP_Calcul_de_la_cle_ucd.pdf
Author
======
Created by [Louis Brunner](https://github.com/Hyrrmadr).