You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
599 B
23 lines
599 B
// 本文件由FirstUI授权予内蒙古晟誉网络科技有限责任公司(手机号: 15 148 2 28 1 08,身份证尾号:1R6T39)专用,请尊重知识产权,勿私下传播,违者追究法律责任。
|
|
import mode from './mode.js'
|
|
|
|
function QR8bitByte(data) {
|
|
this.mode = mode.MODE_8BIT_BYTE;
|
|
this.data = data;
|
|
}
|
|
|
|
QR8bitByte.prototype = {
|
|
|
|
getLength : function(buffer) {
|
|
return this.data.length;
|
|
},
|
|
|
|
write : function(buffer) {
|
|
for (var i = 0; i < this.data.length; i++) {
|
|
// not JIS ...
|
|
buffer.put(this.data.charCodeAt(i), 8);
|
|
}
|
|
}
|
|
};
|
|
|
|
export default QR8bitByte;
|
|
|