/** * Copyright (c) 2010 Perforce Software. All rights reserved. */ package com.perforce.maven.scm.provider.p4.repository; import org.apache.maven.scm.provider.ScmProviderRepositoryWithHost; import org.codehaus.plexus.util.StringUtils; /** * This class will contain all SCM information about your SCM connection (user, password, host, port, path...). */ public class P4ScmProviderRepository extends ScmProviderRepositoryWithHost { /** The Constant P4_CHARSET_PROPERTY. */ public static final String P4_PORT_PROPERTY = "P4PORT"; /** The Constant P4_CHARSET_PROPERTY. */ public static final String P4_CHARSET_PROPERTY = "P4CHARSET"; /** The Constant P4_CLIENT_PROPERTY. */ public static final String P4_CLIENT_PROPERTY = "P4CLIENT"; /** The Constant P4_JOBS_PROPERTY. */ public static final String P4_JOBS_PROPERTY = "P4JOBS"; /** The Constant P4_VERBOSE_PROPERTY. */ public static final String P4_VERBOSE_PROPERTY = "P4VERBOSE"; private String protocol;// when empty perforce treats it as 'tcp' /** The path. */ private String path; private String p4Port; /** * Instantiates a new p4 scm provider repository. * * @param host the host * @param port the port * @param path the path * @param user the user * @param password the password */ public P4ScmProviderRepository( String protocol, String host, int port, String path, String user, String password ) { setProtocol( protocol ); setHost( host ); setPort( port ); setPath( path ); setUser( user ); setPassword( password ); p4Port = ""; if ( !StringUtils.isBlank( protocol ) ) { p4Port += protocol + ":"; } p4Port += getHost() + ":" + getPort(); } /** * Gets the path. * * @return the path */ public String getPath() { return path; } // expose this for branch command to use checkout command public void setPath( String path ) { if ( !path.startsWith( "//" ) ) { throw new IllegalArgumentException( "The depot path must be start with //" ); } this.path = path; } /** * Gets protocol type. * * @return protocol */ public String getProtocol() { return protocol; } private void setProtocol( String protocol ) { this.protocol = protocol; } public String getP4Port() { return p4Port; } }
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#2 | 19967 | jkovisto | Pull over numerous changes from @dantran's branch from change 16716. | ||
#1 | 10055 | Matt Attaway | Pull over numerous changes from @dantran's branch. | ||
//guest/perforce_software/p4maven/main/com.perforce.maven/src/main/java/com/perforce/maven/scm/provider/p4/repository/P4ScmProviderRepository.java | |||||
#2 | 9014 | Matt Attaway |
Add SSL support to P4Maven (committed on behalf of Dan Tran) USer visible change |
||
#1 | 8496 | Matt Attaway | Move P4Ant and P4Maven into their proper homes | ||
//public/perforce/p4maven/main/com.perforce.maven/src/main/java/com/perforce/maven/scm/provider/p4/repository/P4ScmProviderRepository.java | |||||
#1 | 8270 | Matt Attaway | Initial add of P4Maven source code |