00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027 #include "ktoblzcheck.h"
00028
00035 #ifdef HAVE_LONG_LONG
00036 # define long_long long long
00037 #else
00038 # define long_long long
00039 #endif // HAVE_LONG_LONG
00040
00041
00042 void multArray(const int *a, const int *b, int dest[10]);
00048 void crossFoot(const int *source, int dest[10], int start, int stop);
00050 void crossFoot(int *source);
00055 int add(const int *source, int start, int stop);
00057 inline int add_10(const int *source);
00058 std::string array2Number(int a[10]);
00059 void number2Array(const std::string& number, int a[10]);
00060 long_long number2LongLong(const std::string& number);
00061
00062 int algo02(int modulus, int weight[10], bool crossfoot, int accountId[10]);
00063 int algo03(int modulus, int weight[10], bool crossfoot, int accountId[10],
00064 int startAdd, int stopAdd);
00065 int algo03a(int weight[10], bool crossfoot, int accountId[10],
00066 int startAdd, int stopAdd);
00067 int algo05(int modulus1, int modulus2, int weight[10], int accountId[10],
00068 int startAdd, int stopAdd);
00069 AccountNumberCheck::Result
00070 algo04(const std::string& bankId, std::string accountId);
00071 AccountNumberCheck::Result
00072 algo04a(const std::string& bankId, std::string accountId);
00073 AccountNumberCheck::Result
00074 algo06(const std::string& accountId);
00075 AccountNumberCheck::Result
00076 algo07(int accountId[10], int transform[6][10]);
00077 AccountNumberCheck::Result
00078 algo01(int modulus, int weight[10], bool crossfoot,
00079 int checkIndex, int accountId[10]);
00080
00081 std::string accnum_getRegKey(const char *value_name);
00082
00083 inline int add_10(const int *sp) {
00084 return sp[0] + sp[1] + sp[2] + sp[3] + sp[4]
00085 + sp[5] + sp[6] + sp[7] + sp[8] + sp[9];
00086 }