model view controller implemented