1 /* 2 Licensed to the Apache Software Foundation (ASF) under one 3 or more contributor license agreements. See the NOTICE file 4 distributed with this work for additional information 5 regarding copyright ownership. The ASF licenses this file 6 to you under the Apache License, Version 2.0 (the 7 "License"); you may not use this file except in compliance 8 with the License. You may obtain a copy of the License at 9 10 http://www.apache.org/licenses/LICENSE-2.0 11 12 Unless required by applicable law or agreed to in writing, 13 software distributed under the License is distributed on an 14 "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 KIND, either express or implied. See the License for the 16 specific language governing permissions and limitations 17 under the License. 18 =================== DO NOT EDIT THIS FILE ==================== 19 Generated by Modello 2.4.0, 20 any modifications will be overwritten. 21 ============================================================== 22 */ 23 24 package org.apache.maven.settings; 25 26 /** 27 * 28 * 29 * Repository contains the information needed 30 * for establishing connections with remote repository 31 * 32 * . 33 * 34 * @version $Revision$ $Date$ 35 */ 36 @SuppressWarnings( "all" ) 37 public class RepositoryBase 38 implements java.io.Serializable, java.lang.Cloneable 39 { 40 41 //--------------------------/ 42 //- Class/Member Variables -/ 43 //--------------------------/ 44 45 /** 46 * 47 * 48 * A unique identifier for a repository. 49 * 50 * 51 */ 52 private String id; 53 54 /** 55 * 56 * 57 * Human readable name of the repository. 58 * 59 * 60 */ 61 private String name; 62 63 /** 64 * 65 * 66 * The url of the repository. 67 * 68 * 69 */ 70 private String url; 71 72 /** 73 * 74 * The type of layout this repository uses for 75 * locating and 76 * storing artifacts - can be "legacy" or 77 * "default". 78 * 79 */ 80 private String layout = "default"; 81 82 83 //-----------/ 84 //- Methods -/ 85 //-----------/ 86 87 /** 88 * Method clone. 89 * 90 * @return RepositoryBase 91 */ 92 public RepositoryBase clone() 93 { 94 try 95 { 96 RepositoryBase copy = (RepositoryBase) super.clone(); 97 98 return copy; 99 } 100 catch ( java.lang.Exception ex ) 101 { 102 throw (java.lang.RuntimeException) new java.lang.UnsupportedOperationException( getClass().getName() 103 + " does not support clone()" ).initCause( ex ); 104 } 105 } //-- RepositoryBase clone() 106 107 /** 108 * Get a unique identifier for a repository. 109 * 110 * @return String 111 */ 112 public String getId() 113 { 114 return this.id; 115 } //-- String getId() 116 117 /** 118 * Get the type of layout this repository uses for locating and 119 * storing artifacts - can be "legacy" or 120 * "default". 121 * 122 * @return String 123 */ 124 public String getLayout() 125 { 126 return this.layout; 127 } //-- String getLayout() 128 129 /** 130 * Get human readable name of the repository. 131 * 132 * @return String 133 */ 134 public String getName() 135 { 136 return this.name; 137 } //-- String getName() 138 139 /** 140 * Get the url of the repository. 141 * 142 * @return String 143 */ 144 public String getUrl() 145 { 146 return this.url; 147 } //-- String getUrl() 148 149 /** 150 * Set a unique identifier for a repository. 151 * 152 * @param id a id object. 153 */ 154 public void setId( String id ) 155 { 156 this.id = id; 157 } //-- void setId( String ) 158 159 /** 160 * Set the type of layout this repository uses for locating and 161 * storing artifacts - can be "legacy" or 162 * "default". 163 * 164 * @param layout a layout object. 165 */ 166 public void setLayout( String layout ) 167 { 168 this.layout = layout; 169 } //-- void setLayout( String ) 170 171 /** 172 * Set human readable name of the repository. 173 * 174 * @param name a name object. 175 */ 176 public void setName( String name ) 177 { 178 this.name = name; 179 } //-- void setName( String ) 180 181 /** 182 * Set the url of the repository. 183 * 184 * @param url a url object. 185 */ 186 public void setUrl( String url ) 187 { 188 this.url = url; 189 } //-- void setUrl( String ) 190 191 192 193 /** 194 * @see java.lang.Object#equals(java.lang.Object) 195 */ 196 public boolean equals( Object obj ) 197 { 198 RepositoryBase other = (RepositoryBase) obj; 199 200 boolean retValue = false; 201 202 if ( id != null ) 203 { 204 retValue = id.equals( other.id ); 205 } 206 207 return retValue; 208 } 209 210 211 }