classbase64class
remconst
รหัสการแปลง Dimsbase_64_Characters '
dimlenstring 'คำนวณความยาวของสตริง
เคาน์เตอร์ dimicount
ค่า dimreturnvalue'return
อักขระแคช Dimtempchar '
สตริงแคช dimtempstring '
สตริงพารามิเตอร์ dimparamstring '
Dimtemhex 'แคชแคช Hexadecimal
แคช Dimtemplow 'ต่ำบิต
Dimtemphigh 'แคชสูงบิต
dimmod3string '
dimmod4string '
dimtempbinary '
dimtempbyteone '
dimtempbytetwo '
dimtempbytethree '
dimtempbytefour '
dimtempsavebitsone '
dimtempsavebitstwo '
-
'เริ่มเรียนการเริ่มต้น
-
Privatesubclass_initialize ()
SBASE_64_CHARACTERS = "ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/" ENDENDUB
-
'จบการเริ่มต้นคลาส'
-
-
'เริ่มทำลายชั้นเรียน
-
Privatesubclass_terminate ()
SBASE_64_CHARACTERS = "" ENDENDUB
-
'จบชั้นเรียน
-
-
'เริ่มต้นการเข้ารหัส Base64 ของสตริง ANSI-encoded
-
PublicFunctionEncode (Paramstring)
tempstring = ""
returnValue = ""
Lenstring = Len (Paramstring)
Iflenstring <1 จากนั้น
ENCODE = RETURNVALUE
อื่น
mod3string = lenstringMod3
'จำนวนตัวเลขคือการอำนวยความสะดวกในการคำนวณ
ifmod3string> 0 แล้ว
lenstring = lenstring+3-mod3string
lenstring = lenstring-3
endif