Skip to content

Instantly share code, notes, and snippets.

@bigbany
Created April 11, 2022 14:47
Show Gist options
  • Save bigbany/c1297450dd30dc0e393863f82941dcfb to your computer and use it in GitHub Desktop.
Save bigbany/c1297450dd30dc0e393863f82941dcfb to your computer and use it in GitHub Desktop.
interface_abstract
void main(){
BoyGroup bts = BoyGroup('BTS');
print(bts is IdolInterface);
}
abstract class IdolInterface{
String name;
IdolInterface(this.name);
void sayName();
}
class BoyGroup implements IdolInterface{
String name;
BoyGroup(this.name);
void sayName(){}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment