org.kuali.student.common.util
Class ManifestInspector

java.lang.Object
  extended by org.kuali.student.common.util.ManifestInspector

public class ManifestInspector
extends Object

Obtains version information about the application from the META-INF/MANIFEST.MF file contained inside a .war file


Field Summary
static String BUNDLE_BUILD_NUMBER
           
static String BUNDLE_NAME
           
static String BUNDLE_TIMESTAMP
           
static String BUNDLE_VERSION
           
static String MANIFEST_LOCATION
          Location of the MANIFEST.MF file
static String NO_BUILD_INFORMATION_AVAILABLE
           
 
Constructor Summary
ManifestInspector()
           
 
Method Summary
protected  BuildInformation getBuildInformation(Manifest manifest)
          Examine the manifest provided for build information.
 String getBuildInformationString(ServletContext context)
          Obtain version information from MANIFEST.MF
protected  Manifest getManifest(ServletContext servletContext)
          Return a Manifest object
protected  boolean isNullOrEmpty(BuildInformation bi)
          Return true if BuildInformation is null or does not contain any meaningful information.
 String toString(BuildInformation bi)
          Convert the build information POJO to a display String
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MANIFEST_LOCATION

public static final String MANIFEST_LOCATION
Location of the MANIFEST.MF file

See Also:
Constant Field Values

BUNDLE_NAME

public static final String BUNDLE_NAME
See Also:
Constant Field Values

BUNDLE_VERSION

public static final String BUNDLE_VERSION
See Also:
Constant Field Values

BUNDLE_TIMESTAMP

public static final String BUNDLE_TIMESTAMP
See Also:
Constant Field Values

BUNDLE_BUILD_NUMBER

public static final String BUNDLE_BUILD_NUMBER
See Also:
Constant Field Values

NO_BUILD_INFORMATION_AVAILABLE

public static final String NO_BUILD_INFORMATION_AVAILABLE
See Also:
Constant Field Values
Constructor Detail

ManifestInspector

public ManifestInspector()
Method Detail

getManifest

protected Manifest getManifest(ServletContext servletContext)
                        throws IOException
Return a Manifest object

Throws:
IOException

getBuildInformation

protected BuildInformation getBuildInformation(Manifest manifest)
Examine the manifest provided for build information. Returns null if manifest is null


getBuildInformationString

public String getBuildInformationString(ServletContext context)
                                 throws IOException
Obtain version information from MANIFEST.MF

Throws:
IOException

isNullOrEmpty

protected boolean isNullOrEmpty(BuildInformation bi)
Return true if BuildInformation is null or does not contain any meaningful information.


toString

public String toString(BuildInformation bi)
Convert the build information POJO to a display String



Copyright © 2004-2011 The Kuali Foundation. All Rights Reserved.