add visitor design pattern.