com.pmease.quickbuild.repository
Class P4ClientSpec

java.lang.Object
  extended byP4Base
      extended bycom.pmease.quickbuild.repository.P4ClientSpec

public class P4ClientSpec
extends P4Base

P4ClientSpec manages Perforce client specification. It supports both client spec read and write. It is loosely based on original P4Client class from Apache Ant distribution, which doesn't seem to be supported any more (in Ant 1.6.2). It uses Ant optional perforce classes.

Author:
Lubos Pochman
Referenced classes of package org.apache.tools.ant.taskdefs.optional.perforce: P4Base, P4Handler, P4HandlerAdapter
See Also:
Serialized Form

Field Summary
protected  java.lang.String clientValue
           
protected  java.util.ArrayList descValue
           
protected  java.lang.String hostValue
           
protected  java.lang.String lineEndValue
           
protected  java.lang.String optionsValue
           
protected  java.lang.String ownerValue
           
protected  java.lang.String rootValue
           
protected  java.util.ArrayList viewValue
           
 
Constructor Summary
P4ClientSpec()
           
 
Method Summary
 void addDescValue(java.lang.String desc)
          Adds client spec description line
 void addViewValue(java.lang.String view)
          Adds a line to the client spec view value.
 java.lang.String getClientValue()
          Returns client spec name.
 java.lang.String getDescValue()
          Returns client spec description is String form (lines separated by \n\t)
 java.lang.String getHostValue()
          Returns client spec host.
 java.lang.String getLineEndValue()
          Returns client spec LineEnd.
 java.lang.String getOptionsValue()
          Returns client spec options.
 java.lang.String getOwnerValue()
          Returns client spec owner.
 java.lang.String getRootValue()
          Returns client spec root directory.
 java.lang.String getViewValue()
          Returns client spec view value as a String (lines separated by \t\n)
 void read()
          Reads perforce client specification defined by set clientValue and populates object data.
 void setClientValue(java.lang.String clientValue)
          Sets client spec name.
 void setDescValue(java.util.ArrayList desc)
          Sets client spec description.
 void setHostValue(java.lang.String hostValue)
          Sets client spec host.
 void setLineEndValue(java.lang.String lineEndValue)
          Sets client spec LineEnd.
 void setOptionsValue(java.lang.String optionsValue)
          Sets client spec options.
 void setOwnerValue(java.lang.String ownerValue)
          Sets client spec owner.
 void setRootValue(java.lang.String rootValue)
          Sets client spec root directory.
 void setViewValue(java.util.ArrayList viewValue)
          Sets client spec view value.
 void write()
          Writes currently defined client specification into perforce.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

clientValue

protected java.lang.String clientValue

ownerValue

protected java.lang.String ownerValue

hostValue

protected java.lang.String hostValue

rootValue

protected java.lang.String rootValue

optionsValue

protected java.lang.String optionsValue

lineEndValue

protected java.lang.String lineEndValue

viewValue

protected java.util.ArrayList viewValue

descValue

protected java.util.ArrayList descValue
Constructor Detail

P4ClientSpec

public P4ClientSpec()
Method Detail

getClientValue

public java.lang.String getClientValue()
Returns client spec name.

Returns:
client spec name

setClientValue

public void setClientValue(java.lang.String clientValue)
Sets client spec name.

Parameters:
clientValue - client spec name

getOwnerValue

public java.lang.String getOwnerValue()
Returns client spec owner.

Returns:
client spec owner

setOwnerValue

public void setOwnerValue(java.lang.String ownerValue)
Sets client spec owner.

Parameters:
ownerValue - client spec owner

getHostValue

public java.lang.String getHostValue()
Returns client spec host.

Returns:
client spec host

setHostValue

public void setHostValue(java.lang.String hostValue)
Sets client spec host.

Parameters:
hostValue - client spec host

getDescValue

public java.lang.String getDescValue()
Returns client spec description is String form (lines separated by \n\t)

Returns:
client spec description

addDescValue

public void addDescValue(java.lang.String desc)
Adds client spec description line

Parameters:
desc - client spec description line

setDescValue

public void setDescValue(java.util.ArrayList desc)
Sets client spec description.

Parameters:
desc - client spec description

getRootValue

public java.lang.String getRootValue()
Returns client spec root directory.

Returns:
client spec root directory

setRootValue

public void setRootValue(java.lang.String rootValue)
Sets client spec root directory.

Parameters:
rootValue - client spec root directory

getOptionsValue

public java.lang.String getOptionsValue()
Returns client spec options.

Returns:
client spec options

setOptionsValue

public void setOptionsValue(java.lang.String optionsValue)
Sets client spec options.

Parameters:
optionsValue - client spec options

getLineEndValue

public java.lang.String getLineEndValue()
Returns client spec LineEnd.

Returns:
client spec LineEnd

setLineEndValue

public void setLineEndValue(java.lang.String lineEndValue)
Sets client spec LineEnd.

Parameters:
lineEndValue - client spec LineEnd

getViewValue

public java.lang.String getViewValue()
Returns client spec view value as a String (lines separated by \t\n)

Returns:
client spec view value

addViewValue

public void addViewValue(java.lang.String view)
Adds a line to the client spec view value.

Parameters:
view - line to be added to the client spec view value

setViewValue

public void setViewValue(java.util.ArrayList viewValue)
Sets client spec view value.

Parameters:
viewValue - client spec view value

read

public void read()
          throws org.apache.tools.ant.BuildException
Reads perforce client specification defined by set clientValue and populates object data.

Throws:
org.apache.tools.ant.BuildException - (non-Javadoc)
See Also:
Task.execute()

write

public void write()
           throws org.apache.tools.ant.BuildException
Writes currently defined client specification into perforce.

Throws:
org.apache.tools.ant.BuildException - (non-Javadoc)
See Also:
Task.execute()


Copyright © 2005 PMEase Inc. All Rights Reserved.