Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.jcorporate.expresso.core.utility
Class ReNameUtil  view ReNameUtil download ReNameUtil.java

java.lang.Object
  extended bycom.jcorporate.expresso.core.utility.ReNameUtil

public class ReNameUtil
extends java.lang.Object

Utility for renaming classes & dependant objects. Takes a "mapping" file that gives the "from/to" pairs, and a directory to start looking for files in - then all files in that directory are processed


Field Summary
private static java.lang.String suffix
          Suffix to be appended to copy of the file as it's processed
private static java.lang.String thisClass
           
private static int totalEdits
           
private static java.util.Hashtable translateTable
           
 
Constructor Summary
ReNameUtil()
          Constructor
 
Method Summary
static java.util.Vector getDir(java.lang.String dirName)
          Return a vector of the file/dir names in any give directory
static java.lang.String getExtension(java.lang.String fileName)
          Get the file extension (after the ".")
static java.lang.String getPath(java.lang.String fileName)
          Get the path of a file name
static void main(java.lang.String[] args)
           
static void processDB(java.lang.String configDir, java.lang.String db)
           
static void processDirs(java.lang.String fileName)
           
static void processFile(java.lang.String sourceFile)
          Process a single file
private static void readTransFile(java.lang.String transFileName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

thisClass

private static java.lang.String thisClass

suffix

private static java.lang.String suffix
Suffix to be appended to copy of the file as it's processed


translateTable

private static java.util.Hashtable translateTable

totalEdits

private static int totalEdits
Constructor Detail

ReNameUtil

public ReNameUtil()
Constructor

Method Detail

processDirs

public static void processDirs(java.lang.String fileName)
                        throws java.io.IOException

processFile

public static void processFile(java.lang.String sourceFile)
                        throws java.io.IOException
Process a single file


getDir

public static java.util.Vector getDir(java.lang.String dirName)
                               throws java.io.IOException
Return a vector of the file/dir names in any give directory


getExtension

public static java.lang.String getExtension(java.lang.String fileName)
                                     throws java.io.IOException
Get the file extension (after the ".")


getPath

public static java.lang.String getPath(java.lang.String fileName)
Get the path of a file name


readTransFile

private static void readTransFile(java.lang.String transFileName)
                           throws java.io.IOException

processDB

public static void processDB(java.lang.String configDir,
                             java.lang.String db)
                      throws java.io.IOException,
                             com.jcorporate.expresso.core.db.DBException,
                             com.jcorporate.expresso.core.misc.ConfigurationException

main

public static void main(java.lang.String[] args)