de.matthias_burbach.mosaique.core.util
Class P4

java.lang.Object
  extended byde.matthias_burbach.mosaique.core.util.P4

public class P4
extends java.lang.Object

Is a simple interface to the SCM tool Perforce (short: P4).

Author:
Matthias Burbach

Constructor Summary
P4()
           
 
Method Summary
 int getSynchedRevision(java.lang.String file)
           
 boolean isP4Controlled(java.lang.String file)
           
 boolean isP4Installed()
           
 boolean openForEdit(java.lang.String file)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

P4

public P4()
Method Detail

isP4Installed

public boolean isP4Installed()
Returns:
true if the Perforce command line can be accessed by this class.

isP4Controlled

public boolean isP4Controlled(java.lang.String file)
Parameters:
file - The file to check.
Returns:
true if the file is under Perforce control (also if only opened for add yet).

getSynchedRevision

public int getSynchedRevision(java.lang.String file)
Parameters:
file - The file to get the synched revision for.
Returns:
The revision of the file that is currently synched on the client. Returns -1 if no revision is synched or if Perforce access failed.

openForEdit

public boolean openForEdit(java.lang.String file)
Parameters:
file - The file to check.
Returns:
true if the file is now opened for edit.


Copyright © 2005-2006 . All Rights Reserved.