org.eclipse.jetty.http

## Class HttpContent.ResourceAsHttpContent

- java.lang.Object
- - org.eclipse.jetty.http.HttpContent.ResourceAsHttpContent

- All Implemented Interfaces:
    HttpContent
  Enclosing interface:
    HttpContent

      public static class HttpContent.ResourceAsHttpContent
      extends Object
      implements HttpContent

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface org.eclipse.jetty.http.HttpContent

      `HttpContent.ResourceAsHttpContent`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `HttpContent.ResourceAsHttpContent(Resource resource, Buffer mimeType)`
    `HttpContent.ResourceAsHttpContent(Resource resource, Buffer mimeType, boolean etag)`
    `HttpContent.ResourceAsHttpContent(Resource resource, Buffer mimeType, int maxBuffer)`
    `HttpContent.ResourceAsHttpContent(Resource resource, Buffer mimeType, int maxBuffer, boolean etag)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `long` | `getContentLength()`
    `Buffer` | `getContentType()`
    `Buffer` | `getDirectBuffer()`
    `Buffer` | `getETag()`
    `Buffer` | `getIndirectBuffer()`
    `InputStream` | `getInputStream()`
    `Buffer` | `getLastModified()`
    `Resource` | `getResource()`
    `void` | `release()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### HttpContent.ResourceAsHttpContent

          public HttpContent.ResourceAsHttpContent(Resource resource,
                                           Buffer mimeType)

    - #### HttpContent.ResourceAsHttpContent

          public HttpContent.ResourceAsHttpContent(Resource resource,
                                           Buffer mimeType,
                                           int maxBuffer)

    - #### HttpContent.ResourceAsHttpContent

          public HttpContent.ResourceAsHttpContent(Resource resource,
                                           Buffer mimeType,
                                           boolean etag)

    - #### HttpContent.ResourceAsHttpContent

          public HttpContent.ResourceAsHttpContent(Resource resource,
                                           Buffer mimeType,
                                           int maxBuffer,
                                           boolean etag)

  - ### Method Detail

    - #### getContentType

          public Buffer getContentType()

      Specified by:
        `getContentType` in interface `HttpContent`

    - #### getLastModified

          public Buffer getLastModified()

      Specified by:
        `getLastModified` in interface `HttpContent`

    - #### getDirectBuffer

          public Buffer getDirectBuffer()

      Specified by:
        `getDirectBuffer` in interface `HttpContent`

    - #### getETag

          public Buffer getETag()

      Specified by:
        `getETag` in interface `HttpContent`

    - #### getIndirectBuffer

          public Buffer getIndirectBuffer()

      Specified by:
        `getIndirectBuffer` in interface `HttpContent`

    - #### getContentLength

          public long getContentLength()

      Specified by:
        `getContentLength` in interface `HttpContent`

    - #### getInputStream

          public InputStream getInputStream()
                                     throws IOException

      Specified by:
        `getInputStream` in interface `HttpContent`
      Throws:
        `IOException`

    - #### getResource

          public Resource getResource()

      Specified by:
        `getResource` in interface `HttpContent`

    - #### release

          public void release()

      Specified by:
        `release` in interface `HttpContent`

Copyright © 1995-2016 Mort Bay Consulting. All Rights Reserved.