Consolidated getValueBounds() into a single function