ServiceResponse Class

Used to encapsulate a response to a ServiceRequest

Constructors

ServiceResponse( byte[] response )
ServiceResponse( javaxt.io.File file )
ServiceResponse( java.io.InputStream response )
ServiceResponse( int status, String body )
ServiceResponse( String str )
ServiceResponse( StringBuffer str )
ServiceResponse( StringBuilder str )
ServiceResponse( JSONObject json )
ServiceResponse( JSONArray json )
ServiceResponse( javaxt.sql.Model model )
ServiceResponse( int status )
ServiceResponse( Exception e )
ServiceResponse( Throwable e )

Public Methods

setContentType( String contentType ) returns void
getContentType( ) returns String
setContentDisposition( String fileName ) returns void
getContentDisposition( ) returns String
setDate( javaxt.utils.Date date ) returns void
getDate( ) returns javaxt.utils.Date
setContentLength( long contentLength ) returns void
getContentLength( ) returns Long
setCacheControl( String cacheControl ) returns void
getCacheControl( ) returns String
getStatus( ) returns int
setAuthMessage( String msg ) returns void
getAuthMessage( ) returns String
set( String key, Object val ) returns void
get( String key ) returns Object
getResponse( ) returns Object
send( HttpServletResponse response ) returns void
Used to send the response to a client by generating an HttpServletResponse
responseAn HttpServletResponse to write to
send( HttpServletResponse response, ServiceRequest req ) returns void
Used to send the response to a client by generating an HttpServletResponse
responseAn HttpServletResponse to write to
reqThe ServiceRequest associated with this response