1 /* 2 =================== DO NOT EDIT THIS FILE ==================== 3 Generated by Modello 1.4.1 on 2012-01-20 18:09:18, 4 any modifications will be overwritten. 5 ============================================================== 6 */ 7 8 package org.apache.maven.model; 9 10 /** 11 * Contains the information needed for deploying websites. 12 * 13 * @version $Revision$ $Date$ 14 */ 15 @SuppressWarnings( "all" ) 16 public class Site 17 implements java.io.Serializable, java.lang.Cloneable, org.apache.maven.model.InputLocationTracker 18 { 19 20 //--------------------------/ 21 //- Class/Member Variables -/ 22 //--------------------------/ 23 24 /** 25 * 26 * 27 * A unique identifier for a deployment location. 28 * This is used to match the 29 * site to configuration in the 30 * <code>settings.xml</code> file, for example. 31 * 32 * 33 */ 34 private String id; 35 36 /** 37 * Human readable name of the deployment location. 38 */ 39 private String name; 40 41 /** 42 * 43 * 44 * The url of the location where website is 45 * deployed, in the form <code>protocol://hostname/path</code>. 46 * 47 * 48 */ 49 private String url; 50 51 /** 52 * Field locations. 53 */ 54 private java.util.Map<Object, InputLocation> locations; 55 56 57 //-----------/ 58 //- Methods -/ 59 //-----------/ 60 61 /** 62 * Method clone. 63 * 64 * @return Site 65 */ 66 public Site clone() 67 { 68 try 69 { 70 Site copy = (Site) super.clone(); 71 72 if ( copy.locations != null ) 73 { 74 copy.locations = new java.util.LinkedHashMap( copy.locations ); 75 } 76 77 return copy; 78 } 79 catch ( java.lang.Exception ex ) 80 { 81 throw (java.lang.RuntimeException) new java.lang.UnsupportedOperationException( getClass().getName() 82 + " does not support clone()" ).initCause( ex ); 83 } 84 } //-- Site clone() 85 86 /** 87 * Get a unique identifier for a deployment location. This is 88 * used to match the 89 * site to configuration in the 90 * <code>settings.xml</code> file, for example. 91 * 92 * @return String 93 */ 94 public String getId() 95 { 96 return this.id; 97 } //-- String getId() 98 99 /** 100 * 101 * 102 * @param key 103 * @return InputLocation 104 */ 105 public InputLocation getLocation( Object key ) 106 { 107 return ( locations != null ) ? locations.get( key ) : null; 108 } //-- InputLocation getLocation( Object ) 109 110 /** 111 * Get human readable name of the deployment location. 112 * 113 * @return String 114 */ 115 public String getName() 116 { 117 return this.name; 118 } //-- String getName() 119 120 /** 121 * Get the url of the location where website is deployed, in 122 * the form <code>protocol://hostname/path</code>. 123 * 124 * @return String 125 */ 126 public String getUrl() 127 { 128 return this.url; 129 } //-- String getUrl() 130 131 /** 132 * Set a unique identifier for a deployment location. This is 133 * used to match the 134 * site to configuration in the 135 * <code>settings.xml</code> file, for example. 136 * 137 * @param id 138 */ 139 public void setId( String id ) 140 { 141 this.id = id; 142 } //-- void setId( String ) 143 144 /** 145 * 146 * 147 * @param key 148 * @param location 149 */ 150 public void setLocation( Object key, InputLocation location ) 151 { 152 if ( location != null ) 153 { 154 if ( this.locations == null ) 155 { 156 this.locations = new java.util.LinkedHashMap<Object, InputLocation>(); 157 } 158 this.locations.put( key, location ); 159 } 160 } //-- void setLocation( Object, InputLocation ) 161 162 /** 163 * Set human readable name of the deployment location. 164 * 165 * @param name 166 */ 167 public void setName( String name ) 168 { 169 this.name = name; 170 } //-- void setName( String ) 171 172 /** 173 * Set the url of the location where website is deployed, in 174 * the form <code>protocol://hostname/path</code>. 175 * 176 * @param url 177 */ 178 public void setUrl( String url ) 179 { 180 this.url = url; 181 } //-- void setUrl( String ) 182 183 }