001    // =================== DO NOT EDIT THIS FILE ====================
002    // Generated by Modello 1.7,
003    // any modifications will be overwritten.
004    // ==============================================================
005    
006    package org.apache.maven.model;
007    
008    /**
009     * This is an activator which will detect an operating system's
010     * attributes in order
011     *         to activate its profile.
012     * 
013     * @version $Revision$ $Date$
014     */
015    @SuppressWarnings( "all" )
016    public class ActivationOS
017        implements java.io.Serializable, java.lang.Cloneable, org.apache.maven.model.InputLocationTracker
018    {
019    
020          //--------------------------/
021         //- Class/Member Variables -/
022        //--------------------------/
023    
024        /**
025         * 
026         *             
027         *             The name of the operating system to be used to
028         * activate the profile. This must be an exact match
029         *             of the <code>${os.name}</code> Java property,
030         * such as <code>Windows XP</code>.
031         *             
032         *           
033         */
034        private String name;
035    
036        /**
037         * 
038         *             
039         *             The general family of the OS to be used to
040         * activate the profile, such as
041         *             <code>windows</code> or <code>unix</code>.
042         *             
043         *           
044         */
045        private String family;
046    
047        /**
048         * The architecture of the operating system to be used to
049         * activate the
050         *           profile.
051         */
052        private String arch;
053    
054        /**
055         * The version of the operating system to be used to activate
056         * the
057         *           profile.
058         */
059        private String version;
060    
061        /**
062         * Field locations.
063         */
064        private java.util.Map<Object, InputLocation> locations;
065    
066    
067          //-----------/
068         //- Methods -/
069        //-----------/
070    
071        /**
072         * Method clone.
073         * 
074         * @return ActivationOS
075         */
076        public ActivationOS clone()
077        {
078            try
079            {
080                ActivationOS copy = (ActivationOS) super.clone();
081    
082                if ( copy.locations != null )
083                {
084                    copy.locations = new java.util.LinkedHashMap( copy.locations );
085                }
086    
087                return copy;
088            }
089            catch ( java.lang.Exception ex )
090            {
091                throw (java.lang.RuntimeException) new java.lang.UnsupportedOperationException( getClass().getName()
092                    + " does not support clone()" ).initCause( ex );
093            }
094        } //-- ActivationOS clone()
095    
096        /**
097         * Get the architecture of the operating system to be used to
098         * activate the
099         *           profile.
100         * 
101         * @return String
102         */
103        public String getArch()
104        {
105            return this.arch;
106        } //-- String getArch()
107    
108        /**
109         * Get the general family of the OS to be used to activate the
110         * profile, such as
111         *             <code>windows</code> or <code>unix</code>.
112         * 
113         * @return String
114         */
115        public String getFamily()
116        {
117            return this.family;
118        } //-- String getFamily()
119    
120        /**
121         * 
122         * 
123         * @param key
124         * @return InputLocation
125         */
126        public InputLocation getLocation( Object key )
127        {
128            return ( locations != null ) ? locations.get( key ) : null;
129        } //-- InputLocation getLocation( Object )
130    
131        /**
132         * Get the name of the operating system to be used to activate
133         * the profile. This must be an exact match
134         *             of the <code>${os.name}</code> Java property,
135         * such as <code>Windows XP</code>.
136         * 
137         * @return String
138         */
139        public String getName()
140        {
141            return this.name;
142        } //-- String getName()
143    
144        /**
145         * Get the version of the operating system to be used to
146         * activate the
147         *           profile.
148         * 
149         * @return String
150         */
151        public String getVersion()
152        {
153            return this.version;
154        } //-- String getVersion()
155    
156        /**
157         * Set the architecture of the operating system to be used to
158         * activate the
159         *           profile.
160         * 
161         * @param arch
162         */
163        public void setArch( String arch )
164        {
165            this.arch = arch;
166        } //-- void setArch( String )
167    
168        /**
169         * Set the general family of the OS to be used to activate the
170         * profile, such as
171         *             <code>windows</code> or <code>unix</code>.
172         * 
173         * @param family
174         */
175        public void setFamily( String family )
176        {
177            this.family = family;
178        } //-- void setFamily( String )
179    
180        /**
181         * 
182         * 
183         * @param key
184         * @param location
185         */
186        public void setLocation( Object key, InputLocation location )
187        {
188            if ( location != null )
189            {
190                if ( this.locations == null )
191                {
192                    this.locations = new java.util.LinkedHashMap<Object, InputLocation>();
193                }
194                this.locations.put( key, location );
195            }
196        } //-- void setLocation( Object, InputLocation )
197    
198        /**
199         * Set the name of the operating system to be used to activate
200         * the profile. This must be an exact match
201         *             of the <code>${os.name}</code> Java property,
202         * such as <code>Windows XP</code>.
203         * 
204         * @param name
205         */
206        public void setName( String name )
207        {
208            this.name = name;
209        } //-- void setName( String )
210    
211        /**
212         * Set the version of the operating system to be used to
213         * activate the
214         *           profile.
215         * 
216         * @param version
217         */
218        public void setVersion( String version )
219        {
220            this.version = version;
221        } //-- void setVersion( String )
222    
223    }