Yaohong

为了真相不惜被羞辱

The Flutter Plugin Project Files

The Flutter Plugin Project Files Creating the plugin project $ flutter create --org com.example --template=plugin --platforms=android,ios,linux,macos,windows hello_plugin Signing iOS app for device deployment using developer identity: "Apple Development: Yaohong Huang (WS3UUERGF9)" Creating project hello_plugin... Resolving dependencies in hello_plugin... (3.3s) Got dependencies in hello_plugin. Resolving dependencies in hello_plugin/example... (1.1s) Got dependencies in hello_plugin/example. Wrote 161 files. All done! Your plugin code is in hello_plugin/lib/hello_plugin.dart. Your example app code is in hello_plugin/example/lib/main.dart. Host platform code is in the android, ios, linux, macos, windows directories under hello_plugin.

The project files generated by 'flutter create --template=plugin_ffi' using dart:ffi to call C APIs

The project files generated by ‘flutter create –template=plugin_ffi’ using dart:ffi to call C APIs Flutter mobile and desktop apps can use the dart:ffi library to call native C APIs. Here are the project files generated by executing the following command: flutter create --platforms=android,ios,macos,windows,linux --template=plugin_ffi native_add flutter version: flutter_macos_3.10.5-stable Reference: 1.Binding to native Android code using dart:ffi 2.Binding to native iOS code using dart:ffi Notes: 1.The FFI library can only bind

The method with the same name from the last mixin will override the previous ones in dart

The method with the same name from the last mixin will override the previous ones in dart TestMixin file: class MyObject{ init(){ print("draw object"); } } mixin Circle{ init(){ print("draw circle"); } } mixin Square{ init(){ print("draw Square"); } } class MyShape extends MyObject with Circle, Square{ init() { super.init(); print("draw MyShape"); } } void main() { MyShape shape = MyShape(); shape.init(); } //Output: draw Square draw MyShape