1 |
package appl.data; |
2 |
|
3 |
import java.io.Serializable; |
4 |
|
5 |
/** |
6 |
* A class that automatically loads a specified object and returns it, as soon |
7 |
* as the {@link #load()} method is invoked. It is the counterpart of {@link DataUnloader}. |
8 |
* |
9 |
* @author Dominik Appl |
10 |
* @see DataUnloader |
11 |
*/ |
12 |
public interface DataLoader extends Serializable { |
13 |
|
14 |
/** |
15 |
* On invocation the data is loaded and returned |
16 |
* |
17 |
* @return the newly loaded object |
18 |
* |
19 |
* @throws LoadingException if for some reason the data could not |
20 |
* be loaded |
21 |
*/ |
22 |
public Object load() throws LoadingException; |
23 |
|
24 |
/** |
25 |
* @return some general information about the loading class |
26 |
* (like what the class exactly loads) |
27 |
* |
28 |
*/ |
29 |
public String getLoadInfo(); |
30 |
|
31 |
} |