Skip to content

m1ome/bban_gen

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BBAN generator

Simple BBAN generator & validator

Go Report Card GoDoc Build Status Coverage Status

Installation

go get github.com/m1ome/bban_gen

Usage

package main

import (
    "fmt"

    bban "github.com/m1ome/bban_gen"
)

func main() {
	account := bban.Random("040577", "13439317554524", bban.DoubleMod)
	fmt.Printf("Generated account: %s\n", account)

	next := bban.Next("040577", account, "13439317554524", bban.DoubleMod)
	fmt.Printf("Next account: %s\n", next)

	fmt.Printf("Validity passing: %v\n", bban.Validate("040577", next, "13439317554524", bban.DoubleMod))
}

Releases

No releases published

Packages

No packages published

Languages