BarcodeScannerPluginPlatform class abstract

Inheritance
  • Object
  • PlatformInterface
  • BarcodeScannerPluginPlatform
Implementers

Constructors

BarcodeScannerPluginPlatform()
Token dùng để xác thực instance khi gọi setter, đảm bảo chỉ có instance hợp lệ mới có thể ghi đè (phục vụ Mock cho Unit Test).

Properties

barcodeStream Stream<String>
Stream phát ra mã vạch khi máy quét phần cứng (PDA) quét thành công. Sử dụng EventChannel để lắng nghe Broadcast Intents từ hệ thống. Dùng với StreamBuilder hoặc listen() để nhận dữ liệu real-time.
no setter
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
startCameraScan() Future<String?>
Mở màn hình camera và quét mã vạch sử dụng CameraX + Google ML Kit. Trả về mã vạch nếu quét thành công, hoặc null nếu người dùng hủy. Phù hợp với điện thoại thông minh không có máy quét phần cứng chuyên dụng.
toString() String
A string representation of this object.
inherited

Operators

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

Static Properties

instance BarcodeScannerPluginPlatform
Getter để truy cập instance hiện tại (Singleton pattern).
getter/setter pair