/content/code/trunk/administrator/components/com_artofcontent/version.php
PHP | 97 lines | 26 code | 12 blank | 59 comment | 2 complexity | ce3bcaf7bb75f570f651ad3aa23775c9 MD5 | raw file
- <?php
- /**
- * @version $Id: version.php 484 2010-12-20 23:40:27Z eddieajau $
- * @package NewLifeInIT
- * @subpackage com_artofcontent
- * @copyright Copyright 2005 - 2010 New Life in IT Pty Ltd. All rights reserved.
- * @license GNU General Public License <http://www.fsf.org/licensing/licenses/gpl.html>
- * @link http://www.theartofjoomla.com
- */
- // No direct access.
- defined('_JEXEC') or die;
- /**
- * @package NewLifeInIT
- * @subpackage com_artofcontent
- * @since 1.0
- */
- class ArtofContentVersion
- {
- /**
- * Extension name string.
- *
- * @var string
- */
- const EXTENSION = 'com_artofcontent';
- /**
- * Major.Minor version string.
- *
- * @var string
- */
- const VERSION = '1.0';
- /**
- * Maintenance version string.
- *
- * @var string
- */
- const SUBVERSION = '0';
- /**
- * Version status string.
- *
- * @var string
- */
- const STATUS = '';
- /**
- * Version release time stamp.
- *
- * @var string
- */
- const DATE = '2010-12-20 00:00:00';
- /**
- * Source control revision string.
- *
- * @var string
- */
- const REVISION = '$Revision: 484 $';
- /**
- * Method to get the build number from the source control revision string.
- *
- * @return integer The version build number.
- * @since 1.0
- */
- public static function getBuild()
- {
- return intval(substr(self::REVISION, 11));
- }
- /**
- * Gets the version number.
- *
- * @param boolean $build Optionally show the build number.
- * @param boolean $status Optionally show the status string.
- *
- * @return string
- * @since 1.0.3
- */
- public static function getVersion($build = false, $status = false)
- {
- $text = self::VERSION.'.'.self::SUBVERSION;
- if ($build) {
- $text .= ':'.self::getBuild();
- }
- if ($status) {
- $text .= ' '.self::STATUS;
- }
- return $text;
- }
- }