/** * Copyright (c) 2010 Perforce Software. All rights reserved. */ package com.perforce.maven.scm.provider.p4.command.add; import java.util.ArrayList; import java.util.List; import org.apache.maven.scm.ScmFile; import org.apache.maven.scm.ScmFileStatus; import com.perforce.maven.scm.provider.p4.command.P4Result; import com.perforce.p4java.core.file.IFileSpec; /** * This class handles the result from the Perforce add command. */ public class P4AddResult extends P4Result { /** The additions. */ private List<ScmFile> additions = new ArrayList<ScmFile>(); /** * @see com.perforce.maven.scm.provider.p4.command.P4Result#processMessage (java.lang.String) */ @Override public String processMessage( String message ) { return null; } /** * Extracts the file paths from the add command result filespecs. * * @param fileSpecs the file specs */ public void processAdditions( List<IFileSpec> fileSpecs ) { if ( fileSpecs != null ) { for ( IFileSpec fileSpec : fileSpecs ) { if ( fileSpec != null ) { if ( fileSpec.getDepotPath() != null ) { additions.add( new ScmFile( fileSpec.getDepotPath().getPathString(), ScmFileStatus.ADDED ) ); } } } } } /** * Gets the additions. * * @return the additions */ public List<ScmFile> getAdditions() { return additions; } }
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#2 | 9533 | dantran | source format | ||
#1 | 9519 | dantran | folder rename to match with its artifactId | ||
//guest/dantran/p4maven/com.perforce.maven/src/main/java/com/perforce/maven/scm/provider/p4/command/add/P4AddResult.java | |||||
#2 | 9177 | dantran |
Compatible with maven-scm-api-1.5+. The current 1.4 is too old |
||
#1 | 9167 | dantran |
Populate //guest/dantran/p4maven/... from //guest/perforce_software/p4maven/main/.... |
||
//guest/perforce_software/p4maven/main/com.perforce.maven/src/main/java/com/perforce/maven/scm/provider/p4/command/add/P4AddResult.java | |||||
#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/command/add/P4AddResult.java | |||||
#1 | 8270 | Matt Attaway | Initial add of P4Maven source code |