Class MigrateGlobalProperties


  • public class MigrateGlobalProperties
    extends java.lang.Object
    The MigrateGlobalProperties class is a small program that will migrate any global.properties (or solutions.properties) file from 6.0, 6.1, 6.1.1, 7.0, 7.1 & 7.1.1 to TDI 7.2. See the main method for information of valid parameters that can be passed into the command. The program relies on the icu4j library for globalization. It relies on log4j for logging.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void main​(java.lang.String[] args)
      The main method of the Migrate Global Properties Command.
      static int migrateFile()
      Migrates the input file to the TDI 7.2 level.
      static boolean mustMigrateDerby​(java.lang.StringBuilder globalPropNewBuf)
      Determine the file has old derby information and needs to be migrated.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MigrateGlobalProperties

        public MigrateGlobalProperties()
    • Method Detail

      • mustMigrateDerby

        public static boolean mustMigrateDerby​(java.lang.StringBuilder globalPropNewBuf)
        Determine the file has old derby information and needs to be migrated.
        Parameters:
        globalPropNewBuf - The string buffer to look in that represents the file. This is the file content that should be search through and should be a global/solution.properties file.
        Returns:
        True if the Derby information should be migrated. Otherwise, false is returned.
      • migrateFile

        public static int migrateFile()
        Migrates the input file to the TDI 7.2 level. It assumes the input file a global.properties (solution.properties file). The input file (and optional backup file) should have been set in the parseGeneralOptions method which must be called before calling this method.
        Returns:
        1 is returned if the file is successful. -1 is returned if any error occurs while trying to migrate the file including if the file cannot be backed up to the specified location or if the file to migrate cannot be written to.
      • main

        public static void main​(java.lang.String[] args)
        The main method of the Migrate Global Properties Command. The command exits with a 0 if it completes successfully. If the command failes it exits with a -1.
        Parameters:
        args - The arguments passed into the command. Valid arguments are: