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

## org.crosswire.jsword.view.web
Class DownloadSet

    java.lang.Object
      org.crosswire.jsword.view.web.DownloadSet

All Implemented Interfaces:
  Comparable

    public class DownloadSet

extends Object
implements Comparable

A helper for the download.jsp page.

Author:
  Joe Walker [joe at eireneh dot com]
See Also:
  `for license details. The copyright to this program is held by it's authors.`

Field Summary
`static String` | `BIN_TGZ`
`static String` | `BIN_ZIP`
`private boolean` | `datesort`
`private static DateFormat` | `DF_DISK`
`private static DateFormat` | `DF_USER`
`static String` | `DOC_TGZ`
`static String` | `DOC_ZIP`
`private String` | `localprefix`
`protected static Logger` | `log` The log stream
`private static NumberFormat` | `NF`
`private String` | `setname`
`static String` | `SRC_TGZ`
`static String` | `SRC_ZIP`
`private static String` | `TEST_PREFIX`
`private static String` | `TEST_SUFFIX`
`private static String` | `VERSION_DATE`
`private String` | `webprefix`

Constructor Summary
`private` | `DownloadSet(String localprefix, String webprefix, String setname, boolean datesort)` Create a set of downloads

Method Summary
`int` | `compareTo(Object obj)`
`String` | `getDateString()` When was the set of files created (using the file name string)
`static DownloadSet[]` | `getDownloadSets(String localprefix, String webprefix, boolean datesort)` Get an Iterator over all the Downloads in the specified Directory
`String` | `getLinkString(String extension)` Get a short HTML string for the download link.
`String` | `getVersionString()` What is the version number (using the file name string)

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

Field Detail

### BIN_ZIP

    public static final String BIN_ZIP

See Also:
  Constant Field Values

### BIN_TGZ

    public static final String BIN_TGZ

See Also:
  Constant Field Values

### SRC_ZIP

    public static final String SRC_ZIP

See Also:
  Constant Field Values

### SRC_TGZ

    public static final String SRC_TGZ

See Also:
  Constant Field Values

### DOC_ZIP

    public static final String DOC_ZIP

See Also:
  Constant Field Values

### DOC_TGZ

    public static final String DOC_TGZ

See Also:
  Constant Field Values

### datesort

    private boolean datesort

### webprefix

    private String webprefix

### localprefix

    private String localprefix

### setname

    private String setname

### TEST_PREFIX

    private static final String TEST_PREFIX

See Also:
  Constant Field Values

### TEST_SUFFIX

    private static final String TEST_SUFFIX

See Also:
  Constant Field Values

### NF

    private static final NumberFormat NF

### VERSION_DATE

    private static final String VERSION_DATE

See Also:
  Constant Field Values

### DF_DISK

    private static final DateFormat DF_DISK

### DF_USER

    private static final DateFormat DF_USER

### log

    protected static final Logger log

  The log stream

Constructor Detail

### DownloadSet

    private DownloadSet(String localprefix,
                        String webprefix,
                        String setname,
                        boolean datesort)

  Create a set of downloads

Method Detail

### getDownloadSets

    public static DownloadSet[] getDownloadSets(String localprefix,
                                                String webprefix,
                                                boolean datesort)
                                         throws IOException

  Get an Iterator over all the Downloads in the specified Directory

  Throws:
    `IOException`

### compareTo

    public int compareTo(Object obj)

  Specified by:
    `compareTo` in interface `Comparable`

### getDateString

    public String getDateString()
                         throws ParseException

  When was the set of files created (using the file name string)

  Throws:
    `ParseException`

### getVersionString

    public String getVersionString()

  What is the version number (using the file name string)

### getLinkString

    public String getLinkString(String extension)

  Get a short HTML string for the download link. Purists would complain that this is UI specific code embedded where it ought not be. So such I would argue - rewrite this so that it still works (not easy given the JSP/XML use) and so that it is just as simple and so that it can actually be reused in a more general UI.

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