|
From: <cw...@us...> - 2007-08-12 11:03:14
|
Revision: 482
http://rdfapi-php.svn.sourceforge.net/rdfapi-php/?rev=482&view=rev
Author: cweiske
Date: 2007-08-12 04:03:13 -0700 (Sun, 12 Aug 2007)
Log Message:
-----------
nicify indentation
Modified Paths:
--------------
trunk/rdfapi-php/api/syntax/N3Parser.php
Modified: trunk/rdfapi-php/api/syntax/N3Parser.php
===================================================================
--- trunk/rdfapi-php/api/syntax/N3Parser.php 2007-08-12 10:14:41 UTC (rev 481)
+++ trunk/rdfapi-php/api/syntax/N3Parser.php 2007-08-12 11:03:13 UTC (rev 482)
@@ -793,33 +793,34 @@
while (in_array($schar, $list)) {
// while schar in list {
- $ndict=array();
- $nestingLevel=0;
- $biggest=0;
- for ($i=0;$i<count($list);$i++) {
- if ($list[$i] == $schar) {
- $nestingLevel += 1;
- if (!in_array($nestingLevel, array_keys($ndict))) {
- $ndict[$nestingLevel] = array(array($i));
- } else {
- $ndict[$nestingLevel][]=array($i);
- }
- }
- if ($list[$i] == $echar) {
- if (!in_array($nestingLevel, array_keys($ndict))) {
- $ndict[$nestingLevel]=array(array($i));
- } else {
+ $ndict = array();
+ $nestingLevel = 0;
+ $biggest = 0;
+ for ($i = 0; $i < count($list); $i++) {
+ if ($list[$i] == $schar) {
+ $nestingLevel += 1;
+ if (!in_array($nestingLevel, array_keys($ndict))) {
+ $ndict[$nestingLevel] = array(array($i));
+ } else {
+ $ndict[$nestingLevel][]=array($i);
+ }
+ }
+ if ($list[$i] == $echar) {
+ if (!in_array($nestingLevel, array_keys($ndict))) {
+ $ndict[$nestingLevel]=array(array($i));
+ } else {
$ndict[$nestingLevel][count($ndict[$nestingLevel])-1][]=$i;
$nestingLevel-= 1;
# elif type(list[i]) == type([]) {
# list[i] = doLists(list[i], schar, echar)
- }
- }
+ }
+ }
}
- foreach (array_keys($ndict) as $key)
- if ($key > $biggest) $biggest = $key;
+ foreach (array_keys($ndict) as $key) {
+ if ($key > $biggest) $biggest = $key;
+ }
- $tol = $ndict[$biggest][0];
+ $tol = $ndict[$biggest][0];
$list = $this->listify($list, $tol[0], ($tol[1]+1));
}
return $list;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|