1 /*
2 * $Id$
3 */
4
5 package com.javaforge.bobber.archetype.model;
6
7 //---------------------------------/
8 //- Imported classes and packages -/
9 //---------------------------------/
10
11 import java.util.Date;
12
13 /**
14 *
15 * Represents a template in the archetype to be
16 * processed
17 * .
18 *
19 * @version $Revision$ $Date$
20 */
21 public class Template implements java.io.Serializable {
22
23
24 //--------------------------/
25 //- Class/Member Variables -/
26 //--------------------------/
27
28 /**
29 * Field file.
30 */
31 private String file;
32
33 /**
34 * Field output.
35 */
36 private String output;
37
38 /**
39 * If the specified variable is true, the template will be
40 * processed, otherwise skipped.
41 */
42 private String dependsOnVar;
43
44
45 //-----------/
46 //- Methods -/
47 //-----------/
48
49 /**
50 * Get if the specified variable is true, the template will be
51 * processed, otherwise skipped.
52 *
53 * @return String
54 */
55 public String getDependsOnVar()
56 {
57 return this.dependsOnVar;
58 } //-- String getDependsOnVar()
59
60 /**
61 * Get the file field.
62 *
63 * @return String
64 */
65 public String getFile()
66 {
67 return this.file;
68 } //-- String getFile()
69
70 /**
71 * Get the output field.
72 *
73 * @return String
74 */
75 public String getOutput()
76 {
77 return this.output;
78 } //-- String getOutput()
79
80 /**
81 * Set if the specified variable is true, the template will be
82 * processed, otherwise skipped.
83 *
84 * @param dependsOnVar
85 */
86 public void setDependsOnVar(String dependsOnVar)
87 {
88 this.dependsOnVar = dependsOnVar;
89 } //-- void setDependsOnVar(String)
90
91 /**
92 * Set the file field.
93 *
94 * @param file
95 */
96 public void setFile(String file)
97 {
98 this.file = file;
99 } //-- void setFile(String)
100
101 /**
102 * Set the output field.
103 *
104 * @param output
105 */
106 public void setOutput(String output)
107 {
108 this.output = output;
109 } //-- void setOutput(String)
110
111
112 private String modelEncoding = "UTF-8";
113
114 /**
115 * Set an encoding used for reading/writing the model.
116 *
117 * @param modelEncoding the encoding used when reading/writing the model.
118 */
119 public void setModelEncoding( String modelEncoding )
120 {
121 this.modelEncoding = modelEncoding;
122 }
123
124 /**
125 * @return the current encoding used when reading/writing this model.
126 */
127 public String getModelEncoding()
128 {
129 return modelEncoding;
130 }
131 }