コード例 #1
0
ファイル: Project.php プロジェクト: Ingewikkeld/phing
 /**
  * Sets system properties and the environment variables for this project.
  *
  * @return void
  */
 public function setSystemProperties()
 {
     // first get system properties
     $systemP = array_merge(self::getProperties(), Phing::getProperties());
     foreach ($systemP as $name => $value) {
         $this->setPropertyInternal($name, $value);
     }
     // and now the env vars
     foreach ($_SERVER as $name => $value) {
         // skip arrays
         if (is_array($value)) {
             continue;
         }
         $this->setPropertyInternal('env.' . $name, $value);
     }
     return true;
 }
コード例 #2
0
ファイル: Diagnostics.php プロジェクト: Ingewikkeld/phing
 /**
  * Report a listing of system properties existing in the current phing.
  *
  * @param PrintStream $out the stream to print the properties to.
  */
 private static function doReportSystemProperties(PrintStream $out)
 {
     $phing = new Phing();
     $phingprops = $phing->getProperties();
     foreach ($phingprops as $key => $value) {
         $out->println($key . " : " . $value);
     }
 }