projects
/
yaffs-website
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Added the Search API Synonym module to deal specifically with licence and license...
[yaffs-website]
/
vendor
/
symfony
/
config
/
Definition
/
Dumper
/
YamlReferenceDumper.php
diff --git
a/vendor/symfony/config/Definition/Dumper/YamlReferenceDumper.php
b/vendor/symfony/config/Definition/Dumper/YamlReferenceDumper.php
index 5a0e76c5255a382b5265684a156b36aa92c8d5c0..fc5d20a2e70408d1423bd439b4adfcddf9f8f610 100644
(file)
--- a/
vendor/symfony/config/Definition/Dumper/YamlReferenceDumper.php
+++ b/
vendor/symfony/config/Definition/Dumper/YamlReferenceDumper.php
@@
-11,10
+11,10
@@
namespace Symfony\Component\Config\Definition\Dumper;
namespace Symfony\Component\Config\Definition\Dumper;
-use Symfony\Component\Config\Definition\ConfigurationInterface;
-use Symfony\Component\Config\Definition\NodeInterface;
use Symfony\Component\Config\Definition\ArrayNode;
use Symfony\Component\Config\Definition\ArrayNode;
+use Symfony\Component\Config\Definition\ConfigurationInterface;
use Symfony\Component\Config\Definition\EnumNode;
use Symfony\Component\Config\Definition\EnumNode;
+use Symfony\Component\Config\Definition\NodeInterface;
use Symfony\Component\Config\Definition\PrototypedArrayNode;
use Symfony\Component\Config\Definition\ScalarNode;
use Symfony\Component\Yaml\Inline;
use Symfony\Component\Config\Definition\PrototypedArrayNode;
use Symfony\Component\Config\Definition\ScalarNode;
use Symfony\Component\Yaml\Inline;
@@
-92,9
+92,9
@@
class YamlReferenceDumper
}
if (!$children) {
}
if (!$children) {
- if ($node->hasDefaultValue() && count($defaultArray = $node->getDefaultValue())) {
+ if ($node->hasDefaultValue() &&
\
count($defaultArray = $node->getDefaultValue())) {
$default = '';
$default = '';
- } elseif (!is_array($example)) {
+ } elseif (!
\
is_array($example)) {
$default = '[]';
}
}
$default = '[]';
}
}
@@
-107,10
+107,10
@@
class YamlReferenceDumper
if ($node->hasDefaultValue()) {
$default = $node->getDefaultValue();
if ($node->hasDefaultValue()) {
$default = $node->getDefaultValue();
- if (is_array($default)) {
- if (count($defaultArray = $node->getDefaultValue())) {
+ if (
\
is_array($default)) {
+ if (
\
count($defaultArray = $node->getDefaultValue())) {
$default = '';
$default = '';
- } elseif (!is_array($example)) {
+ } elseif (!
\
is_array($example)) {
$default = '[]';
}
} else {
$default = '[]';
}
} else {
@@
-130,12
+130,12
@@
class YamlReferenceDumper
}
// example
}
// example
- if ($example && !is_array($example)) {
+ if ($example && !
\
is_array($example)) {
$comments[] = 'Example: '.$example;
}
$default = '' != (string) $default ? ' '.$default : '';
$comments[] = 'Example: '.$example;
}
$default = '' != (string) $default ? ' '.$default : '';
- $comments = count($comments) ? '# '.implode(', ', $comments) : '';
+ $comments =
\
count($comments) ? '# '.implode(', ', $comments) : '';
$key = $prototypedArray ? '-' : $node->getName().':';
$text = rtrim(sprintf('%-21s%s %s', $key, $default, $comments), ' ');
$key = $prototypedArray ? '-' : $node->getName().':';
$text = rtrim(sprintf('%-21s%s %s', $key, $default, $comments), ' ');
@@
-153,17
+153,17
@@
class YamlReferenceDumper
if ($defaultArray) {
$this->writeLine('');
if ($defaultArray) {
$this->writeLine('');
- $message = count($defaultArray) > 1 ? 'Defaults' : 'Default';
+ $message =
\
count($defaultArray) > 1 ? 'Defaults' : 'Default';
$this->writeLine('# '.$message.':', $depth * 4 + 4);
$this->writeArray($defaultArray, $depth + 1);
}
$this->writeLine('# '.$message.':', $depth * 4 + 4);
$this->writeArray($defaultArray, $depth + 1);
}
- if (is_array($example)) {
+ if (
\
is_array($example)) {
$this->writeLine('');
$this->writeLine('');
- $message = count($example) > 1 ? 'Examples' : 'Example';
+ $message =
\
count($example) > 1 ? 'Examples' : 'Example';
$this->writeLine('# '.$message.':', $depth * 4 + 4);
$this->writeLine('# '.$message.':', $depth * 4 + 4);
@@
-185,7
+185,7
@@
class YamlReferenceDumper
*/
private function writeLine($text, $indent = 0)
{
*/
private function writeLine($text, $indent = 0)
{
- $indent = strlen($text) + $indent;
+ $indent =
\
strlen($text) + $indent;
$format = '%'.$indent.'s';
$this->reference .= sprintf($format, $text)."\n";
$format = '%'.$indent.'s';
$this->reference .= sprintf($format, $text)."\n";
@@
-196,7
+196,7
@@
class YamlReferenceDumper
$isIndexed = array_values($array) === $array;
foreach ($array as $key => $value) {
$isIndexed = array_values($array) === $array;
foreach ($array as $key => $value) {
- if (is_array($value)) {
+ if (
\
is_array($value)) {
$val = '';
} else {
$val = $value;
$val = '';
} else {
$val = $value;
@@
-208,7
+208,7
@@
class YamlReferenceDumper
$this->writeLine(sprintf('%-20s %s', $key.':', $val), $depth * 4);
}
$this->writeLine(sprintf('%-20s %s', $key.':', $val), $depth * 4);
}
- if (is_array($value)) {
+ if (
\
is_array($value)) {
$this->writeArray($value, $depth + 1);
}
}
$this->writeArray($value, $depth + 1);
}
}