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

## juzu
Class Response.Content

    java.lang.Object
      juzu.Response
          juzu.Response.Status
              juzu.Response.Body
                  juzu.Response.Content

Enclosing class:
  Response

    public static class Response.Content

extends Response.Body

Nested Class Summary

Nested classes/interfaces inherited from class juzu.Response
`Response.Body, Response.Content, Response.Error, Response.Redirect, Response.Status, Response.View`

Constructor Summary
`Response.Content(int status, PropertyMap properties, Streamable streamable)`
`Response.Content(int status, Streamable streamable)`
`Response.Content(PropertyMap properties, Streamable streamable)`
`Response.Content(Streamable streamable)`

Method Summary
`String` | `getTitle()`
`String` | `toString()`
`Response.Content` | `with(PropertyType<Boolean> propertyType)` Set a boolean property to true.
`
`<T> Response.Content`
` | `with(PropertyType<T> propertyType, T propertyValue)` Set a property, if the value is null, the property is removed.
`Response.Content` | `withAssets(String... assets)`
`Response.Content` | `withCharset(Charset charset)`
`Response.Content` | `withHeader(String name, String... value)`
`Response.Content` | `withHeaderTag(Element header)` Set the provided element on the response as an HTML header.
`Response.Content` | `withHeaderTag(String header)` Parse the header into an `Element` and set it on the response as an header tag.
`Response.Content` | `withMetaHttpEquiv(String name, String value)`
`Response.Content` | `withMetaTag(String name, String value)`
`Response.Content` | `withMimeType(String mimeType)`
`Response.Content` | `withNo(PropertyType<Boolean> propertyType)` Set a boolean property to false.
`
`<T> Response.Content`
` | `without(PropertyType<T> propertyType)` Removes a property.
`Response.Content` | `withTitle(String title)`

Methods inherited from class juzu.Response.Body
`getCharset, getData, getMimeType`

Methods inherited from class juzu.Response.Status
`body, body, body, body, body, content, content, content, content, getCode, streamable`

Methods inherited from class juzu.Response
`content, content, content, content, content, error, error, getProperties, notFound, notFound, notFound, notFound, notFound, ok, ok, ok, ok, ok, redirect, status`

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

Constructor Detail

### Response.Content

    public Response.Content(int status,
                            PropertyMap properties,
                            Streamable streamable)

### Response.Content

    public Response.Content(int status,
                            Streamable streamable)

### Response.Content

    public Response.Content(PropertyMap properties,
                            Streamable streamable)

### Response.Content

    public Response.Content(Streamable streamable)

Method Detail

### with

    public <T> Response.Content with(PropertyType<T> propertyType,
                                     T propertyValue)
                          throws NullPointerException

  Description copied from class: `Response`
  Set a property, if the value is null, the property is removed.

  Overrides:
    `with` in class `Response.Body`
  Parameters:
    `propertyType` - the property type
    `propertyValue` - the property value
  Throws:
    `NullPointerException` - if the property type is null

### without

    public <T> Response.Content without(PropertyType<T> propertyType)
                             throws NullPointerException

  Description copied from class: `Response`
  Removes a property.

  Overrides:
    `without` in class `Response.Body`
  Parameters:
    `propertyType` - the property type
  Throws:
    `NullPointerException` - if the property type is null

### with

    public Response.Content with(PropertyType<Boolean> propertyType)
                          throws NullPointerException

  Description copied from class: `Response`
  Set a boolean property to true.

  Overrides:
    `with` in class `Response.Body`
  Parameters:
    `propertyType` - the property type
  Throws:
    `NullPointerException` - if the property type is null

### withNo

    public Response.Content withNo(PropertyType<Boolean> propertyType)
                            throws NullPointerException

  Description copied from class: `Response`
  Set a boolean property to false.

  Overrides:
    `withNo` in class `Response.Body`
  Parameters:
    `propertyType` - the property type
  Throws:
    `NullPointerException` - if the property type is null

### withMimeType

    public Response.Content withMimeType(String mimeType)

  Overrides:
    `withMimeType` in class `Response.Body`

### withCharset

    public Response.Content withCharset(Charset charset)

  Overrides:
    `withCharset` in class `Response.Body`

### withHeader

    public Response.Content withHeader(String name,
                                       String... value)

  Overrides:
    `withHeader` in class `Response.Body`

### getTitle

    public String getTitle()

### withTitle

    public Response.Content withTitle(String title)

### withAssets

    public Response.Content withAssets(String... assets)
                                throws NullPointerException

  Throws:
    `NullPointerException`

### withMetaTag

    public Response.Content withMetaTag(String name,
                                        String value)

### withMetaHttpEquiv

    public Response.Content withMetaHttpEquiv(String name,
                                              String value)

### withHeaderTag

    public Response.Content withHeaderTag(String header)
                                   throws ParserConfigurationException,
                                          SAXException

  Parse the header into an `Element` and set it on the response as an header tag. This method expects well formed XML, the parsed Element will be translated into markup according to the response content type when the response will be written to the document.

  Parameters:
    `header` - the header string to parse
  Returns:
    this object
  Throws:
    `ParserConfigurationException` - any ParserConfigurationException
    `SAXException` - any SAXException

### withHeaderTag

    public Response.Content withHeaderTag(Element header)

  Set the provided element on the response as an HTML header.

  Parameters:
    `header` - the header
  Returns:
    this object

### toString

    public String toString()

  Overrides:
    `toString` in class `Object`

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

Copyright © 2014 eXo Platform SAS. All rights reserved.