Skip to content

ArseniySavin/IINBINCheck

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This solution may checking our individual tax number, using official government algorithm. If number was checked true. We will be getting true value.

How to test

  • Create console application;
  • Add reference from IINBINCheck;
  • Paste this code into Main method;
  Console.WriteLine("Enter IIN/BIN:");
  string iin = Console.ReadLine();

  IinBinCheckContext contextIinChek = new IinBinCheckContext(iin, new DirectChek());
  contextIinChek.Check();

  Console.WriteLine("Direction check: " + contextIinChek.IsCheked.ToString());

  if(!contextIinChek.IsCheked)
  {
    contextIinChek.ChekAlgoritm = new IndirectChek();
    contextIinChek.Check();
    Console.WriteLine("Indirect check: " + contextIinChek.IsCheked.ToString());
  }
    
  Console.WriteLine("Curent key bit: " + contextIinChek.CurrentRank.ToString());

  Console.WriteLine("Result check: " + contextIinChek.IsCheked.ToString());
  
  // Data of parsing result IIN
  IINBINData iinData = contextIinChek.IINData;
  // or if you want get data the BIN
  // IINBINData binData = contextIinChek.BINData
  
  Console.ReadKey();

About

Checking IIN or BIN generated in Kazakhstan

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages