This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main(){ | |
final m1 = Model(0, b:1); | |
m1.a; | |
m1.b; | |
final m2 = Model.named(10); | |
m2.a; | |
m2.b; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main(){ | |
void a() => print("a"); | |
void b(){ | |
DateTime start = DateTime.now(); | |
DateTime now = start; | |
while(now.difference(start).inSeconds < 5) { | |
now = DateTime.now(); | |
} | |
print("b"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main(){ | |
// new OnlyTemplete(); // err -> only class | |
OnlyTemplete obj1 = Obj1(); | |
obj1.func(); | |
obj1.func2(); | |
obj1.func3(); | |
// obj1.func4(); // err -> only obj1 | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main(){ | |
Templete t_obj = Obj(); | |
t_obj.a; | |
t_obj.func(); | |
// t_obj.b; // err -> only Obj | |
} | |
class Templete{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main(){ | |
Parent p1 = Parent(); | |
Child c1 = Child(); | |
Parent pc1 = Child(); | |
p1.a; | |
// p1.b; // err -> only child | |
p1.func(); | |
p1.func3(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main() { | |
new Object(); | |
Object(); | |
Model().a; | |
Model().func(); | |
Model().func2(); | |
Model().func3(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main() { | |
/// type | |
int a = 0; | |
double a2 = 0.2; | |
String b = "b"; | |
String b2 = "bOb"; | |
bool c = true; | |
bool c2 = false; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main(){ | |
/// 1 | |
void func0(){ | |
// ... | |
} | |
void func1(){ | |
// ... | |
return; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main(){ | |
/// 1 | |
var data0 = 0; | |
dynamic data1 = 1; | |
int data2 = 2; | |
final data3 = 3; | |
const data4 = 4; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:audioplayers/audioplayers.dart'; | |
import 'package:flutter/material.dart'; | |
void main() => runApp(MyApp()); | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) => MaterialApp( | |
home: MainPage(), | |
); |
NewerOlder