# Document
Date: 2012-02-24

## com.google.appengine.api.conversion
Class Document

    java.lang.Object
      com.google.appengine.api.conversion.Document

    public final class Document

extends java.lang.Object

An immutable document for conversion. A document must contain at least one asset, typically the document contents. Additional assets are those needed for the conversion, for example images in HTML.

Constructor Summary
`Document(Asset firstAsset)` Constructs a document.
`Document(java.util.List<Asset> assets)` Constructs a document.

Method Summary
`boolean` `equals(java.lang.Object o)`
`java.util.List<Asset>` `getAssets()` Returns all assets associated with the document.
`int` `hashCode()`

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

Constructor Detail

### Document

    public Document(Asset firstAsset)

  Constructs a document.

  Parameters:
    `firstAsset` - the first asset to add

### Document

    public Document(java.util.List<Asset> assets)

  Constructs a document.

  Parameters:
    `assets` - a list of assets to add
  Throws:
    `java.lang.IllegalArgumentException` - if the assets list is empty

Method Detail

### getAssets

    public java.util.List<Asset> getAssets()

  Returns all assets associated with the document.

### equals

    public boolean equals(java.lang.Object o)

  Overrides:
    `equals` in class `java.lang.Object`

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `java.lang.Object`