@@ -54,21 +54,19 @@ public function getPropertyTypeName($typeInteger)
5454 */
5555 public function formatQueryResult (QueryResultInterface $ result , OutputInterface $ output , $ elapsed )
5656 {
57- $ selectorNames = $ result ->getSelectorNames ();
58-
5957 $ table = $ this ->tableHelper ->create ();
6058 $ table ->setHeaders (array_merge (array (
6159 'Path ' ,
6260 'Index ' ,
6361 ), $ result ->getColumnNames ()));
6462
65- foreach ($ result ->getRows () as $ i => $ row ) {
63+ foreach ($ result ->getRows () as $ row ) {
6664 $ values = array_merge (array (
6765 $ row ->getPath (),
6866 $ row ->getNode ()->getIndex (),
6967 ), $ row ->getValues ());
7068
71- foreach ($ values as $ columnName => &$ value ) {
69+ foreach ($ values as &$ value ) {
7270 $ value = $ this ->normalizeValue ($ value );
7371 }
7472
@@ -90,13 +88,17 @@ public function normalizeValue($value)
9088
9189 foreach ($ array as $ i => $ value ) {
9290 if ($ value instanceof NodeInterface) {
91+ $ uuid = $ value ->getIdentifier ();
9392 $ value = $ value ->getPath ();
93+ if ($ uuid ) {
94+ $ value .= ' ( ' . $ uuid . ') ' ;
95+ }
9496 } elseif (is_object ($ value )) {
9597 $ value = '<UNKNOWN OBJECT> ' ;
9698 } else {
9799 $ value = $ value ;
98100 }
99- $ value = '[ ' . $ i . '] ' . $ this ->textHelper ->truncate ($ value );
101+ $ value = '[ ' . $ i . '] ' . $ this ->textHelper ->truncate ($ value, 255 );
100102 $ values [] = $ value ;
101103 }
102104
@@ -112,10 +114,8 @@ public function normalizeValue($value)
112114
113115 public function formatValue (PropertyInterface $ value , $ showBinary = false )
114116 {
115- $ v = $ value ->getValue ();
116-
117- if (is_array ($ v )) {
118- return $ this ->normalizeValue ($ v );
117+ if (is_array ($ value ->getValue ())) {
118+ return $ this ->normalizeValue ($ value ->getValue ());
119119 }
120120
121121 switch (intval ($ value ->getType ())) {
0 commit comments