View Javadoc

1   /*
2    * $Id$
3    */
4   
5   package org.apache.maven.profiles;
6   
7     //---------------------------------/
8    //- Imported classes and packages -/
9   //---------------------------------/
10  
11  import java.util.Date;
12  
13  /**
14   * 
15   *         This is the file specification used to activate a
16   * profile. The missing value will be a the location
17   *         of a file that needs to exist, and if it doesn't the
18   * profile must run.  On the other hand exists will test 
19   *         for the existence of the file and if it is there will
20   * run the profile.
21   *       
22   * 
23   * @version $Revision$ $Date$
24   */
25  public class ActivationFile implements java.io.Serializable {
26  
27  
28        //--------------------------/
29       //- Class/Member Variables -/
30      //--------------------------/
31  
32      /**
33       * The name of the file that should be missing to activate a
34       * profile.
35       */
36      private String missing;
37  
38      /**
39       * The name of the file that should exist to activate a profile.
40       */
41      private String exists;
42  
43  
44        //-----------/
45       //- Methods -/
46      //-----------/
47  
48      /**
49       * Get the name of the file that should exist to activate a
50       * profile.
51       * 
52       * @return String
53       */
54      public String getExists()
55      {
56          return this.exists;
57      } //-- String getExists() 
58  
59      /**
60       * Get the name of the file that should be missing to activate
61       * a profile.
62       * 
63       * @return String
64       */
65      public String getMissing()
66      {
67          return this.missing;
68      } //-- String getMissing() 
69  
70      /**
71       * Set the name of the file that should exist to activate a
72       * profile.
73       * 
74       * @param exists
75       */
76      public void setExists( String exists )
77      {
78          this.exists = exists;
79      } //-- void setExists( String ) 
80  
81      /**
82       * Set the name of the file that should be missing to activate
83       * a profile.
84       * 
85       * @param missing
86       */
87      public void setMissing( String missing )
88      {
89          this.missing = missing;
90      } //-- void setMissing( String ) 
91  
92  
93      private String modelEncoding = "UTF-8";
94  
95      /**
96       * Set an encoding used for reading/writing the model.
97       *
98       * @param modelEncoding the encoding used when reading/writing the model.
99       */
100     public void setModelEncoding( String modelEncoding )
101     {
102         this.modelEncoding = modelEncoding;
103     }
104 
105     /**
106      * @return the current encoding used when reading/writing this model.
107      */
108     public String getModelEncoding()
109     {
110         return modelEncoding;
111     }
112 }