Package com.jalios.jcms
Class JcmsInfo
- java.lang.Object
-
- com.jalios.jcms.JcmsInfo
-
- All Implemented Interfaces:
JaliosConstants
public class JcmsInfo extends java.lang.Object implements JaliosConstants
This class manages information about JCMS release.- Since:
- jcms-3.0
- Author:
- Olivier Dedieu
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringBUILDstatic java.lang.StringGIT_REVISIONstatic java.lang.StringRELEASEstatic java.lang.StringRELEASE_CANDIDATEstatic intRELEASE_MAINTENANCEstatic intRELEASE_MAJORstatic intRELEASE_MINORstatic java.lang.StringSVN_REVISION-
Fields inherited from interface com.jalios.util.JaliosConstants
CRLF, MILLIS_IN_ONE_DAY, MILLIS_IN_ONE_HOUR, MILLIS_IN_ONE_MINUTE, MILLIS_IN_ONE_MONTH, MILLIS_IN_ONE_SECOND, MILLIS_IN_ONE_WEEK, MILLIS_IN_ONE_YEAR
-
-
Constructor Summary
Constructors Constructor Description JcmsInfo()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompareToVersion(int major, int minor, int maintenance)Compare this version of JPlatform to the given version (major.minor.maintenance)static java.lang.StringgenerateAddPackProp(java.lang.String addPack, java.lang.String channelName)Generates a add-pack property from a given string.com.jalios.jcms.JcmsInfo.AdditionalPackgetAdditionalPack()java.util.DategetAddPackExpirationDate()Return the expiration date of the current AddPack, if any.java.lang.StringgetAddPackName()Returns the name of the add-pack.java.util.Map<java.lang.String,java.lang.String>getBuildPropertiesMap()static org.apache.log4j.LoggergetLogger()java.lang.StringgetVersion()static intgetVersionMaintenance()static intgetVersionMajor()static intgetVersionMinor()voidinit()
-
-
-
Field Detail
-
RELEASE_MAJOR
public static final int RELEASE_MAJOR
-
RELEASE_MINOR
public static final int RELEASE_MINOR
-
RELEASE_MAINTENANCE
public static final int RELEASE_MAINTENANCE
-
RELEASE_CANDIDATE
public static final java.lang.String RELEASE_CANDIDATE
-
RELEASE
public static final java.lang.String RELEASE
-
BUILD
public static final java.lang.String BUILD
- See Also:
- Constant Field Values
-
SVN_REVISION
public static final java.lang.String SVN_REVISION
- See Also:
- Constant Field Values
-
GIT_REVISION
public static final java.lang.String GIT_REVISION
- See Also:
- Constant Field Values
-
-
Method Detail
-
init
public void init()
-
getLogger
public static org.apache.log4j.Logger getLogger()
-
getVersion
public java.lang.String getVersion()
- Returns:
- JPlatform version string
- Since:
- jcms-3.0
-
getVersionMajor
public static int getVersionMajor()
- Returns:
- JPlatform major version number
- Since:
- jcms-10.0.5
-
getVersionMinor
public static int getVersionMinor()
- Returns:
- JPlatform mino version number
- Since:
- jcms-10.0.5
-
getVersionMaintenance
public static int getVersionMaintenance()
- Returns:
- JPlatform maintenance version number
- Since:
- jcms-10.0.5
-
getBuildPropertiesMap
public java.util.Map<java.lang.String,java.lang.String> getBuildPropertiesMap()
- Returns:
- JCMS build properties map
- Since:
- jcms-10.0.1
-
generateAddPackProp
public static java.lang.String generateAddPackProp(java.lang.String addPack, java.lang.String channelName)Generates a add-pack property from a given string.- Parameters:
addPack- the add-pack stringchannelName- the name of the channel- Returns:
- the add-pack property
- Since:
- jcms-5.6.0
-
getAdditionalPack
public com.jalios.jcms.JcmsInfo.AdditionalPack getAdditionalPack()
-
getAddPackExpirationDate
public java.util.Date getAddPackExpirationDate()
Return the expiration date of the current AddPack, if any.- Returns:
- a Date, or null if no addpack is configured, or if this add pack does not have an expiration date
-
getAddPackName
public java.lang.String getAddPackName()
Returns the name of the add-pack.- Returns:
- the name of the add-pack.
- Since:
- jcms-8.0.0
-
compareToVersion
public int compareToVersion(int major, int minor, int maintenance)Compare this version of JPlatform to the given version (major.minor.maintenance)- Parameters:
major- the major digitminor- the minor digitmaintenance- the maintenance digit- Returns:
- 1 if this version is greater than the given one. 0 if it is the same. -1 if this version is lesser than the given one.
- Since:
- jcms-10.0.5
-
-