C# Class Perforce.P4Shell

Mostrar archivo Open project: jurney/P4Backup

Public Methods

Method Description
ActionToString ( System.Action action ) : string
Add ( string filePath, int changelistID ) : bool
CreateChangelist ( string description, int &changelistID ) : bool

Creates a new changelist with the given description.

Delete ( string filePath, int changelistID ) : bool
EasyDelete ( string filePath, int changelistID ) : void
EasyEdit ( List fileStats, int changelistID, bool reopenDeleted ) : void

This utility method will attempt whatever is necessary to get the given file path into an editable state as far as Perforce is concerned.

EasyEdit ( string filePaths, int changelistID, bool reopenDeleted ) : void

This utility method will attempt whatever is necessary to get the given file path into an editable state as far as Perforce is concerned.

Edit ( string filePath, int changelistID ) : bool
FindChangelist ( string descriptionStartsWith ) : List

Finds a list of changelists whose first 31 characters of the description match the given description, case insensitive.

GetChangelist ( int changelistID ) : Changelist
GetClientSpec ( string client, ClientSpec &clientSpec ) : bool
GetClientSpecs ( ) : List
GetClients ( ) : List
GetFileStats ( string filePath ) : List
GetOpenedFileStats ( int optionalChangelist ) : List
GetOpenedFiles ( int optionalChangelist ) : List
GetPendingChangelists ( ) : List
Initialize ( ) : void

Initialize P4Shell with the current system defaults.

Integrate ( string fromFile, string toFile, System.Operation operation ) : bool
IsHeadRevisionDelete ( FileStats fileStat ) : bool
IsHeadRevisionDelete ( string filePath, int changelistID ) : bool
PingServer ( ) : bool

Ping's the Perforce server using the current P4Shell settings.

Reopen ( string filePath, int newChangelistID ) : bool
Revert ( string filePath ) : bool
SetFileReadOnly ( string filePath ) : void
SetFileWritable ( string filePath ) : void
SetFilesReadOnly ( List files ) : void
SetFilesWriteable ( List files ) : void
StringToAction ( string actionName ) : System.Action
Submit ( int changelistID, string description ) : bool

Submits the given changelist, and updates it's description if provided. Note that when submitting the default changelist, you must always provide a description.

Sync ( string filePath ) : bool

Private Methods

Method Description
Execute ( string arguments, string input ) : void

Method Details

ActionToString() public static method

public static ActionToString ( System.Action action ) : string
action System.Action
return string

Add() public static method

public static Add ( string filePath, int changelistID ) : bool
filePath string
changelistID int
return bool

CreateChangelist() public static method

Creates a new changelist with the given description.
public static CreateChangelist ( string description, int &changelistID ) : bool
description string The description of the changelist.
changelistID int
return bool

Delete() public static method

public static Delete ( string filePath, int changelistID ) : bool
filePath string
changelistID int
return bool

EasyDelete() public static method

public static EasyDelete ( string filePath, int changelistID ) : void
filePath string
changelistID int
return void

EasyEdit() public static method

This utility method will attempt whatever is necessary to get the given file path into an editable state as far as Perforce is concerned.
public static EasyEdit ( List fileStats, int changelistID, bool reopenDeleted ) : void
fileStats List
changelistID int
reopenDeleted bool
return void

EasyEdit() public static method

This utility method will attempt whatever is necessary to get the given file path into an editable state as far as Perforce is concerned.
public static EasyEdit ( string filePaths, int changelistID, bool reopenDeleted ) : void
filePaths string
changelistID int The changelist ID to use if it is necessary to open the file.
reopenDeleted bool
return void

Edit() public static method

public static Edit ( string filePath, int changelistID ) : bool
filePath string
changelistID int
return bool

FindChangelist() public static method

Finds a list of changelists whose first 31 characters of the description match the given description, case insensitive.
public static FindChangelist ( string descriptionStartsWith ) : List
descriptionStartsWith string The given description.
return List

GetChangelist() public static method

public static GetChangelist ( int changelistID ) : Changelist
changelistID int
return Changelist

GetClientSpec() public static method

public static GetClientSpec ( string client, ClientSpec &clientSpec ) : bool
client string
clientSpec ClientSpec
return bool

GetClientSpecs() public static method

public static GetClientSpecs ( ) : List
return List

GetClients() public static method

public static GetClients ( ) : List
return List

GetFileStats() public static method

public static GetFileStats ( string filePath ) : List
filePath string
return List

GetOpenedFileStats() public static method

public static GetOpenedFileStats ( int optionalChangelist ) : List
optionalChangelist int
return List

GetOpenedFiles() public static method

public static GetOpenedFiles ( int optionalChangelist ) : List
optionalChangelist int
return List

GetPendingChangelists() public static method

public static GetPendingChangelists ( ) : List
return List

Initialize() public static method

Initialize P4Shell with the current system defaults.
public static Initialize ( ) : void
return void

Integrate() public static method

public static Integrate ( string fromFile, string toFile, System.Operation operation ) : bool
fromFile string
toFile string
operation System.Operation
return bool

IsHeadRevisionDelete() public static method

public static IsHeadRevisionDelete ( FileStats fileStat ) : bool
fileStat FileStats
return bool

IsHeadRevisionDelete() public static method

public static IsHeadRevisionDelete ( string filePath, int changelistID ) : bool
filePath string
changelistID int
return bool

PingServer() public static method

Ping's the Perforce server using the current P4Shell settings.
public static PingServer ( ) : bool
return bool

Reopen() public static method

public static Reopen ( string filePath, int newChangelistID ) : bool
filePath string
newChangelistID int
return bool

Revert() public static method

public static Revert ( string filePath ) : bool
filePath string
return bool

SetFileReadOnly() public static method

public static SetFileReadOnly ( string filePath ) : void
filePath string
return void

SetFileWritable() public static method

public static SetFileWritable ( string filePath ) : void
filePath string
return void

SetFilesReadOnly() public static method

public static SetFilesReadOnly ( List files ) : void
files List
return void

SetFilesWriteable() public static method

public static SetFilesWriteable ( List files ) : void
files List
return void

StringToAction() public static method

public static StringToAction ( string actionName ) : System.Action
actionName string
return System.Action

Submit() public static method

Submits the given changelist, and updates it's description if provided. Note that when submitting the default changelist, you must always provide a description.
public static Submit ( int changelistID, string description ) : bool
changelistID int The changelistID to submit.
description string The changelist description. For changelists other than the default changelist, /// this can be null, in which case the existing changelist description will be used.
return bool

Sync() public static method

public static Sync ( string filePath ) : bool
filePath string
return bool