jena-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a...@apache.org
Subject jena git commit: Environment variable access.
Date Thu, 27 Nov 2014 16:23:31 GMT
Repository: jena
Updated Branches:
  refs/heads/master 61eb14b95 -> 955c82cf5


Environment variable access.

Project: http://git-wip-us.apache.org/repos/asf/jena/repo
Commit: http://git-wip-us.apache.org/repos/asf/jena/commit/955c82cf
Tree: http://git-wip-us.apache.org/repos/asf/jena/tree/955c82cf
Diff: http://git-wip-us.apache.org/repos/asf/jena/diff/955c82cf

Branch: refs/heads/master
Commit: 955c82cf561976a5c2aca0ec6741d0026693b7c0
Parents: 61eb14b
Author: Andy Seaborne <andy@apache.org>
Authored: Thu Nov 27 16:23:15 2014 +0000
Committer: Andy Seaborne <andy@apache.org>
Committed: Thu Nov 27 16:23:15 2014 +0000

----------------------------------------------------------------------
 .../java/org/apache/jena/fuseki/server/FusekiServer.java  | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/jena/blob/955c82cf/jena-fuseki2/src/main/java/org/apache/jena/fuseki/server/FusekiServer.java
----------------------------------------------------------------------
diff --git a/jena-fuseki2/src/main/java/org/apache/jena/fuseki/server/FusekiServer.java b/jena-fuseki2/src/main/java/org/apache/jena/fuseki/server/FusekiServer.java
index 17f1da6..9188b05 100644
--- a/jena-fuseki2/src/main/java/org/apache/jena/fuseki/server/FusekiServer.java
+++ b/jena-fuseki2/src/main/java/org/apache/jena/fuseki/server/FusekiServer.java
@@ -126,13 +126,13 @@ public class FusekiServer
         
         if ( FUSEKI_HOME == null ) {
             // Make absolute
-            String x1 = System.getenv("FUSEKI_HOME") ;
+            String x1 = getenv("FUSEKI_HOME") ;
             if ( x1 != null )
                 FUSEKI_HOME = Paths.get(x1) ;
         }
             
         if ( FUSEKI_BASE == null ) {
-            String x2 = System.getenv("FUSEKI_BASE") ;
+            String x2 = getenv("FUSEKI_BASE") ;
             if ( x2 != null )
                 FUSEKI_BASE = Paths.get(x2) ;
             else {
@@ -193,6 +193,12 @@ public class FusekiServer
         
         serverInitialized = true ;
     }
+    
+    /** Get environment variable value. */
+    private static String getenv(String name) {
+        //Possible intercept poiint
+        return System.getenv(name) ;
+    }
 
     private static boolean emptyDir(Path dir) {
         return dir.toFile().list().length <= 2 ;


Mime
View raw message