com.sun.electric.tool.cvspm
Class Update

java.lang.Object
  extended by com.sun.electric.tool.cvspm.Update

public class Update
extends java.lang.Object

User: gainsley Date: Mar 13, 2006


Nested Class Summary
static class Update.StatusResult
           
static class Update.UpdateEnum
           
 
Constructor Summary
Update()
           
 
Method Summary
static void commentStatusResult(Update.StatusResult result, Update.UpdateEnum type)
          Parse the output of an 'cvs -nq update' command, which checks the status of the given files.
static void rollback(Cell cell)
           
static void rollback(Library lib)
           
static void update(java.util.List<Library> libs, java.util.List<Cell> cells, Update.UpdateEnum type, boolean updateProject, boolean checkEditors)
          Run Update/Status/Rollback on the libraries and cells
protected static Update.StatusResult update(java.lang.String cvsProgram, java.lang.String repository, java.lang.String file, java.lang.String dir, Update.UpdateEnum type)
          Update the given file in the given directory.
static void updateCell(Cell cell, Update.UpdateEnum type)
          Update a Cell.
static void updateLibrary(Library lib, Update.UpdateEnum type)
          Update all Cells from a library.
static void updateOpenLibraries(Update.UpdateEnum type)
          Update all open libraries.
static void updateProject(Update.UpdateEnum type)
          Update all libraries.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Update

public Update()
Method Detail

updateProject

public static void updateProject(Update.UpdateEnum type)
Update all libraries.

Parameters:
type - the type of update to do

updateOpenLibraries

public static void updateOpenLibraries(Update.UpdateEnum type)
Update all open libraries.

Parameters:
type - the type of update to do

updateLibrary

public static void updateLibrary(Library lib,
                                 Update.UpdateEnum type)
Update all Cells from a library.

Parameters:
lib -
type - the type of update to do

updateCell

public static void updateCell(Cell cell,
                              Update.UpdateEnum type)
Update a Cell.

Parameters:
cell -
type - the type of update to do

update

public static void update(java.util.List<Library> libs,
                          java.util.List<Cell> cells,
                          Update.UpdateEnum type,
                          boolean updateProject,
                          boolean checkEditors)
Run Update/Status/Rollback on the libraries and cells

Parameters:
libs -
cells -
type -
updateProject -
checkEditors -

update

protected static Update.StatusResult update(java.lang.String cvsProgram,
                                            java.lang.String repository,
                                            java.lang.String file,
                                            java.lang.String dir,
                                            Update.UpdateEnum type)
Update the given file in the given directory.

Parameters:
cvsProgram - the name of CVS program
repository - the path to CVS repository
file - the name of the file.
dir - the directory.
Returns:
parsed output from running CVS.

rollback

public static void rollback(Cell cell)

rollback

public static void rollback(Library lib)

commentStatusResult

public static void commentStatusResult(Update.StatusResult result,
                                       Update.UpdateEnum type)
Parse the output of an 'cvs -nq update' command, which checks the status of the given files. Returns true if all files are up-to-date, false otherwise