NsfwMethodChannel class

Inheritance

Constructors

NsfwMethodChannel()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scanEventStream Stream<Map>
no setteroverride

Methods

availableModels() Future<List<ModelDescriptor>>
override
cancelScan() Future<void>
override
checkCameraPermission() Future<PermissionStatus>
override
checkPermission() Future<PhotoLibraryPermissionStatus>
override
clearScanCache({String? modelId}) Future<void>
Clear the persistent scan-result cache. Default no-op.
override
deleteModel(String modelId) Future<void>
Delete a previously-downloaded model. Default no-op.
override
downloadModel(String modelId, {String? url}) Future<bool>
Download a downloadable model. Default throws.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
pickMedia({required String type, required bool multiple, int? maxItems}) Future<List<Map>>
Pure media picker (no classification). Default throws.
override
preloadModel(String modelId) Future<void>
Compile / warm the model. Default no-op so test mocks don't need to stub.
override
requestCameraPermission() Future<PermissionStatus>
override
requestPermission() Future<PhotoLibraryPermissionStatus>
override
resetScan() Future<void>
Reset scan state (clears native checkpoints, etc.). Default no-op.
override
scanFilePath(String filePath, {String? modelId}) Future<Map>
Scan an image file from path. Default throws.
override
scanImageBytes(Uint8List bytes, {String? modelId}) Future<Map>
Scan raw image bytes. Default throws.
override
scanSingleAsset(String localIdentifier, {String? modelId}) Future<Map>
override
setLogging(bool enabled) Future<void>
Toggle native logging. Default no-op.
override
setModelUrl(String modelId, String url) Future<void>
Set a custom download URL for a model. Default no-op.
override
startCameraScan(CameraConfiguration config) Future<void>
override
startPickAndScan(ScanConfiguration config, int maxItems) Future<void>
Picker scan. Default throws — enable by overriding in your native impl.
override
startScan(ScanConfiguration config) Future<void>
override
stopCameraScan() Future<void>
override
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited