use factory methods for exceptions