Changed ODataException class to return the exception

Changed exception class to return an exception rather than throwing it. Also changed anywhere that the exception class is called to then throw that exception.