Added factory class extracts from design patterns book