HTMLAServProfile.Response (Alignment API and Server)
Date: 2010-03-31

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Alignment API and Server 4.0
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## fr.inrialpes.exmo.align.service
Class HTMLAServProfile.Response

    java.lang.Object
      fr.inrialpes.exmo.align.service.HTMLAServProfile.Response

Enclosing class:
  HTMLAServProfile

    public class HTMLAServProfile.Response

extends Object

HTTP response. Return one of these from serve().

Field Summary
`InputStream` | `data` Data of the response, may be null.
`Properties` | `header` Headers for the HTTP response.
`String` | `mimeType` MIME type of content, e.g.
`String` | `msg`
`String` | `status` HTTP status code after processing, e.g.

Constructor Summary
`HTMLAServProfile.Response()` Default constructor: response = HTTP_OK, data = mime = 'null'
`HTMLAServProfile.Response(String status, String mimeType, InputStream data)` Basic constructor.
`HTMLAServProfile.Response(String status, String mimeType, String txt)` Convenience method that makes an InputStream out of given text.

Method Summary
`void` | `addHeader(String name, String value)` Adds given line to the header.
`String` | `getContentType()`
`String` | `getData()`
`String` | `getStatus()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### status

    public String status

  HTTP status code after processing, e.g. "200 OK", HTTP_OK

### mimeType

    public String mimeType

  MIME type of content, e.g. "text/html"

### data

    public InputStream data

  Data of the response, may be null.

### header

    public Properties header

  Headers for the HTTP response. Use addHeader() to add lines.

### msg

    public String msg

Constructor Detail

### HTMLAServProfile.Response

    public HTMLAServProfile.Response()

  Default constructor: response = HTTP_OK, data = mime = 'null'

### HTMLAServProfile.Response

    public HTMLAServProfile.Response(String status,
                                     String mimeType,
                                     InputStream data)

  Basic constructor.

### HTMLAServProfile.Response

    public HTMLAServProfile.Response(String status,
                                     String mimeType,
                                     String txt)

  Convenience method that makes an InputStream out of given text.

Method Detail

### addHeader

    public void addHeader(String name,
                          String value)

  Adds given line to the header.

### getStatus

    public String getStatus()

### getContentType

    public String getContentType()

### getData

    public String getData()

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Alignment API and Server 4.0
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

(C) INRIA & friends, 2003-2010