Fluent - dart event loop mechanism and asynchronous
Welcome to WeChat official account: FSA full stack operation 👋
1, Dart asynchronous
Like JavaScript, Dart is a single thread model based on event loop mechanism, so there is no multithreading in Dart, so there is no distinction between main thread and sub thread
1. Synchronous and asynchronous
Synchronization: in the same thread, execute ...
Posted by zeth369 on Tue, 08 Mar 2022 12:24:36 +0100
) Dart asynchronous programming: futures,async,await
The article covers the following knowledge points:
How and when to use async and await keywords.How to use async and await to affect the execution order.How to use try catch to handle asynchronous call exceptions.
1, Why is asynchronous code important
Asynchronous operations allow programs to complete work while waiting for another opera ...
Posted by jbog91 on Thu, 03 Feb 2022 11:33:02 +0100
The date component and the third-party date component are included in the Flutter
Date and time stamp
You can use datetime to get the current date from the fluent Now(). now.millisecondsSinceEpoch can get the timestamp What is a timestamp
"Timestamp" refers to the total number of seconds from 00:00:00 GMT on January 1, 1970 (08:00:00 GMT on January 1, 1970) to now. Generally speaking, timestamp is a comple ...
Posted by kparker on Sat, 22 Jan 2022 00:04:05 +0100
Let Flutter transform your dialog! (Attach,Dialog,Loading,Toast)
preface
Q: What's the most smelly thing you've ever smelled in your life?
A: My rotten dream.
Brother Meng!!! I'm here again!
This time, I can confidently say to you: I finally brought you a pub package that can really help you solve many pit ratio scenes!
Put the previous shuttle_ smart_ Dialog, on the basis of maintaining the stabi ...
Posted by DarkEden on Tue, 04 Jan 2022 11:13:43 +0100
Dart series: the secret of dart excellence - isolation mechanism
brief introduction
Many asynchronous programming skills in dart were introduced before. I wonder if you have found a problem. If it is asynchronous programming in java, locking and concurrency mechanisms will certainly be mentioned, but for dart, it seems that you have never heard of multithreading and concurrency. Why?
Today, let's explain th ...
Posted by cshaul on Sat, 01 Jan 2022 23:51:20 +0100
Dart language 02 - Advanced
1, Functions
1. Custom method
//main entry method
void main() {
//Call method
printInfo();
//Custom methods can also be defined inside the main method
int getNum() {
return 1;
}
print(getNum());
}
//The custom method void has no return value
void printInfo() {
print("Custom method");
}
2. Location optional parameter m ...
Posted by ckuipers on Tue, 28 Dec 2021 21:56:14 +0100
dart series: smooth as silk, operating files and directories
brief introduction
File operation is a very common operation in IO. Is it easy to operate files in dart language? In fact, dart provides two ways to read files, one is to read all files at once, and the other is to read files as streams.
The disadvantage of one-time reading is that you need to load all the file contents into memory at one tim ...
Posted by Dj Kat on Wed, 22 Dec 2021 17:23:41 +0100
Dart series: the exclusive domain of HTML. In addition to javascript, dart can also be used
brief introduction
Although dart can be used as both client and server, dart is basically used as the basic language for fluent development. In addition to Android and ios, the web is the most common and common platform. Dart also provides native support for HTML, which is dart:html package.
dart:html provides various useful operations on DOM ...
Posted by wafawj on Tue, 07 Dec 2021 20:17:18 +0100
Flutter adds more functions of drop-down refresh and slide up loading to the list
In actual apps, pull-down refresh and slide up loading are more common forms of interaction. In the Flutter, there is a Flutter_ The easyrefresh open source plug-in is used to implement pull-down refresh and slide up load. This article introduces stateful components and fluent_ The basic application of easyrefresh completes asynchronous data lo ...
Posted by Sgarissta on Fri, 19 Nov 2021 16:15:10 +0100
Fluent implements an illustrated list
List is the most common form in App. ListView is provided in fluent to implement the list. This article will implement a list with pictures and texts through ListView.
Interface layout analysis
The list to be implemented in this chapter is shown in the figure above. After we get the interface design draft, the first thing we do in UI devel ...
Posted by stewart on Thu, 18 Nov 2021 15:51:24 +0100