org.apache.maven.scm.provider.synergy.util
Class SynergyCCM

java.lang.Object
  extended by org.apache.maven.scm.provider.synergy.util.SynergyCCM

public class SynergyCCM
extends Object

This class contains methods to execute Synergy ccm command line.

Version:
$Id: SynergyCCM.java 1333668 2012-05-03 22:37:08Z hboutemy $
Author:
Julien Henry

Constructor Summary
SynergyCCM()
           
 
Method Summary
static Commandline checkinFiles(List<File> files, String comment, String ccmAddr)
          Create commandline to checkin a fileset
static Commandline checkinProject(String projectSpec, String comment, String ccmAddr)
          Create commandline to checkin a project
static Commandline checkinTask(String taskSpecs, String comment, String ccmAddr)
          Create command line for checkin a task
static Commandline checkoutFiles(List<File> files, String ccmAddr)
          Create commandline to checkout a fileset.
static Commandline checkoutProject(File directory, String projectSpec, ScmVersion version, String purpose, String release, String ccmAddr)
          Create commandline to checkout a project
static Commandline create(List<File> files, String message, String ccmAddr)
          Create command line for adding a fileset to a project
static Commandline createBaseline(String projectSpec, String name, String release, String purpose, String ccmAddr)
          Create command line for creating a baseline.
static Commandline createTask(String synopsis, String release, boolean defaultTask, String ccmAddr)
          Create command line for creating a task
static Commandline delete(List<File> files, String ccmAddr, boolean replace)
          Create command line for deleting file(s).
static Commandline delimiter(String ccmAddr)
          Create commandline to get Synergy database delimiter
static Commandline dir(File directory, String format, String ccmAddr)
          Create command line to perform a dir on the directory.
static Commandline query(String query, String format, String ccmAddr)
          Create commandline for query.
static Commandline reconcileUdb(String projectSpec, String ccmAddr)
          Create command line to reconcile a project with udb option.
static Commandline reconcileUwa(String projectSpec, String ccmAddr)
          Create command line to reconcile a project with uwa option.
static Commandline reconfigure(String projectSpec, String ccmAddr)
          Create commandline to reconfigure a project.
static Commandline reconfigureProperties(String projectSpec, String ccmAddr)
          Create commandline to reconfigure properties of a project.
static Commandline setDefaultTask(int task, String ccmAddr)
          Create commandline to set current (i.e. default) task
static Commandline showDefaultTask(String ccmAddr)
          Create commandline to get current (i.e. default) task
static Commandline showTaskObjects(int taskNumber, String format, String ccmAddr)
          Create commandline for getting list of objects in a task.
static Commandline showWorkArea(String projectSpec, String ccmAddr)
          Create commandline to get workarea informations for a given project.
static Commandline start(String username, String password, SynergyRole role)
          Create commandline to start a Synergy session
static Commandline startRemote(String username, String password, SynergyRole role)
          Create commandline to start a remote Synergy session
static Commandline stop(String ccmAddr)
          Create commandline to stop a Synergy session
static Commandline synchronize(String projectSpec, String ccmAddr)
          Create commandline to synchronize a project
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SynergyCCM

public SynergyCCM()
Method Detail

showTaskObjects

public static Commandline showTaskObjects(int taskNumber,
                                          String format,
                                          String ccmAddr)
                                   throws ScmException
Create commandline for getting list of objects in a task.

Parameters:
taskNumber - Task number.
format - Output format.
ccmAddr -
Returns:
the commandline.
Throws:
ScmException

query

public static Commandline query(String query,
                                String format,
                                String ccmAddr)
                         throws ScmException
Create commandline for query.

Parameters:
query - query.
format - Output format
ccmAddr -
Returns:
the command line.
Throws:
ScmException

createBaseline

public static Commandline createBaseline(String projectSpec,
                                         String name,
                                         String release,
                                         String purpose,
                                         String ccmAddr)
                                  throws ScmException
Create command line for creating a baseline.

Parameters:
projectSpec - project_name~project_version
name - Name of the baseline
release - the release.
purpose - the purpose.
ccmAddr -
Returns:
the command line.
Throws:
ScmException

create

public static Commandline create(List<File> files,
                                 String message,
                                 String ccmAddr)
                          throws ScmException
Create command line for adding a fileset to a project

Parameters:
files - fileset.
message - message log, or null if none.
ccmAddr -
Returns:
the command line.
Throws:
ScmException

createTask

public static Commandline createTask(String synopsis,
                                     String release,
                                     boolean defaultTask,
                                     String ccmAddr)
                              throws ScmException
Create command line for creating a task

Parameters:
synopsis - synopsis.
release - release.
defaultTask - default.
ccmAddr -
Returns:
the command line.
Throws:
ScmException

checkinTask

public static Commandline checkinTask(String taskSpecs,
                                      String comment,
                                      String ccmAddr)
                               throws ScmException
Create command line for checkin a task

Parameters:
taskSpecs - task_specs or default
comment - comment.
ccmAddr -
Returns:
Throws:
ScmException

delete

public static Commandline delete(List<File> files,
                                 String ccmAddr,
                                 boolean replace)
                          throws ScmException
Create command line for deleting file(s).

Parameters:
files - fileset.
ccmAddr -
replace - replace with previous version of file ?
Returns:
Throws:
ScmException

reconfigure

public static Commandline reconfigure(String projectSpec,
                                      String ccmAddr)
                               throws ScmException
Create commandline to reconfigure a project.

Parameters:
projectSpec -
ccmAddr -
Returns:
the command line.
Throws:
ScmException

reconfigureProperties

public static Commandline reconfigureProperties(String projectSpec,
                                                String ccmAddr)
                                         throws ScmException
Create commandline to reconfigure properties of a project.

Parameters:
projectSpec -
ccmAddr -
Returns:
Throws:
ScmException

reconcileUwa

public static Commandline reconcileUwa(String projectSpec,
                                       String ccmAddr)
                                throws ScmException
Create command line to reconcile a project with uwa option.

Parameters:
projectSpec -
ccmAddr -
Returns:
Throws:
ScmException

reconcileUdb

public static Commandline reconcileUdb(String projectSpec,
                                       String ccmAddr)
                                throws ScmException
Create command line to reconcile a project with udb option.

Parameters:
projectSpec -
ccmAddr -
Returns:
Throws:
ScmException

dir

public static Commandline dir(File directory,
                              String format,
                              String ccmAddr)
                       throws ScmException
Create command line to perform a dir on the directory.

Parameters:
directory -
format - Output format.
ccmAddr -
Returns:
Throws:
ScmException

checkoutFiles

public static Commandline checkoutFiles(List<File> files,
                                        String ccmAddr)
                                 throws ScmException
Create commandline to checkout a fileset.

Parameters:
files - fileset.
ccmAddr -
Returns:
the command line.
Throws:
ScmException

checkoutProject

public static Commandline checkoutProject(File directory,
                                          String projectSpec,
                                          ScmVersion version,
                                          String purpose,
                                          String release,
                                          String ccmAddr)
                                   throws ScmException
Create commandline to checkout a project

Parameters:
directory - target WA, or null if using default directory
projectSpec -
version - new version of the project, or null if using default Synergy mecanism
ccmAddr -
Returns:
Throws:
ScmException

checkinProject

public static Commandline checkinProject(String projectSpec,
                                         String comment,
                                         String ccmAddr)
                                  throws ScmException
Create commandline to checkin a project

Parameters:
projectSpec -
comment -
ccmAddr -
Returns:
Throws:
ScmException

checkinFiles

public static Commandline checkinFiles(List<File> files,
                                       String comment,
                                       String ccmAddr)
                                throws ScmException
Create commandline to checkin a fileset

Parameters:
files - fileset.
comment -
ccmAddr -
Returns:
Throws:
ScmException

synchronize

public static Commandline synchronize(String projectSpec,
                                      String ccmAddr)
                               throws ScmException
Create commandline to synchronize a project

Parameters:
projectSpec -
ccmAddr -
Returns:
Throws:
ScmException

showWorkArea

public static Commandline showWorkArea(String projectSpec,
                                       String ccmAddr)
                                throws ScmException
Create commandline to get workarea informations for a given project.

Parameters:
projectSpec -
ccmAddr -
Returns:
Throws:
ScmException

stop

public static Commandline stop(String ccmAddr)
                        throws ScmException
Create commandline to stop a Synergy session

Parameters:
ccmAddr -
Returns:
Throws:
ScmException

start

public static Commandline start(String username,
                                String password,
                                SynergyRole role)
                         throws ScmException
Create commandline to start a Synergy session

Parameters:
username -
password -
role -
Returns:
Throws:
ScmException

startRemote

public static Commandline startRemote(String username,
                                      String password,
                                      SynergyRole role)
                               throws ScmException
Create commandline to start a remote Synergy session

Parameters:
username -
password -
role -
Returns:
Throws:
ScmException

delimiter

public static Commandline delimiter(String ccmAddr)
                             throws ScmException
Create commandline to get Synergy database delimiter

Returns:
Throws:
ScmException

showDefaultTask

public static Commandline showDefaultTask(String ccmAddr)
                                   throws ScmException
Create commandline to get current (i.e. default) task

Parameters:
ccmAddr - current Synergy session ID
Returns:
Throws:
ScmException

setDefaultTask

public static Commandline setDefaultTask(int task,
                                         String ccmAddr)
                                  throws ScmException
Create commandline to set current (i.e. default) task

Parameters:
task - the number of the task to set as current task
ccmAddr - current Synergy session ID
Returns:
Throws:
ScmException


Copyright © 2003-2012 The Apache Software Foundation. All Rights Reserved.