org.codehaus.enunciate.modules.docs
Class DownloadBundle

java.lang.Object
  extended by org.codehaus.enunciate.main.BaseArtifact
      extended by org.codehaus.enunciate.modules.docs.DownloadBundle
All Implemented Interfaces:
java.lang.Comparable<Artifact>, Artifact, ArtifactBundle, NamedArtifact

public class DownloadBundle
extends BaseArtifact
implements ArtifactBundle, NamedArtifact

An artifact bundle the contains information about a download file.

Author:
Ryan Heaton

Constructor Summary
DownloadBundle(java.lang.String module, java.lang.String id, java.io.File file)
           
 
Method Summary
 void exportTo(java.io.File fileOrDirectory, Enunciate enunciate)
          Exports this bundle to the specified file or directory.
 java.util.Collection<? extends Artifact> getArtifacts()
          There's only one bundled artifact: the download file.
 java.util.Date getCreated()
          The modification date of the file.
 java.lang.String getDescription()
          The description of this bundle.
 java.lang.String getName()
          The name of this bundle.
 long getSize()
          The size of this download bundle.
 void setDescription(java.lang.String description)
          The description of this bundle.
 void setName(java.lang.String name)
          The name of this bundle.
 
Methods inherited from class org.codehaus.enunciate.main.BaseArtifact
addAlias, addDependency, compareTo, getAliases, getDependencies, getId, getModule, isPublic, setDependencies
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.codehaus.enunciate.main.Artifact
getAliases, getDependencies, getId, getModule, isPublic
 
Methods inherited from interface java.lang.Comparable
compareTo
 

Constructor Detail

DownloadBundle

public DownloadBundle(java.lang.String module,
                      java.lang.String id,
                      java.io.File file)
Method Detail

exportTo

public void exportTo(java.io.File fileOrDirectory,
                     Enunciate enunciate)
              throws java.io.IOException
Exports this bundle to the specified file or directory.

Specified by:
exportTo in interface Artifact
Parameters:
fileOrDirectory - The file or directory to which to export this bundle.
enunciate - The enunciated utilities to use.
Throws:
java.io.IOException - If an error occurs exporting it.

getArtifacts

public java.util.Collection<? extends Artifact> getArtifacts()
There's only one bundled artifact: the download file.

Specified by:
getArtifacts in interface ArtifactBundle
Returns:
There's only one bundled artifact: the download file.

getName

public java.lang.String getName()
The name of this bundle.

Specified by:
getName in interface NamedArtifact
Returns:
The name of this bundle.

getSize

public long getSize()
The size of this download bundle.

Specified by:
getSize in interface Artifact
Returns:
The size of this download bundle.

setName

public void setName(java.lang.String name)
The name of this bundle.

Parameters:
name - The name of this bundle.

getDescription

public java.lang.String getDescription()
The description of this bundle.

Returns:
The description of this bundle.

setDescription

public void setDescription(java.lang.String description)
The description of this bundle.

Parameters:
description - The description of this bundle.

getCreated

public java.util.Date getCreated()
The modification date of the file.

Returns:
The modification date of the file.