org.rhq.enterprise.server.rest
Class CustomExceptionMapper

java.lang.Object
  extended by org.rhq.enterprise.server.rest.CustomExceptionMapper
All Implemented Interfaces:
javax.ws.rs.ext.ExceptionMapper<Exception>

@Provider
public class CustomExceptionMapper
extends Object
implements javax.ws.rs.ext.ExceptionMapper<Exception>

Map a NotFoundException to a HTTP response with respective error message

Author:
Heiko W. Rupp

Constructor Summary
CustomExceptionMapper()
           
 
Method Summary
 javax.ws.rs.core.Response toResponse(Exception e)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CustomExceptionMapper

public CustomExceptionMapper()
Method Detail

toResponse

public javax.ws.rs.core.Response toResponse(Exception e)
Specified by:
toResponse in interface javax.ws.rs.ext.ExceptionMapper<Exception>


Copyright © 2008-2012 Red Hat, Inc.. All Rights Reserved.