input could be null, should ideally be protected.