1 package net.sf.jpkgmk.prototype;
2
3 import java.io.File;
4 import java.io.IOException;
5 import java.util.List;
6
7 import net.sf.jpkgmk.LineProvider;
8 import net.sf.jpkgmk.pkgmap.PkgMapEntry;
9 import net.sf.jpkgmk.util.VariableResolver;
10
11
12 /**
13 * Represents one line of a prototype file
14 *
15 * @author gommma (gommma AT users.sourceforge.net)
16 * @author Last changed by: $Author: gommma $
17 * @version $Revision: 2 $ $Date: 2008-08-20 21:14:19 +0200 (Mi, 20 Aug 2008) $
18 * @since 1.0
19 */
20 public interface PrototypeEntry extends LineProvider
21 {
22
23 /**
24 * @return Returns the type of this entry
25 */
26 public PrototypeEntryType getType();
27
28 /**
29 * Copies the file of this prototype entry into the target directory
30 * @param targetDir
31 * @param variableResolver The variable resolver to be used for expanding variables within the paths of this entry
32 * @throws IOException
33 */
34 public void create(File targetDir, VariableResolver variableResolver) throws IOException;
35
36 /**
37 * Creates the {@link PkgMapEntry} objects for this {@link PrototypeEntry}.
38 * @param targetDir The directory in which the pkgMap entry is located
39 * @param variableResolver
40 * @return The list of all created {@link PkgMapEntry} objects created by this prototype entry. Can be empty.
41 */
42 public List<PkgMapEntry> createPkgMapEntry(File targetDir, VariableResolver variableResolver);
43
44 }