(bits: string)
| 768 | } |
| 769 | |
| 770 | function toBitArray(bits: string): BitArray { |
| 771 | const inArr = new BitArray(); |
| 772 | const str: string[] = bits.replace(DOTX, '').split(''); |
| 773 | for (let aStr of str) { |
| 774 | inArr.appendBit(aStr === 'X'); |
| 775 | } |
| 776 | return inArr; |
| 777 | } |
| 778 | |
| 779 | function toBooleanArray(bitArray: BitArray) { |
| 780 | const result: boolean[] = new Array<boolean>(bitArray.getSize()); |
no test coverage detected