clearAll method
Clear all models from OPFS (for testing/development)
Returns: Number of files deleted
Implementation
Future<int> clearAll() async {
try {
final count = await _opfs.clearAll().toDart;
final deletedCount = count.toDartInt;
debugPrint('[WebOPFSService] Cleared $deletedCount files from OPFS');
return deletedCount;
} catch (e) {
debugPrint('[WebOPFSService] Failed to clear OPFS: $e');
throw Exception('Failed to clear OPFS: $e');
}
}