Add RandomAccessMemory class for in-memory binary operations

This commit is contained in:
ImBenji
2025-11-23 05:29:08 +00:00
parent 9216cd1638
commit 4295d119d7
26 changed files with 2124 additions and 949 deletions

View File

@@ -0,0 +1,31 @@
import 'dart:io';
import 'dart:async';
import 'package:sweepstore/debug.dart';
void main() async {
int refreshCount = 0;
while (true) {
// Clear console
if (Platform.isWindows) {
print(Process.runSync("cls", [], runInShell: true).stdout);
} else {
print(Process.runSync("clear", [], runInShell: true).stdout);
}
refreshCount++;
// Read example.bin
final file = File('example.bin');
if (await file.exists()) {
final data = await file.readAsBytes();
print('Binary dump of example.bin (${data.length} bytes) - Refresh #$refreshCount\n');
print(binaryDump(data));
print('\n--- Refreshing in 1 seconds ---');
} else {
print('Error: example.bin not found - Refresh #$refreshCount');
}
await Future.delayed(Duration(seconds: 1));
}
}