split formatter into two methods for dates and numeric types, lay some groundwork for general numeric formatting