Image for post
Image for post
public class Email{public void sendMail(){// send mail 
}
}
public class Notification{private Email _email;public Notification(){_email = new Email();
}
public void promotionalNotification(){_email.sendMail(); …


Image for post
Image for post
public interface someInterface{public int methodOne(){
// Do something
}public int methodTwo(){
// Do somthing diffrent
}}
public someClass implements someInterface{public int methodOne(){
// logic to do something
}public int methodTwo(){
}
}
public interface someInterface{public int methodOne(){
// Do something
}}public interface someDiffrentInterface{public int methodTwo(){
// Do somthing diffrent
}}

Image for post
Image for post
public class Bird{
public void fly(){}
}
public class Duck extends Bird{}
public class Ostrich extends Bird{}

Image for post
Image for post

Image for post

Image for post
Image for post

use-case with Dart/Flutter


Image for post
Image for post


Image for post
Image for post

About

Hussein Reda

Software engineer

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store