1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23 package net.sf.statcvs.output;
24
25 import java.io.IOException;
26
27 /**
28 * Manager for the handling of CSS files. There are different ways for speciying
29 * CSS files (local file, default file from the distribution JAR, HTTP URL).
30 * A CssHandler must be implemented for each of these ways.
31 *
32 * TODO: Should be refactored into something that produces a ReportFile, which
33 * has methods getURL() and write() and can be added to report pages.
34 *
35 * @author Richard Cyganiak
36 */
37 public interface CssHandler {
38
39 /**
40 * returns a link to the CSS file, which can be used as the HREF in HTML's
41 * <LINK REL="stylesheet"> HREF="filename.css";.
42 *
43 * @return a link to the CSS file
44 */
45 String getLink();
46
47 /**
48 * Checks if all necessary resources are available. This can be
49 * used, for example, to check if a local CSS file really exists
50 * or if a HTTP URL is valid.
51 *
52 * @throws ConfigurationException if some resource is missing.
53 */
54 void checkForMissingResources() throws ConfigurationException;
55
56 /**
57 * Creates any necessary output files.
58 *
59 * @throws IOException if an output file can't be created
60 */
61 void createOutputFiles() throws IOException;
62 }