org.apache.tools.ant.taskdefs.optional.perforce

Class P4Integrate


public class P4Integrate
extends P4Base

Integrate file(s). P4Change should be used to obtain a new changelist for P4Integrate, although P4Integrate can open files to the default change, P4Submit cannot yet submit to it. Example Usage:
<p4integrate change="${p4.change}" fromfile="//depot/project/dev/foo.txt" tofile="//depot/project/main/foo.txt" />

Field Summary

Fields inherited from class org.apache.tools.ant.taskdefs.optional.perforce.P4Base

P4Client, P4CmdOpts, P4Opts, P4Port, P4User, P4View, failOnError, shell, util

Fields inherited from class org.apache.tools.ant.Task

description, location, target, taskName, taskType, wrapper

Fields inherited from class org.apache.tools.ant.ProjectComponent

project

Method Summary

void
execute()
execute the p4 integrate
String
getBranch()
get the branch
String
getChange()
get the changelist number
String
getFromfile()
get the from file specification
String
getTofile()
get the to file specification
boolean
isEnableBaselessMerges()
gets the enablebaselessmerges flag
boolean
isForceIntegrate()
gets the forceintegrate flag
boolean
isLeaveTargetRevision()
gets the leavetargetrevision flag
boolean
isNocopynewtargetfiles()
indicates intention to suppress the copying on the local hard disk of new target files.
boolean
isPropagatesourcefiletype()
returns flag indicating if propagation of source file type is sought
boolean
isRestoreDeletedRevisions()
gets the restoredeletedrevisions flag
boolean
isReversebranchmappings()
returns the flag indicating if reverse branch mappings are sought
boolean
isSimulationMode()
gets the simulationmode flag
void
setBranch(String br)
sets the branch
void
setChange(String change)
set the changelist number for the operation
void
setEnableBaselessMerges(boolean setrest)
sets the enablebaselessmerges flag
void
setForceIntegrate(boolean setrest)
sets the forceintegrate flag
void
setFromfile(String fromf)
sets the from file specification
void
setLeaveTargetRevision(boolean setrest)
sets the leavetargetrevision flag
void
setNocopynewtargetfiles(boolean nocopynewtargetfiles)
sets nocopynewtargetfiles flag
void
setPropagatesourcefiletype(boolean propagatesourcefiletype)
sets flag indicating if one wants to propagate the source file type
void
setRestoreDeletedRevisions(boolean setrest)
sets the restoredeletedrevisions flag
void
setReversebranchmappings(boolean reversebranchmappings)
sets the reversebranchmappings flag
void
setSimulationMode(boolean setrest)
sets the simulationmode flag
void
setTofile(String tof)
sets the to file specification

Methods inherited from class org.apache.tools.ant.taskdefs.optional.perforce.P4Base

execP4Command, execP4Command, getErrorMessage, getInError, init, setClient, setCmdopts, setErrorMessage, setFailonerror, setGlobalopts, setInError, setPort, setUser, setView

Methods inherited from class org.apache.tools.ant.Task

execute, getDescription, getLocation, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, maybeConfigure, perform, reconfigure, setDescription, setLocation, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType

Methods inherited from class org.apache.tools.ant.ProjectComponent

getProject, log, log, setProject

Method Details

execute

public void execute()
            throws BuildException
execute the p4 integrate
Overrides:
execute in interface Task
Throws:
BuildException - if there are missing parameters

getBranch

public String getBranch()
get the branch
Returns:
the name of the branch

getChange

public String getChange()
get the changelist number
Returns:
the changelist number set for this task

getFromfile

public String getFromfile()
get the from file specification
Returns:
the from file specification

getTofile

public String getTofile()
get the to file specification
Returns:
the to file specification

isEnableBaselessMerges

public boolean isEnableBaselessMerges()
gets the enablebaselessmerges flag
Returns:
boolean indicating if baseless merges are desired

isForceIntegrate

public boolean isForceIntegrate()
gets the forceintegrate flag
Returns:
restore deleted revisions

isLeaveTargetRevision

public boolean isLeaveTargetRevision()
gets the leavetargetrevision flag
Returns:
flag indicating if the target revision should be preserved

isNocopynewtargetfiles

public boolean isNocopynewtargetfiles()
indicates intention to suppress the copying on the local hard disk of new target files.
Returns:
indicates intention to suppress the copying on the local hard disk of new target files.

isPropagatesourcefiletype

public boolean isPropagatesourcefiletype()
returns flag indicating if propagation of source file type is sought
Returns:
flag set to true if you want to propagate source file type for existing target files

isRestoreDeletedRevisions

public boolean isRestoreDeletedRevisions()
gets the restoredeletedrevisions flag
Returns:
restore deleted revisions

isReversebranchmappings

public boolean isReversebranchmappings()
returns the flag indicating if reverse branch mappings are sought
Returns:
reversebranchmappings flag

isSimulationMode

public boolean isSimulationMode()
gets the simulationmode flag
Returns:
simulation mode flag

setBranch

public void setBranch(String br)
sets the branch
Parameters:
br - the name of the branch to use

setChange

public void setChange(String change)
set the changelist number for the operation
Parameters:
change - An existing changelist number to assign files to; optional but strongly recommended.

setEnableBaselessMerges

public void setEnableBaselessMerges(boolean setrest)
sets the enablebaselessmerges flag
Parameters:
setrest - value chosen for enablebaselessmerges

setForceIntegrate

public void setForceIntegrate(boolean setrest)
sets the forceintegrate flag
Parameters:
setrest - value chosen for forceintegrate

setFromfile

public void setFromfile(String fromf)
sets the from file specification
Parameters:
fromf - the from file specification

setLeaveTargetRevision

public void setLeaveTargetRevision(boolean setrest)
sets the leavetargetrevision flag
Parameters:
setrest - value chosen for leavetargetrevision

setNocopynewtargetfiles

public void setNocopynewtargetfiles(boolean nocopynewtargetfiles)
sets nocopynewtargetfiles flag
Parameters:
nocopynewtargetfiles - set it to true to gain speed in integration by not copying on the local Perforce client new target files

setPropagatesourcefiletype

public void setPropagatesourcefiletype(boolean propagatesourcefiletype)
sets flag indicating if one wants to propagate the source file type
Parameters:
propagatesourcefiletype - set it to true if you want to change the type of existing target files according to type of source file.

setRestoreDeletedRevisions

public void setRestoreDeletedRevisions(boolean setrest)
sets the restoredeletedrevisions flag
Parameters:
setrest - value chosen for restoredeletedrevisions

setReversebranchmappings

public void setReversebranchmappings(boolean reversebranchmappings)
sets the reversebranchmappings flag
Parameters:
reversebranchmappings - flag indicating if reverse branch mappings are sought

setSimulationMode

public void setSimulationMode(boolean setrest)
sets the simulationmode flag
Parameters:
setrest - value chosen for simulationmode

setTofile

public void setTofile(String tof)
sets the to file specification
Parameters:
tof - the to file specification

Copyright B) 2000-2007 Apache Software Foundation. All Rights Reserved.