added docblock, added setAllowed method
added setStatusCode
refactored, changed handling of exceptions, moved setStatusCode method, moved validResponse check to respond method, added getResponse method