View Javadoc
1   // =================== DO NOT EDIT THIS FILE ====================
2   // Generated by Modello 1.9.1,
3   // any modifications will be overwritten.
4   // ==============================================================
5   
6   package org.apache.maven.model;
7   
8   /**
9    * 
10   *         
11   *         The <code>&lt;scm&gt;</code> element contains
12   * informations required to the SCM
13   *         (Source Control Management) of the project.
14   *         
15   *       
16   * 
17   * @version $Revision: 1008624 $ $Date: 2017-03-19 14:17:57 +0000 (Sun, 19 Mar 2017) $
18   */
19  @SuppressWarnings( "all" )
20  public class Scm
21      implements java.io.Serializable, java.lang.Cloneable, org.apache.maven.model.InputLocationTracker
22  {
23  
24        //--------------------------/
25       //- Class/Member Variables -/
26      //--------------------------/
27  
28      /**
29       * 
30       *             
31       *             The source control management system URL
32       *             that describes the repository and how to connect
33       * to the
34       *             repository. For more information, see the
35       *             <a
36       * href="https://maven.apache.org/scm/scm-url-format.html">URL
37       * format</a>
38       *             and <a
39       * href="https://maven.apache.org/scm/scms-overview.html">list
40       * of supported SCMs</a>.
41       *             This connection is read-only.
42       *             <br><b>Default value is</b>: parent value [+
43       * path adjustment] + (artifactId or
44       * <code>project.directory</code> property) 
45       *             
46       *           .
47       */
48      private String connection;
49  
50      /**
51       * 
52       *             
53       *             Just like <code>connection</code>, but for
54       * developers, i.e. this scm connection
55       *             will not be read only.
56       *             <br><b>Default value is</b>: parent value [+
57       * path adjustment] + (artifactId or
58       * <code>project.directory</code> property)
59       *             
60       *           .
61       */
62      private String developerConnection;
63  
64      /**
65       * The tag of current code. By default, it's set to HEAD during
66       * development.
67       */
68      private String tag = "HEAD";
69  
70      /**
71       * 
72       *             
73       *             The URL to the project's browsable SCM
74       * repository, such as ViewVC or Fisheye.
75       *             <br><b>Default value is</b>: parent value [+
76       * path adjustment] + (artifactId or
77       * <code>project.directory</code> property)
78       *             
79       *           .
80       */
81      private String url;
82  
83      /**
84       * Field locations.
85       */
86      private java.util.Map<Object, InputLocation> locations;
87  
88  
89        //-----------/
90       //- Methods -/
91      //-----------/
92  
93      /**
94       * Method clone.
95       * 
96       * @return Scm
97       */
98      public Scm clone()
99      {
100         try
101         {
102             Scm copy = (Scm) super.clone();
103 
104             if ( copy.locations != null )
105             {
106                 copy.locations = new java.util.LinkedHashMap( copy.locations );
107             }
108 
109             return copy;
110         }
111         catch ( java.lang.Exception ex )
112         {
113             throw (java.lang.RuntimeException) new java.lang.UnsupportedOperationException( getClass().getName()
114                 + " does not support clone()" ).initCause( ex );
115         }
116     } //-- Scm clone()
117 
118     /**
119      * Get the source control management system URL
120      *             that describes the repository and how to connect
121      * to the
122      *             repository. For more information, see the
123      *             <a
124      * href="https://maven.apache.org/scm/scm-url-format.html">URL
125      * format</a>
126      *             and <a
127      * href="https://maven.apache.org/scm/scms-overview.html">list
128      * of supported SCMs</a>.
129      *             This connection is read-only.
130      *             <br><b>Default value is</b>: parent value [+
131      * path adjustment] + (artifactId or
132      * <code>project.directory</code> property).
133      * 
134      * @return String
135      */
136     public String getConnection()
137     {
138         return this.connection;
139     } //-- String getConnection()
140 
141     /**
142      * Get just like <code>connection</code>, but for developers,
143      * i.e. this scm connection
144      *             will not be read only.
145      *             <br><b>Default value is</b>: parent value [+
146      * path adjustment] + (artifactId or
147      * <code>project.directory</code> property).
148      * 
149      * @return String
150      */
151     public String getDeveloperConnection()
152     {
153         return this.developerConnection;
154     } //-- String getDeveloperConnection()
155 
156     /**
157      * 
158      * 
159      * @param key
160      * @return InputLocation
161      */
162     public InputLocation getLocation( Object key )
163     {
164         return ( locations != null ) ? locations.get( key ) : null;
165     } //-- InputLocation getLocation( Object )
166 
167     /**
168      * Get the tag of current code. By default, it's set to HEAD
169      * during development.
170      * 
171      * @return String
172      */
173     public String getTag()
174     {
175         return this.tag;
176     } //-- String getTag()
177 
178     /**
179      * Get the URL to the project's browsable SCM repository, such
180      * as ViewVC or Fisheye.
181      *             <br><b>Default value is</b>: parent value [+
182      * path adjustment] + (artifactId or
183      * <code>project.directory</code> property).
184      * 
185      * @return String
186      */
187     public String getUrl()
188     {
189         return this.url;
190     } //-- String getUrl()
191 
192     /**
193      * Set the source control management system URL
194      *             that describes the repository and how to connect
195      * to the
196      *             repository. For more information, see the
197      *             <a
198      * href="https://maven.apache.org/scm/scm-url-format.html">URL
199      * format</a>
200      *             and <a
201      * href="https://maven.apache.org/scm/scms-overview.html">list
202      * of supported SCMs</a>.
203      *             This connection is read-only.
204      *             <br><b>Default value is</b>: parent value [+
205      * path adjustment] + (artifactId or
206      * <code>project.directory</code> property).
207      * 
208      * @param connection
209      */
210     public void setConnection( String connection )
211     {
212         this.connection = connection;
213     } //-- void setConnection( String )
214 
215     /**
216      * Set just like <code>connection</code>, but for developers,
217      * i.e. this scm connection
218      *             will not be read only.
219      *             <br><b>Default value is</b>: parent value [+
220      * path adjustment] + (artifactId or
221      * <code>project.directory</code> property).
222      * 
223      * @param developerConnection
224      */
225     public void setDeveloperConnection( String developerConnection )
226     {
227         this.developerConnection = developerConnection;
228     } //-- void setDeveloperConnection( String )
229 
230     /**
231      * 
232      * 
233      * @param key
234      * @param location
235      */
236     public void setLocation( Object key, InputLocation location )
237     {
238         if ( location != null )
239         {
240             if ( this.locations == null )
241             {
242                 this.locations = new java.util.LinkedHashMap<Object, InputLocation>();
243             }
244             this.locations.put( key, location );
245         }
246     } //-- void setLocation( Object, InputLocation )
247 
248     /**
249      * Set the tag of current code. By default, it's set to HEAD
250      * during development.
251      * 
252      * @param tag
253      */
254     public void setTag( String tag )
255     {
256         this.tag = tag;
257     } //-- void setTag( String )
258 
259     /**
260      * Set the URL to the project's browsable SCM repository, such
261      * as ViewVC or Fisheye.
262      *             <br><b>Default value is</b>: parent value [+
263      * path adjustment] + (artifactId or
264      * <code>project.directory</code> property).
265      * 
266      * @param url
267      */
268     public void setUrl( String url )
269     {
270         this.url = url;
271     } //-- void setUrl( String )
272 
273 }