Refactor to use DomainException

Leaving InvalidArgumentException for errors like invalid types or nulls.