001    /*
002     =================== DO NOT EDIT THIS FILE ====================
003     Generated by Modello 1.4.1 on 2013-02-24 03:32:14,
004     any modifications will be overwritten.
005     ==============================================================
006     */
007    
008    package org.apache.maven.model;
009    
010    /**
011     * Describes the prerequisites a project can have.
012     * 
013     * @version $Revision$ $Date$
014     */
015    @SuppressWarnings( "all" )
016    public class Prerequisites
017        implements java.io.Serializable, java.lang.Cloneable, org.apache.maven.model.InputLocationTracker
018    {
019    
020          //--------------------------/
021         //- Class/Member Variables -/
022        //--------------------------/
023    
024        /**
025         * The minimum version of Maven required to build the project,
026         * or to use this
027         *             plugin.
028         */
029        private String maven = "2.0";
030    
031        /**
032         * Field locations.
033         */
034        private java.util.Map<Object, InputLocation> locations;
035    
036    
037          //-----------/
038         //- Methods -/
039        //-----------/
040    
041        /**
042         * Method clone.
043         * 
044         * @return Prerequisites
045         */
046        public Prerequisites clone()
047        {
048            try
049            {
050                Prerequisites copy = (Prerequisites) super.clone();
051    
052                if ( copy.locations != null )
053                {
054                    copy.locations = new java.util.LinkedHashMap( copy.locations );
055                }
056    
057                return copy;
058            }
059            catch ( java.lang.Exception ex )
060            {
061                throw (java.lang.RuntimeException) new java.lang.UnsupportedOperationException( getClass().getName()
062                    + " does not support clone()" ).initCause( ex );
063            }
064        } //-- Prerequisites clone()
065    
066        /**
067         * 
068         * 
069         * @param key
070         * @return InputLocation
071         */
072        public InputLocation getLocation( Object key )
073        {
074            return ( locations != null ) ? locations.get( key ) : null;
075        } //-- InputLocation getLocation( Object )
076    
077        /**
078         * Get the minimum version of Maven required to build the
079         * project, or to use this
080         *             plugin.
081         * 
082         * @return String
083         */
084        public String getMaven()
085        {
086            return this.maven;
087        } //-- String getMaven()
088    
089        /**
090         * 
091         * 
092         * @param key
093         * @param location
094         */
095        public void setLocation( Object key, InputLocation location )
096        {
097            if ( location != null )
098            {
099                if ( this.locations == null )
100                {
101                    this.locations = new java.util.LinkedHashMap<Object, InputLocation>();
102                }
103                this.locations.put( key, location );
104            }
105        } //-- void setLocation( Object, InputLocation )
106    
107        /**
108         * Set the minimum version of Maven required to build the
109         * project, or to use this
110         *             plugin.
111         * 
112         * @param maven
113         */
114        public void setMaven( String maven )
115        {
116            this.maven = maven;
117        } //-- void setMaven( String )
118    
119    }