1 package org.apache.maven.artifact.repository; 2 3 /* 4 * Licensed to the Apache Software Foundation (ASF) under one 5 * or more contributor license agreements. See the NOTICE file 6 * distributed with this work for additional information 7 * regarding copyright ownership. The ASF licenses this file 8 * to you under the Apache License, Version 2.0 (the 9 * "License"); you may not use this file except in compliance 10 * with the License. You may obtain a copy of the License at 11 * 12 * http://www.apache.org/licenses/LICENSE-2.0 13 * 14 * Unless required by applicable law or agreed to in writing, 15 * software distributed under the License is distributed on an 16 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 17 * KIND, either express or implied. See the License for the 18 * specific language governing permissions and limitations 19 * under the License. 20 */ 21 22 public class Authentication 23 { 24 public Authentication( String userName, String password ) 25 { 26 this.username = userName; 27 this.password = password; 28 } 29 30 /** 31 * Username used to login to the host 32 */ 33 private String username; 34 35 /** 36 * Password associated with the login 37 */ 38 private String password; 39 40 /** 41 * Get the user's password which is used when connecting to the repository. 42 * 43 * @return password of user 44 */ 45 public String getPassword() 46 { 47 return password; 48 } 49 50 /** 51 * Set the user's password which is used when connecting to the repository. 52 * 53 * @param password password of the user 54 */ 55 public void setPassword( String password ) 56 { 57 this.password = password; 58 } 59 60 /** 61 * Get the username used to access the repository. 62 * 63 * @return username at repository 64 */ 65 public String getUsername() 66 { 67 return username; 68 } 69 70 /** 71 * Set username used to access the repository. 72 * 73 * @param userName the username used to access repository 74 */ 75 public void setUsername( final String userName ) 76 { 77 this.username = userName; 78 } 79 }