template method