|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r64913 - in website/public_html/beta: common/code doc
From: dnljms_at_[hidden]
Date: 2010-08-19 03:52:44
Author: danieljames
Date: 2010-08-19 03:52:42 EDT (Thu, 19 Aug 2010)
New Revision: 64913
URL: http://svn.boost.org/trac/boost/changeset/64913
Log:
Define the functions in boost_version.php inline.
All the functions in boost_version are only used in one place.
Removed:
website/public_html/beta/common/code/boost_version.php
Text files modified:
website/public_html/beta/common/code/boost.php | 1 +
website/public_html/beta/doc/display_libs.php | 29 ++++++++++++++++++++++++++++-
website/public_html/beta/doc/libraries.php | 40 +++++++++++++++++++++++++++++++++++++++-
3 files changed, 68 insertions(+), 2 deletions(-)
Modified: website/public_html/beta/common/code/boost.php
==============================================================================
--- website/public_html/beta/common/code/boost.php (original)
+++ website/public_html/beta/common/code/boost.php 2010-08-19 03:52:42 EDT (Thu, 19 Aug 2010)
@@ -4,6 +4,7 @@
Distributed under the Boost Software License, Version 1.0.
(See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
*/
+$boost_current_version = Array(1,44,0);
require_once(dirname(__FILE__) . '/boost_config.php');
require_once(dirname(__FILE__) . '/boost_utility.php');
?>
\ No newline at end of file
Deleted: website/public_html/beta/common/code/boost_version.php
==============================================================================
--- website/public_html/beta/common/code/boost_version.php 2010-08-19 03:52:42 EDT (Thu, 19 Aug 2010)
+++ (empty file)
@@ -1,76 +0,0 @@
-<?php
-/*
- Copyright 2005-2006 Redshift Software, Inc.
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
-*/
-require_once(dirname(__FILE__) . '/boost.php');
-
-$boost_current_version = Array(1,44,0);
-
-function boost_title()
-{
- $vinfo = array();
- if (isset($_SERVER["PATH_INFO"])) {
- preg_match('@([0-9]+)_([0-9]+)_([0-9]+)@',$_SERVER["PATH_INFO"],$vinfo);
- }
- if (isset($vinfo[0])) {
- array_shift($vinfo);
- return 'Boost '.implode('.', $vinfo);
- }
- else {
- return 'Boost';
- }
-}
-
-function boost_version($v,$r,$p)
-{
- if (isset($_SERVER["PATH_INFO"]))
- {
- $vinfo = array();
- preg_match('@([0-9]+)_([0-9]+)_([0-9]+)@',$_SERVER["PATH_INFO"],$vinfo);
- if (isset($vinfo[0]))
- {
- return
- ($v < $vinfo[1]) ||
- ($v == $vinfo[1] && $r < $vinfo[2]) ||
- ($v == $vinfo[1] && $r == $vinfo[2] && $p <= $vinfo[3]);
- }
- else
- {
- return FALSE;
- }
- }
- else
- {
- return TRUE;
- }
-}
-
-function boost_future_version($version)
-{
- if ($version)
- {
- $vinfo = array();
- preg_match('@([0-9]+)_([0-9]+)_([0-9]+)@',$version,$vinfo);
- if (isset($vinfo[0]))
- {
- global $boost_current_version;
- $v = $boost_current_version[0];
- $r = $boost_current_version[1];
- $p = $boost_current_version[2];
- return
- ($v < $vinfo[1]) ||
- ($v == $vinfo[1] && $r < $vinfo[2]) ||
- ($v == $vinfo[1] && $r == $vinfo[2] && $p < $vinfo[3]);
- }
- else
- {
- return FALSE;
- }
- }
- else
- {
- return FALSE;
- }
-}
Modified: website/public_html/beta/doc/display_libs.php
==============================================================================
--- website/public_html/beta/doc/display_libs.php (original)
+++ website/public_html/beta/doc/display_libs.php 2010-08-19 03:52:42 EDT (Thu, 19 Aug 2010)
@@ -1,6 +1,33 @@
<?php
require_once(dirname(__FILE__) . '/../common/code/boost_archive.php');
-require_once(dirname(__FILE__) . '/../common/code/boost_version.php');
+
+function boost_future_version($version)
+{
+ if ($version)
+ {
+ $vinfo = array();
+ preg_match('@([0-9]+)_([0-9]+)_([0-9]+)@',$version,$vinfo);
+ if (isset($vinfo[0]))
+ {
+ global $boost_current_version;
+ $v = $boost_current_version[0];
+ $r = $boost_current_version[1];
+ $p = $boost_current_version[2];
+ return
+ ($v < $vinfo[1]) ||
+ ($v == $vinfo[1] && $r < $vinfo[2]) ||
+ ($v == $vinfo[1] && $r == $vinfo[2] && $p < $vinfo[3]);
+ }
+ else
+ {
+ return FALSE;
+ }
+ }
+ else
+ {
+ return FALSE;
+ }
+}
function add_spirit_analytics($content) {
if(stripos($content, '_uacct = "UA-11715441-2"') !== FALSE)
Modified: website/public_html/beta/doc/libraries.php
==============================================================================
--- website/public_html/beta/doc/libraries.php (original)
+++ website/public_html/beta/doc/libraries.php 2010-08-19 03:52:42 EDT (Thu, 19 Aug 2010)
@@ -1,8 +1,46 @@
<?php
-require_once(dirname(__FILE__) . '/../common/code/boost_version.php');
require_once(dirname(__FILE__) . '/../common/code/boost_libraries.php');
+function boost_title()
+{
+ $vinfo = array();
+ if (isset($_SERVER["PATH_INFO"])) {
+ preg_match('@([0-9]+)_([0-9]+)_([0-9]+)@',$_SERVER["PATH_INFO"],$vinfo);
+ }
+ if (isset($vinfo[0])) {
+ array_shift($vinfo);
+ return 'Boost '.implode('.', $vinfo);
+ }
+ else {
+ return 'Boost';
+ }
+}
+
+function boost_version($v,$r,$p)
+{
+ if (isset($_SERVER["PATH_INFO"]))
+ {
+ $vinfo = array();
+ preg_match('@([0-9]+)_([0-9]+)_([0-9]+)@',$_SERVER["PATH_INFO"],$vinfo);
+ if (isset($vinfo[0]))
+ {
+ return
+ ($v < $vinfo[1]) ||
+ ($v == $vinfo[1] && $r < $vinfo[2]) ||
+ ($v == $vinfo[1] && $r == $vinfo[2] && $p <= $vinfo[3]);
+ }
+ else
+ {
+ return FALSE;
+ }
+ }
+ else
+ {
+ return TRUE;
+ }
+}
+
//$libs = new boost_libraries(dirname(__FILE__) . '/libraries.xml');
$libs = unserialize(file_get_contents(dirname(__FILE__) . '/libraries.txt'));
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk