patterns/templatemethod/simplebarista/tea.d

35 lines
460 B
D

module tea;
import std.stdio : writeln;
class Tea
{
void prepareRecipe()
{
boilWater();
steepTeaBag();
pourInCup();
addLemon();
}
void boilWater()
{
writeln("Boiling water");
}
void steepTeaBag()
{
writeln("Steeping the tea");
}
void addLemon()
{
writeln("Adding Lemon");
}
void pourInCup()
{
writeln("Pouring into cup");
}
}