psdi.util

Class Release

  • java.lang.Object
    • psdi.util.Release


  • public class Release
    extends java.lang.Object
    psdi.util.Release is used to capture the version information for a release of the MXE product and to reset the related MAXVARS We need it to support DB updated with x-files to get it working with latest Maximo Build.
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      static java.util.Map allProductInfo 
      static java.lang.String build
      patch Build
      static java.lang.String DBBuild
      DB Build
      static boolean dbConnection 
      protected static java.lang.String dbPropPrefix 
      protected static java.lang.String defaultSchemaOwner 
      static java.lang.String hfDBBuild
      Hotfix DB build
      static java.lang.String hotfix
      Hotfix number
      static java.lang.String lastReleaseDBbuilds
      last release database build number, it is not final on purpose to prevent upatedb class keeps the variable in its class by the compiler.
      static java.lang.String majorVersion
      Major version name
      static java.lang.String minorVersion
      Minor version
      static java.lang.String modLevel
      Build number
      static java.lang.String patch 
      static java.lang.String productName
      Name of the product
      static java.lang.String propdir
      properties file directory
      static java.lang.String versionStr 
    • Constructor Summary

      Constructors 
      Constructor and Description
      Release() 
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      static boolean checkAndSetMaxVarInDB(java.lang.String dbmaxvarname, java.lang.String dbBuild, java.sql.Connection con)
      Check if maxvar is there in database or not.
      static java.lang.String getBaseProductName()
      returns the base product name string
      static java.sql.Connection getConnection() 
      static java.util.Map getProductInfoFromXMLStream(java.util.HashMap xmlMap, java.sql.Connection con)
      Loop through all product xml inputstream and returns version information.
      static java.lang.String[] getRelDBBuildStrings(java.lang.String previousDBBuilds)
      returns the last s' database build strings and the new release string in an array in the their relase orders.
      java.util.HashMap getStreamFromBundle(java.lang.String productDir) 
      java.util.HashMap getStreamfromDirectory(java.lang.String productDir)
      Gets maximo Input Stream from XML files in directory structure
      java.util.HashMap getStreamFromJar(java.lang.String productDir)
      Get product xml stream from jar
      static java.lang.String getString()
      Return the version label
      java.util.HashMap getXMLInputStream()
      Gets maximo Input Stream from XML files
      static void main(java.lang.String[] argv)
      Print out the version of the product to the console
      • Methods inherited from class java.lang.Object

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

      • productName

        public static final java.lang.String productName
        Name of the product
        See Also:
        Constant Field Values
      • majorVersion

        public static final java.lang.String majorVersion
        Major version name
        See Also:
        Constant Field Values
      • minorVersion

        public static final java.lang.String minorVersion
        Minor version
        See Also:
        Constant Field Values
      • lastReleaseDBbuilds

        public static java.lang.String lastReleaseDBbuilds
        last release database build number, it is not final on purpose to prevent upatedb class keeps the variable in its class by the compiler.
      • hfDBBuild

        public static final java.lang.String hfDBBuild
        Hotfix DB build
        See Also:
        Constant Field Values
      • versionStr

        public static java.lang.String versionStr
      • propdir

        public static java.lang.String propdir
        properties file directory
      • dbConnection

        public static boolean dbConnection
      • allProductInfo

        public static java.util.Map allProductInfo
      • defaultSchemaOwner

        protected static final java.lang.String defaultSchemaOwner
        See Also:
        Constant Field Values
    • Constructor Detail

      • Release

        public Release()
    • Method Detail

      • getString

        public static java.lang.String getString()
        Return the version label
      • getConnection

        public static java.sql.Connection getConnection()
      • getXMLInputStream

        public java.util.HashMap getXMLInputStream()
                                            throws java.lang.Exception
        Gets maximo Input Stream from XML files
        Returns:
        hashmap(productname,inputstream)
        Throws:
        java.lang.Exception
      • getStreamFromBundle

        public java.util.HashMap getStreamFromBundle(java.lang.String productDir)
                                              throws java.lang.Exception
        Throws:
        java.lang.Exception
      • getStreamFromJar

        public java.util.HashMap getStreamFromJar(java.lang.String productDir)
                                           throws java.lang.Exception
        Get product xml stream from jar
        Parameters:
        productDir -
        Returns:
        Throws:
        java.lang.Exception
      • getStreamfromDirectory

        public java.util.HashMap getStreamfromDirectory(java.lang.String productDir)
                                                 throws java.lang.Exception
        Gets maximo Input Stream from XML files in directory structure
        Returns:
        Throws:
        java.lang.Exception
      • main

        public static void main(java.lang.String[] argv)
        Print out the version of the product to the console
      • getProductInfoFromXMLStream

        public static java.util.Map getProductInfoFromXMLStream(java.util.HashMap xmlMap,
                                                                java.sql.Connection con)
                                                         throws java.lang.Exception
        Loop through all product xml inputstream and returns version information.
        Parameters:
        Hashmap(productname,inputstream) -
        Returns:
        version information
        Throws:
        java.lang.Exception
      • checkAndSetMaxVarInDB

        public static boolean checkAndSetMaxVarInDB(java.lang.String dbmaxvarname,
                                                    java.lang.String dbBuild,
                                                    java.sql.Connection con)
        Check if maxvar is there in database or not.
        Parameters:
        dbmaxvarname -
        con -
        Returns:
      • getBaseProductName

        public static java.lang.String getBaseProductName()
        returns the base product name string
      • getRelDBBuildStrings

        public static java.lang.String[] getRelDBBuildStrings(java.lang.String previousDBBuilds)
        returns the last s' database build strings and the new release string in an array in the their relase orders.