private static boolean cv_to_64 ( long number , char [ ] code , int len ) { long act ; int iDigit , nDigits ; char [ ] result = new char [ 5 ] ; if ( len > 5 ) return false ; act = number ; nDigits = len - 1 ; for ( iDigit = 0 ; iDigit < nDigits ; iDigit ++ ) { result [ nDigits - iDigit - 1 ] = cConversionTable [ ( int ) ( act % 64 ) ] ; act /= 64 ; } result [ len - 1 ] = ' ' ; if ( act != 0 ) return false ; for ( int i = 0 ; i < result . length ; i ++ ) code [ i ] = result [ i ] ; return true ; }
Conversion of an integer into a number with base 64 using the table cConversionTable