add strategy pattern
modify time.rb