Browse Source

export renamed to view.

avkonst 11 years ago
parent
commit
9dcebf2564
25 changed files with 5034 additions and 16 deletions
  1. 10 10
      mainline/tests/general/test_basic.py
  2. 32 0
      mainline/tests/general/test_basic/test_help_view_default_stdout.gold.txt
  3. 0 0
      mainline/tests/general/test_basic/test_view_format_collect_default_stdout.gold.txt
  4. 0 0
      mainline/tests/general/test_basic/test_view_format_collect_nest_stdout.gold.txt
  5. 107 0
      mainline/tests/general/test_basic/test_view_format_view_nest_per_file_stdout.gold.txt
  6. 25 0
      mainline/tests/general/test_basic/test_view_format_view_nest_stdout.gold.txt
  7. 1 0
      mainline/tests/general/test_basic/test_view_format_view_python_stdout.gold.txt
  8. 35 0
      mainline/tests/general/test_basic/test_view_format_view_txt_stdout.gold.txt
  9. 22 0
      mainline/tests/general/test_basic/test_view_format_view_xml_stdout.gold.txt
  10. 3 0
      mainline/tests/general/test_basic/test_workflow_view_default_stderr.gold.txt
  11. 22 0
      mainline/tests/general/test_basic/test_workflow_view_default_stdout.gold.txt
  12. 3 0
      mainline/tests/general/test_basic/test_workflow_view_second_per_file_stderr.gold.txt
  13. 87 0
      mainline/tests/general/test_basic/test_workflow_view_second_per_file_stdout.gold.txt
  14. 3 0
      mainline/tests/general/test_basic/test_workflow_view_second_stderr.gold.txt
  15. 25 0
      mainline/tests/general/test_basic/test_workflow_view_second_stdout.gold.txt
  16. 2 2
      mainline/tests/general/test_std_code_cpp.py
  17. 23 0
      mainline/tests/general/test_std_code_cpp/test_parser_view_default_stdout.gold.txt
  18. 1515 0
      mainline/tests/general/test_std_code_cpp/test_parser_view_files_stdout.gold.txt
  19. 2 2
      mainline/tests/general/test_std_code_cs.py
  20. 27 0
      mainline/tests/general/test_std_code_cs/test_parser_view_default_stdout.gold.txt
  21. 861 0
      mainline/tests/general/test_std_code_cs/test_parser_view_files_stdout.gold.txt
  22. 2 2
      mainline/tests/general/test_std_code_java.py
  23. 26 0
      mainline/tests/general/test_std_code_java/test_parser_view_default_stdout.gold.txt
  24. 1957 0
      mainline/tests/general/test_std_code_java/test_parser_view_files_stdout.gold.txt
  25. 244 0
      mainline/tools/view.py

+ 10 - 10
mainline/tests/general/test_basic.py

@@ -34,7 +34,7 @@ class Test(tests.common.TestCase):
                                          save_prev=True)
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export',
+        runner = tests.common.ToolRunner('view',
                                          ['--general.log-level=INFO', '--general.format=xml'],
                                          check_stderr=[(0, -1)])
         self.assertExec(runner.run())
@@ -62,14 +62,14 @@ class Test(tests.common.TestCase):
                                          use_prev=True)
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export',
+        runner = tests.common.ToolRunner('view',
                                          ['--general.log-level=INFO', '--general.format=xml'],
                                          check_stderr=[(0, -1)],
                                          prefix='second',
                                          use_prev=True)
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export',
+        runner = tests.common.ToolRunner('view',
                                          ['--general.log-level=INFO', '--general.format=xml'],
                                          check_stderr=[(0, -1)],
                                          prefix='second_per_file',
@@ -138,7 +138,7 @@ class Test(tests.common.TestCase):
         runner = tests.common.ToolRunner('collect', ['--help'])
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export', ['--help'])
+        runner = tests.common.ToolRunner('view', ['--help'])
         self.assertExec(runner.run())
 
         runner = tests.common.ToolRunner('limit', ['--help'])
@@ -147,18 +147,18 @@ class Test(tests.common.TestCase):
         runner = tests.common.ToolRunner('info', ['--help'])
         self.assertExec(runner.run())
 
-    def test_export_format(self):
+    def test_view_format(self):
 
         runner = tests.common.ToolRunner('collect', ['--std.code.complexity.on'], save_prev=True)
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export', ['--general.format=txt'], prefix='txt')
+        runner = tests.common.ToolRunner('view', ['--general.format=txt'], prefix='txt')
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export', ['--general.format=python'], prefix='python')
+        runner = tests.common.ToolRunner('view', ['--general.format=python'], prefix='python')
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export', ['--general.format=xml'], prefix='xml')
+        runner = tests.common.ToolRunner('view', ['--general.format=xml'], prefix='xml')
         self.assertExec(runner.run())
         
         runner = tests.common.ToolRunner('collect',
@@ -168,13 +168,13 @@ class Test(tests.common.TestCase):
                                          use_prev=True)
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export',
+        runner = tests.common.ToolRunner('view',
                                          ['--general.nest-regions', '--general.format=xml'],
                                          prefix='nest',
                                          use_prev=True)
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export',
+        runner = tests.common.ToolRunner('view',
                                          ['--general.nest-regions', '--general.format=xml'],
                                          prefix='nest_per_file',
                                          dirs_list=['./simple.cpp'],

+ 32 - 0
mainline/tests/general/test_basic/test_help_view_default_stdout.gold.txt

@@ -0,0 +1,32 @@
+Usage: metrixpp.py export [options] -- [path 1] ... [path N]
+
+Options:
+  -h, --help            show this help message and exit
+  --general.log-level=GENERAL.LOG_LEVEL
+                        Defines log level. Possible values are
+                        'DEBUG','INFO','WARNING' or 'ERROR'. Default value is
+                        inherited from environment variable
+                        'METRIXPLUSPLUS_LOG_LEVEL' if set. [default: INFO]
+  --general.db-file=GENERAL.DB_FILE
+                        Primary database file to write (by the collector) and
+                        post-process (by other tools) [default: ./metrixpp.db]
+  --general.db-file-prev=GENERAL.DB_FILE_PREV
+                        Database file with data collected for the
+                        past/previous revision. If it is set for the collector
+                        tool to perform an incremental/iterative collection,
+                        it may reduce the processing time significantly. Post-
+                        processing tools use it in order to recognise/evaluate
+                        change trends. [default: none].
+  --general.format=GENERAL.FORMAT
+                        Format of the output data. Possible values are 'xml',
+                        'txt' or 'python' [default: xml]
+  --general.namespaces=GENERAL.NAMESPACES
+                        Allows to enumerate namespaces of interest. If not
+                        defined all namespaces available in database file will
+                        be processed. Separate several namespaces by comma,
+                        for example 'general,std.code.complexity' [default:
+                        none]
+  --general.nest-regions
+                        If the option is set (True), data for regions is
+                        exported in the form of a tree. Otherwise, all regions
+                        are exported in plain list. [default: False]

+ 0 - 0
mainline/tests/general/test_basic/test_view_format_collect_default_stdout.gold.txt


+ 0 - 0
mainline/tests/general/test_basic/test_view_format_collect_nest_stdout.gold.txt


+ 107 - 0
mainline/tests/general/test_basic/test_view_format_view_nest_per_file_stdout.gold.txt

@@ -0,0 +1,107 @@
+<export>
+
+    <data>
+        <info path="./simple.cpp" id="1" />
+        <file-data>
+            <regions>
+                <region>
+                    <info cursor="0" name="__global__" offset_end="639" line_begin="3" type="global" line_end="65" offset_begin="2" />
+                    <data />
+                    <subregions>
+                        <subregion>
+                            <info cursor="4" name="hmm" offset_end="638" line_begin="3" type="namespace" line_end="64" offset_begin="2" />
+                            <data />
+                            <subregions>
+                                <subregion>
+                                    <info cursor="7" name="A" offset_end="634" line_begin="7" type="class" line_end="62" offset_begin="76" />
+                                    <data />
+                                    <subregions>
+                                        <subregion>
+                                            <info cursor="10" name="A" offset_end="234" line_begin="10" type="function" line_end="21" offset_begin="88" />
+                                            <data>
+                                                <std.code.complexity cyclomatic="3">
+                                                    <__diff__ cyclomatic="0" />
+                                                </std.code.complexity>
+                                            </data>
+                                            <subregions>
+                                            </subregions>
+                                        </subregion>
+                                        <subregion>
+                                            <info cursor="23" name="func" offset_end="420" line_begin="23" type="function" line_end="39" offset_begin="237" />
+                                            <data>
+                                                <std.code.complexity cyclomatic="1">
+                                                    <__diff__ cyclomatic="0" />
+                                                </std.code.complexity>
+                                            </data>
+                                            <subregions>
+                                                <subregion>
+                                                    <info cursor="25" name="embeded" offset_end="406" line_begin="25" type="class" line_end="37" offset_begin="266" />
+                                                    <data />
+                                                    <subregions>
+                                                        <subregion>
+                                                            <info cursor="27" name="embeded" offset_end="402" line_begin="27" type="function" line_end="36" offset_begin="287" />
+                                                            <data>
+                                                                <std.code.complexity cyclomatic="2">
+                                                                    <__diff__ cyclomatic="1" />
+                                                                </std.code.complexity>
+                                                            </data>
+                                                            <subregions>
+                                                            </subregions>
+                                                        </subregion>
+                                                    </subregions>
+                                                </subregion>
+                                            </subregions>
+                                        </subregion>
+                                        <subregion>
+                                            <info cursor="41" name="never" offset_end="514" line_begin="41" type="function" line_end="48" offset_begin="423" />
+                                            <data>
+                                                <std.code.complexity cyclomatic="1">
+                                                    <__diff__ cyclomatic="0" />
+                                                </std.code.complexity>
+                                            </data>
+                                            <subregions>
+                                            </subregions>
+                                        </subregion>
+                                        <subregion>
+                                            <info cursor="50" name="new_func" offset_end="550" line_begin="50" type="function" line_end="53" offset_begin="517" />
+                                            <data>
+                                                <std.code.complexity cyclomatic="0" />
+                                            </data>
+                                            <subregions>
+                                            </subregions>
+                                        </subregion>
+                                        <subregion>
+                                            <info cursor="55" name="new_func_complex" offset_end="611" line_begin="55" type="function" line_end="59" offset_begin="553" />
+                                            <data>
+                                                <std.code.complexity cyclomatic="1" />
+                                            </data>
+                                            <subregions>
+                                            </subregions>
+                                        </subregion>
+                                    </subregions>
+                                </subregion>
+                            </subregions>
+                        </subregion>
+                    </subregions>
+                </region>
+            </regions>
+        </file-data>
+        <subfiles>
+        </subfiles>
+        <subdirs>
+        </subdirs>
+        <aggregated-data>
+            <std.code.complexity>
+                <cyclomatic count="6" max="3" avg="1.33333333333" total="8.0" min="0">
+                    <distribution-bars>
+                        <distribution-bar count="1" __diff__="0" metric="0" />
+                        <distribution-bar count="3" __diff__="0" metric="1" />
+                        <distribution-bar count="1" __diff__="0" metric="2" />
+                        <distribution-bar count="1" __diff__="0" metric="3" />
+                    </distribution-bars>
+                    <__diff__ count="2" max="0" avg="-0.166666666667" total="2.0" min="-1" />
+                </cyclomatic>
+            </std.code.complexity>
+        </aggregated-data>
+    </data>
+</export>

+ 25 - 0
mainline/tests/general/test_basic/test_view_format_view_nest_stdout.gold.txt

@@ -0,0 +1,25 @@
+<export>
+
+    <data>
+        <info path="" id="1" />
+        <file-data />
+        <subfiles>
+        </subfiles>
+        <subdirs>
+            <subdir>.</subdir>
+        </subdirs>
+        <aggregated-data>
+            <std.code.complexity>
+                <cyclomatic count="7" max="3" avg="1.57142857143" total="11.0" min="0">
+                    <distribution-bars>
+                        <distribution-bar count="1" __diff__="0" metric="0" />
+                        <distribution-bar count="3" __diff__="0" metric="1" />
+                        <distribution-bar count="1" __diff__="0" metric="2" />
+                        <distribution-bar count="2" __diff__="1" metric="3" />
+                    </distribution-bars>
+                    <__diff__ count="3" max="0" avg="0.0714285714286" total="5.0" min="-1" />
+                </cyclomatic>
+            </std.code.complexity>
+        </aggregated-data>
+    </data>
+</export>

+ 1 - 0
mainline/tests/general/test_basic/test_view_format_view_python_stdout.gold.txt

@@ -0,0 +1 @@
+{'export': [{'data: {'info': {'path': '', 'id': 1}, 'file-data': {}, 'subfiles': [], 'subdirs': [u'.'], 'aggregated-data': {'std.code.complexity': {'cyclomatic': {'count': 4, 'distribution-bars': [{'count': 3, 'metric': 1, 'ratio': 0.75}, {'count': 1, 'metric': 3, 'ratio': 0.25}], 'avg': 1.5, 'min': 1, 'max': 3, 'total': 6.0}}}}}]}

+ 35 - 0
mainline/tests/general/test_basic/test_view_format_view_txt_stdout.gold.txt

@@ -0,0 +1,35 @@
+================================================================================
+Export
+________________________________________________________________________________
+
+--------------------------------------------------------------------------------
+data:  
+.   info: 
+.   .   path=""
+.   .   id="1"
+.   file-data: 
+.   subfiles:
+.   subdirs:
+.   .   .
+.   aggregated-data:  
+.   .   std.code.complexity:  
+.   .   .   cyclomatic: 
+.   .   .   .   count="4"
+.   .   .   .   max="3"
+.   .   .   .   avg="1.5"
+.   .   .   .   total="6.0"
+.   .   .   .   min="1" 
+.   .   .   .   distribution-bars:
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="3"
+.   .   .   .   .   .   metric="1"
+.   .   .   .   .   .   ratio="0.75"
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="1"
+.   .   .   .   .   .   metric="3"
+.   .   .   .   .   .   ratio="0.25"
+================================================================================
+
+

+ 22 - 0
mainline/tests/general/test_basic/test_view_format_view_xml_stdout.gold.txt

@@ -0,0 +1,22 @@
+<export>
+
+    <data>
+        <info path="" id="1" />
+        <file-data />
+        <subfiles>
+        </subfiles>
+        <subdirs>
+            <subdir>.</subdir>
+        </subdirs>
+        <aggregated-data>
+            <std.code.complexity>
+                <cyclomatic count="4" max="3" avg="1.5" total="6.0" min="1">
+                    <distribution-bars>
+                        <distribution-bar count="3" metric="1" ratio="0.75" />
+                        <distribution-bar count="1" metric="3" ratio="0.25" />
+                    </distribution-bars>
+                </cyclomatic>
+            </std.code.complexity>
+        </aggregated-data>
+    </data>
+</export>

+ 3 - 0
mainline/tests/general/test_basic/test_workflow_view_default_stderr.gold.txt

@@ -0,0 +1,3 @@
+[LOG]: WARNING:	Logging enabled with INFO level
+[LOG]: INFO:	Processing: 
+[LOG]: WARNING:	Exit code: 0. Time spent: 1 seconds. Done

+ 22 - 0
mainline/tests/general/test_basic/test_workflow_view_default_stdout.gold.txt

@@ -0,0 +1,22 @@
+<export>
+
+    <data>
+        <info path="" id="1" />
+        <file-data />
+        <subfiles>
+        </subfiles>
+        <subdirs>
+            <subdir>.</subdir>
+        </subdirs>
+        <aggregated-data>
+            <std.code.complexity>
+                <cyclomatic count="4" max="3" avg="1.5" total="6.0" min="1">
+                    <distribution-bars>
+                        <distribution-bar count="3" metric="1" ratio="0.75" />
+                        <distribution-bar count="1" metric="3" ratio="0.25" />
+                    </distribution-bars>
+                </cyclomatic>
+            </std.code.complexity>
+        </aggregated-data>
+    </data>
+</export>

+ 3 - 0
mainline/tests/general/test_basic/test_workflow_view_second_per_file_stderr.gold.txt

@@ -0,0 +1,3 @@
+[LOG]: WARNING:	Logging enabled with INFO level
+[LOG]: INFO:	Processing: ./simple.cpp
+[LOG]: WARNING:	Exit code: 0. Time spent: 1 seconds. Done

+ 87 - 0
mainline/tests/general/test_basic/test_workflow_view_second_per_file_stdout.gold.txt

@@ -0,0 +1,87 @@
+<export>
+
+    <data>
+        <info path="./simple.cpp" id="1" />
+        <file-data>
+            <regions>
+                <region>
+                    <info cursor="0" name="__global__" offset_end="639" line_begin="3" type="global" line_end="65" offset_begin="2" />
+                    <data />
+                </region>
+                <region>
+                    <info cursor="4" name="hmm" offset_end="638" line_begin="3" type="namespace" line_end="64" offset_begin="2" />
+                    <data />
+                </region>
+                <region>
+                    <info cursor="7" name="A" offset_end="634" line_begin="7" type="class" line_end="62" offset_begin="76" />
+                    <data />
+                </region>
+                <region>
+                    <info cursor="10" name="A" offset_end="234" line_begin="10" type="function" line_end="21" offset_begin="88" />
+                    <data>
+                        <std.code.complexity cyclomatic="3">
+                            <__diff__ cyclomatic="0" />
+                        </std.code.complexity>
+                    </data>
+                </region>
+                <region>
+                    <info cursor="23" name="func" offset_end="420" line_begin="23" type="function" line_end="39" offset_begin="237" />
+                    <data>
+                        <std.code.complexity cyclomatic="1">
+                            <__diff__ cyclomatic="0" />
+                        </std.code.complexity>
+                    </data>
+                </region>
+                <region>
+                    <info cursor="25" name="embeded" offset_end="406" line_begin="25" type="class" line_end="37" offset_begin="266" />
+                    <data />
+                </region>
+                <region>
+                    <info cursor="27" name="embeded" offset_end="402" line_begin="27" type="function" line_end="36" offset_begin="287" />
+                    <data>
+                        <std.code.complexity cyclomatic="2">
+                            <__diff__ cyclomatic="1" />
+                        </std.code.complexity>
+                    </data>
+                </region>
+                <region>
+                    <info cursor="41" name="never" offset_end="514" line_begin="41" type="function" line_end="48" offset_begin="423" />
+                    <data>
+                        <std.code.complexity cyclomatic="1">
+                            <__diff__ cyclomatic="0" />
+                        </std.code.complexity>
+                    </data>
+                </region>
+                <region>
+                    <info cursor="50" name="new_func" offset_end="550" line_begin="50" type="function" line_end="53" offset_begin="517" />
+                    <data>
+                        <std.code.complexity cyclomatic="0" />
+                    </data>
+                </region>
+                <region>
+                    <info cursor="55" name="new_func_complex" offset_end="611" line_begin="55" type="function" line_end="59" offset_begin="553" />
+                    <data>
+                        <std.code.complexity cyclomatic="1" />
+                    </data>
+                </region>
+            </regions>
+        </file-data>
+        <subfiles>
+        </subfiles>
+        <subdirs>
+        </subdirs>
+        <aggregated-data>
+            <std.code.complexity>
+                <cyclomatic count="6" max="3" avg="1.33333333333" total="8.0" min="0">
+                    <distribution-bars>
+                        <distribution-bar count="1" __diff__="0" metric="0" />
+                        <distribution-bar count="3" __diff__="0" metric="1" />
+                        <distribution-bar count="1" __diff__="0" metric="2" />
+                        <distribution-bar count="1" __diff__="0" metric="3" />
+                    </distribution-bars>
+                    <__diff__ count="2" max="0" avg="-0.166666666667" total="2.0" min="-1" />
+                </cyclomatic>
+            </std.code.complexity>
+        </aggregated-data>
+    </data>
+</export>

+ 3 - 0
mainline/tests/general/test_basic/test_workflow_view_second_stderr.gold.txt

@@ -0,0 +1,3 @@
+[LOG]: WARNING:	Logging enabled with INFO level
+[LOG]: INFO:	Processing: 
+[LOG]: WARNING:	Exit code: 0. Time spent: 1 seconds. Done

+ 25 - 0
mainline/tests/general/test_basic/test_workflow_view_second_stdout.gold.txt

@@ -0,0 +1,25 @@
+<export>
+
+    <data>
+        <info path="" id="1" />
+        <file-data />
+        <subfiles>
+        </subfiles>
+        <subdirs>
+            <subdir>.</subdir>
+        </subdirs>
+        <aggregated-data>
+            <std.code.complexity>
+                <cyclomatic count="7" max="3" avg="1.57142857143" total="11.0" min="0">
+                    <distribution-bars>
+                        <distribution-bar count="1" __diff__="0" metric="0" />
+                        <distribution-bar count="3" __diff__="0" metric="1" />
+                        <distribution-bar count="1" __diff__="0" metric="2" />
+                        <distribution-bar count="2" __diff__="1" metric="3" />
+                    </distribution-bars>
+                    <__diff__ count="3" max="0" avg="0.0714285714286" total="5.0" min="-1" />
+                </cyclomatic>
+            </std.code.complexity>
+        </aggregated-data>
+    </data>
+</export>

+ 2 - 2
mainline/tests/general/test_std_code_cpp.py

@@ -30,11 +30,11 @@ class Test(tests.common.TestCase):
         runner = tests.common.ToolRunner('collect', ['--std.code.complexity.on'])
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export')
+        runner = tests.common.ToolRunner('view')
         self.assertExec(runner.run())
         
         dirs_list = [os.path.join('.', each) for each in os.listdir(self.get_content_paths().cwd)]
-        runner = tests.common.ToolRunner('export', opts_list=['--general.format=txt'], dirs_list=dirs_list, prefix='files')
+        runner = tests.common.ToolRunner('view', opts_list=['--general.format=txt'], dirs_list=dirs_list, prefix='files')
         self.assertExec(runner.run())
 
         runner = tests.common.ToolRunner('limit',

+ 23 - 0
mainline/tests/general/test_std_code_cpp/test_parser_view_default_stdout.gold.txt

@@ -0,0 +1,23 @@
+<export>
+
+    <data>
+        <info path="" id="1" />
+        <file-data />
+        <subfiles>
+        </subfiles>
+        <subdirs>
+            <subdir>.</subdir>
+        </subdirs>
+        <aggregated-data>
+            <std.code.complexity>
+                <cyclomatic count="86" max="2" avg="0.197674418605" total="17.0" min="0">
+                    <distribution-bars>
+                        <distribution-bar count="74" metric="0" ratio="0.8605" />
+                        <distribution-bar count="7" metric="1" ratio="0.0814" />
+                        <distribution-bar count="5" metric="2" ratio="0.0581" />
+                    </distribution-bars>
+                </cyclomatic>
+            </std.code.complexity>
+        </aggregated-data>
+    </data>
+</export>

File diff suppressed because it is too large
+ 1515 - 0
mainline/tests/general/test_std_code_cpp/test_parser_view_files_stdout.gold.txt


+ 2 - 2
mainline/tests/general/test_std_code_cs.py

@@ -30,11 +30,11 @@ class Test(tests.common.TestCase):
         runner = tests.common.ToolRunner('collect', ['--std.code.complexity.on'])
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export', ['--general.nest-regions', '--general.format=xml'])
+        runner = tests.common.ToolRunner('view', ['--general.nest-regions', '--general.format=xml'])
         self.assertExec(runner.run())
 
         dirs_list = [os.path.join('.', each) for each in os.listdir(self.get_content_paths().cwd)]
-        runner = tests.common.ToolRunner('export',
+        runner = tests.common.ToolRunner('view',
                                          opts_list=['--general.nest-regions', '--general.format=txt'],
                                          dirs_list=dirs_list,
                                          prefix='files')

+ 27 - 0
mainline/tests/general/test_std_code_cs/test_parser_view_default_stdout.gold.txt

@@ -0,0 +1,27 @@
+<export>
+
+    <data>
+        <info path="" id="1" />
+        <file-data />
+        <subfiles>
+        </subfiles>
+        <subdirs>
+            <subdir>.</subdir>
+        </subdirs>
+        <aggregated-data>
+            <std.code.complexity>
+                <cyclomatic count="39" max="6" avg="1.15384615385" total="45.0" min="0">
+                    <distribution-bars>
+                        <distribution-bar count="23" metric="0" ratio="0.5897" />
+                        <distribution-bar count="7" metric="1" ratio="0.1795" />
+                        <distribution-bar count="1" metric="2" ratio="0.0256" />
+                        <distribution-bar count="1" metric="3" ratio="0.0256" />
+                        <distribution-bar count="3" metric="4" ratio="0.0769" />
+                        <distribution-bar count="3" metric="5" ratio="0.0769" />
+                        <distribution-bar count="1" metric="6" ratio="0.0256" />
+                    </distribution-bars>
+                </cyclomatic>
+            </std.code.complexity>
+        </aggregated-data>
+    </data>
+</export>

+ 861 - 0
mainline/tests/general/test_std_code_cs/test_parser_view_files_stdout.gold.txt

@@ -0,0 +1,861 @@
+================================================================================
+Export
+________________________________________________________________________________
+
+--------------------------------------------------------------------------------
+data:  
+.   info: 
+.   .   path=".\File.cs"
+.   .   id="1"
+.   file-data:  
+.   .   regions:
+.   .   
+.   .   .   region:  
+.   .   .   .   info: 
+.   .   .   .   .   cursor="0"
+.   .   .   .   .   name="__global__"
+.   .   .   .   .   offset_end="9141"
+.   .   .   .   .   line_begin="1"
+.   .   .   .   .   type="global"
+.   .   .   .   .   line_end="448"
+.   .   .   .   .   offset_begin="0"
+.   .   .   .   data: 
+.   .   .   .   subregions:
+.   .   .   .   
+.   .   .   .   .   subregion:  
+.   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   cursor="21"
+.   .   .   .   .   .   .   name="Microsoft.VisualBasic"
+.   .   .   .   .   .   .   offset_end="9104"
+.   .   .   .   .   .   .   line_begin="21"
+.   .   .   .   .   .   .   type="namespace"
+.   .   .   .   .   .   .   line_end="447"
+.   .   .   .   .   .   .   offset_begin="855"
+.   .   .   .   .   .   data: 
+.   .   .   .   .   .   subregions:
+.   .   .   .   .   .   
+.   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   cursor="30"
+.   .   .   .   .   .   .   .   .   name="File"
+.   .   .   .   .   .   .   .   .   offset_end="9037"
+.   .   .   .   .   .   .   .   .   line_begin="30"
+.   .   .   .   .   .   .   .   .   type="class"
+.   .   .   .   .   .   .   .   .   line_end="437"
+.   .   .   .   .   .   .   .   .   offset_begin="1012"
+.   .   .   .   .   .   .   .   data: 
+.   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="74"
+.   .   .   .   .   .   .   .   .   .   .   name="get"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="2222"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="74"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="89"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="1961"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="3"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="95"
+.   .   .   .   .   .   .   .   .   .   .   name="get"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="2781"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="95"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="114"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="2295"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="2"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="120"
+.   .   .   .   .   .   .   .   .   .   .   name="get"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="3022"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="120"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="128"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="2888"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="1"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="134"
+.   .   .   .   .   .   .   .   .   .   .   name="get"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="3263"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="134"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="142"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="3129"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="1"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="148"
+.   .   .   .   .   .   .   .   .   .   .   name="get"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="3489"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="148"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="156"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="3355"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="1"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="160"
+.   .   .   .   .   .   .   .   .   .   .   name="Close"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="4076"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="159"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="187"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="3497"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="4"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="190"
+.   .   .   .   .   .   .   .   .   .   .   name="SetRecord"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="4794"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="189"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="226"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="4079"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="6"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="229"
+.   .   .   .   .   .   .   .   .   .   .   name="FileTable"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="5103"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="228"
+.   .   .   .   .   .   .   .   .   .   .   type="class"
+.   .   .   .   .   .   .   .   .   .   .   line_end="242"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="4797"
+.   .   .   .   .   .   .   .   .   .   data: 
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   .   .   cursor="235"
+.   .   .   .   .   .   .   .   .   .   .   .   .   name="FileTable"
+.   .   .   .   .   .   .   .   .   .   .   .   .   offset_end="5099"
+.   .   .   .   .   .   .   .   .   .   .   .   .   line_begin="235"
+.   .   .   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   .   .   line_end="240"
+.   .   .   .   .   .   .   .   .   .   .   .   .   offset_begin="4943"
+.   .   .   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="245"
+.   .   .   .   .   .   .   .   .   .   .   name="GetFile"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="5822"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="244"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="274"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="5126"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="5"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="277"
+.   .   .   .   .   .   .   .   .   .   .   name="GetFile"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="6140"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="276"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="285"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="5825"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="1"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="288"
+.   .   .   .   .   .   .   .   .   .   .   name="AllocateFile"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="7049"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="287"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="324"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="6143"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="5"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="327"
+.   .   .   .   .   .   .   .   .   .   .   name="FindFreeFile"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="7735"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="326"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="358"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="7052"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="5"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="361"
+.   .   .   .   .   .   .   .   .   .   .   name="CloseAll"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="8342"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="360"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="387"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="7738"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="4"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="391"
+.   .   .   .   .   .   .   .   .   .   .   name="Write"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="8437"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="389"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="394"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="8345"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="398"
+.   .   .   .   .   .   .   .   .   .   .   name="WriteLine"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="8541"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="396"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="401"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="8440"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="405"
+.   .   .   .   .   .   .   .   .   .   .   name="Tab"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="8631"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="403"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="408"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="8544"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="412"
+.   .   .   .   .   .   .   .   .   .   .   name="Space"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="8726"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="410"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="415"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="8634"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="419"
+.   .   .   .   .   .   .   .   .   .   .   name="Lock"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="8839"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="417"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="422"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="8729"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="426"
+.   .   .   .   .   .   .   .   .   .   .   name="Unlock"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="9034"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="424"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="435"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="8842"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="1"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   subfiles:
+.   subdirs:
+.   aggregated-data:  
+.   .   std.code.complexity:  
+.   .   .   cyclomatic: 
+.   .   .   .   count="19"
+.   .   .   .   max="6"
+.   .   .   .   avg="2.05263157895"
+.   .   .   .   total="39.0"
+.   .   .   .   min="0" 
+.   .   .   .   distribution-bars:
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="6"
+.   .   .   .   .   .   metric="0"
+.   .   .   .   .   .   ratio="0.3158"
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="5"
+.   .   .   .   .   .   metric="1"
+.   .   .   .   .   .   ratio="0.2632"
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="1"
+.   .   .   .   .   .   metric="2"
+.   .   .   .   .   .   ratio="0.0526"
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="1"
+.   .   .   .   .   .   metric="3"
+.   .   .   .   .   .   ratio="0.0526"
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="2"
+.   .   .   .   .   .   metric="4"
+.   .   .   .   .   .   ratio="0.1053"
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="3"
+.   .   .   .   .   .   metric="5"
+.   .   .   .   .   .   ratio="0.1579"
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="1"
+.   .   .   .   .   .   metric="6"
+.   .   .   .   .   .   ratio="0.0526"
+================================================================================
+--------------------------------------------------------------------------------
+data:  
+.   info: 
+.   .   path=".\Generics.cs"
+.   .   id="2"
+.   file-data:  
+.   .   regions:
+.   .   
+.   .   .   region:  
+.   .   .   .   info: 
+.   .   .   .   .   cursor="0"
+.   .   .   .   .   name="__global__"
+.   .   .   .   .   offset_end="3134"
+.   .   .   .   .   line_begin="1"
+.   .   .   .   .   type="global"
+.   .   .   .   .   line_end="106"
+.   .   .   .   .   offset_begin="0"
+.   .   .   .   data: 
+.   .   .   .   subregions:
+.   .   .   .   
+.   .   .   .   .   subregion:  
+.   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   cursor="22"
+.   .   .   .   .   .   .   name="Generics"
+.   .   .   .   .   .   .   offset_end="3133"
+.   .   .   .   .   .   .   line_begin="22"
+.   .   .   .   .   .   .   type="class"
+.   .   .   .   .   .   .   line_end="105"
+.   .   .   .   .   .   .   offset_begin="1182"
+.   .   .   .   .   .   data: 
+.   .   .   .   .   .   subregions:
+.   .   .   .   .   .   
+.   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   cursor="24"
+.   .   .   .   .   .   .   .   .   name="MyArray"
+.   .   .   .   .   .   .   .   .   offset_end="1664"
+.   .   .   .   .   .   .   .   .   line_begin="24"
+.   .   .   .   .   .   .   .   .   type="class"
+.   .   .   .   .   .   .   .   .   line_end="57"
+.   .   .   .   .   .   .   .   .   offset_begin="1214"
+.   .   .   .   .   .   .   .   data: 
+.   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="26"
+.   .   .   .   .   .   .   .   .   .   .   name="NestedClass"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="1316"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="26"
+.   .   .   .   .   .   .   .   .   .   .   type="class"
+.   .   .   .   .   .   .   .   .   .   .   line_end="30"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="1243"
+.   .   .   .   .   .   .   .   .   .   data: 
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="40"
+.   .   .   .   .   .   .   .   .   .   .   name="MyArray"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="1458"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="40"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="43"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="1391"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="45"
+.   .   .   .   .   .   .   .   .   .   .   name="Size"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="1546"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="45"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="48"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="1464"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="50"
+.   .   .   .   .   .   .   .   .   .   .   name="Grow"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="1661"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="50"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="56"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="1552"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="1"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   
+.   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   cursor="59"
+.   .   .   .   .   .   .   .   .   name="IInterface"
+.   .   .   .   .   .   .   .   .   offset_end="1775"
+.   .   .   .   .   .   .   .   .   line_begin="59"
+.   .   .   .   .   .   .   .   .   type="interface"
+.   .   .   .   .   .   .   .   .   line_end="63"
+.   .   .   .   .   .   .   .   .   offset_begin="1668"
+.   .   .   .   .   .   .   .   data: 
+.   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   
+.   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   cursor="65"
+.   .   .   .   .   .   .   .   .   name="Base"
+.   .   .   .   .   .   .   .   .   offset_end="2084"
+.   .   .   .   .   .   .   .   .   line_begin="65"
+.   .   .   .   .   .   .   .   .   type="class"
+.   .   .   .   .   .   .   .   .   line_end="74"
+.   .   .   .   .   .   .   .   .   offset_begin="1779"
+.   .   .   .   .   .   .   .   data: 
+.   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="71"
+.   .   .   .   .   .   .   .   .   .   .   name="Generics.IInterface.Method2"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="2081"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="70"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="73"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="1960"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   
+.   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   cursor="76"
+.   .   .   .   .   .   .   .   .   name="Derived"
+.   .   .   .   .   .   .   .   .   offset_end="2245"
+.   .   .   .   .   .   .   .   .   line_begin="76"
+.   .   .   .   .   .   .   .   .   type="class"
+.   .   .   .   .   .   .   .   .   line_end="82"
+.   .   .   .   .   .   .   .   .   offset_begin="2088"
+.   .   .   .   .   .   .   .   data: 
+.   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="79"
+.   .   .   .   .   .   .   .   .   .   .   name="Method1"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="2242"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="78"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="81"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="2130"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   
+.   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   cursor="92"
+.   .   .   .   .   .   .   .   .   name="MethodWithConstraint"
+.   .   .   .   .   .   .   .   .   offset_end="2798"
+.   .   .   .   .   .   .   .   .   line_begin="92"
+.   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   line_end="94"
+.   .   .   .   .   .   .   .   .   offset_begin="2698"
+.   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   
+.   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   cursor="96"
+.   .   .   .   .   .   .   .   .   name="MethodWithStructConstraint"
+.   .   .   .   .   .   .   .   .   offset_end="2875"
+.   .   .   .   .   .   .   .   .   line_begin="96"
+.   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   line_end="98"
+.   .   .   .   .   .   .   .   .   offset_begin="2802"
+.   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   
+.   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   cursor="100"
+.   .   .   .   .   .   .   .   .   name="Dictionary"
+.   .   .   .   .   .   .   .   .   offset_end="3131"
+.   .   .   .   .   .   .   .   .   line_begin="100"
+.   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   line_end="104"
+.   .   .   .   .   .   .   .   .   offset_begin="2879"
+.   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   subregions:
+.   subfiles:
+.   subdirs:
+.   aggregated-data:  
+.   .   std.code.complexity:  
+.   .   .   cyclomatic: 
+.   .   .   .   count="8"
+.   .   .   .   max="1"
+.   .   .   .   avg="0.125"
+.   .   .   .   total="1.0"
+.   .   .   .   min="0" 
+.   .   .   .   distribution-bars:
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="7"
+.   .   .   .   .   .   metric="0"
+.   .   .   .   .   .   ratio="0.875"
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="1"
+.   .   .   .   .   .   metric="1"
+.   .   .   .   .   .   ratio="0.125"
+================================================================================
+--------------------------------------------------------------------------------
+data:  
+.   info: 
+.   .   path=".\interface.cs"
+.   .   id="3"
+.   file-data:  
+.   .   regions:
+.   .   
+.   .   .   region:  
+.   .   .   .   info: 
+.   .   .   .   .   cursor="0"
+.   .   .   .   .   name="__global__"
+.   .   .   .   .   offset_end="6584"
+.   .   .   .   .   line_begin="1"
+.   .   .   .   .   type="global"
+.   .   .   .   .   line_end="219"
+.   .   .   .   .   offset_begin="0"
+.   .   .   .   data: 
+.   .   .   .   subregions:
+.   .   .   .   
+.   .   .   .   .   subregion:  
+.   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   cursor="22"
+.   .   .   .   .   .   .   name="System.Runtime.Serialization"
+.   .   .   .   .   .   .   offset_end="1139"
+.   .   .   .   .   .   .   line_begin="22"
+.   .   .   .   .   .   .   type="namespace"
+.   .   .   .   .   .   .   line_end="37"
+.   .   .   .   .   .   .   offset_begin="918"
+.   .   .   .   .   .   data: 
+.   .   .   .   .   .   subregions:
+.   .   .   .   .   .   
+.   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   cursor="30"
+.   .   .   .   .   .   .   .   .   name="IDeserializationCallback"
+.   .   .   .   .   .   .   .   .   offset_end="1097"
+.   .   .   .   .   .   .   .   .   line_begin="25"
+.   .   .   .   .   .   .   .   .   type="interface"
+.   .   .   .   .   .   .   .   .   line_end="35"
+.   .   .   .   .   .   .   .   .   offset_begin="960"
+.   .   .   .   .   .   .   .   data: 
+.   .   .   .   .   .   .   .   subregions:
+.   .   .   .   
+.   .   .   .   .   subregion:  
+.   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   cursor="61"
+.   .   .   .   .   .   .   name="System.Globalization"
+.   .   .   .   .   .   .   offset_end="6548"
+.   .   .   .   .   .   .   line_begin="61"
+.   .   .   .   .   .   .   type="namespace"
+.   .   .   .   .   .   .   line_end="218"
+.   .   .   .   .   .   .   offset_begin="2040"
+.   .   .   .   .   .   data: 
+.   .   .   .   .   .   subregions:
+.   .   .   .   .   .   
+.   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   cursor="69"
+.   .   .   .   .   .   .   .   .   name="TextInfo"
+.   .   .   .   .   .   .   .   .   offset_end="6526"
+.   .   .   .   .   .   .   .   .   line_begin="69"
+.   .   .   .   .   .   .   .   .   type="class"
+.   .   .   .   .   .   .   .   .   line_end="216"
+.   .   .   .   .   .   .   .   .   offset_begin="2183"
+.   .   .   .   .   .   .   .   data: 
+.   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="80"
+.   .   .   .   .   .   .   .   .   .   .   name="TextInfo"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="2687"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="75"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="83"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="2288"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="88"
+.   .   .   .   .   .   .   .   .   .   .   name="get"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="2940"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="88"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="92"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="2802"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="98"
+.   .   .   .   .   .   .   .   .   .   .   name="get"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="3209"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="98"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="102"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="3073"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="108"
+.   .   .   .   .   .   .   .   .   .   .   name="get"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="3475"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="108"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="112"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="3336"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="118"
+.   .   .   .   .   .   .   .   .   .   .   name="get"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="3739"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="118"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="122"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="3602"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="128"
+.   .   .   .   .   .   .   .   .   .   .   name="get"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="3934"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="128"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="131"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="3863"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="135"
+.   .   .   .   .   .   .   .   .   .   .   name="Equals"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="4348"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="134"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="146"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="3954"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="1"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="149"
+.   .   .   .   .   .   .   .   .   .   .   name="GetHashCode"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="4489"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="148"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="152"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="4354"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="169"
+.   .   .   .   .   .   .   .   .   .   .   name="ToTitleCase"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="5940"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="168"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="195"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="5003"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="4"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="198"
+.   .   .   .   .   .   .   .   .   .   .   name="I.Deserialization.Callback.OnDeserialization"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="6128"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="197"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="201"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="5946"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="204"
+.   .   .   .   .   .   .   .   .   .   .   name="ToString"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="6296"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="203"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="207"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="6134"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   .   .   .   .   .   .   .   
+.   .   .   .   .   .   .   .   .   subregion:  
+.   .   .   .   .   .   .   .   .   .   info: 
+.   .   .   .   .   .   .   .   .   .   .   cursor="211"
+.   .   .   .   .   .   .   .   .   .   .   name="IDeserializationCallback.OnDeserialization"
+.   .   .   .   .   .   .   .   .   .   .   offset_end="6523"
+.   .   .   .   .   .   .   .   .   .   .   line_begin="209"
+.   .   .   .   .   .   .   .   .   .   .   type="function"
+.   .   .   .   .   .   .   .   .   .   .   line_end="214"
+.   .   .   .   .   .   .   .   .   .   .   offset_begin="6302"
+.   .   .   .   .   .   .   .   .   .   data:  
+.   .   .   .   .   .   .   .   .   .   .   std.code.complexity: 
+.   .   .   .   .   .   .   .   .   .   .   .   cyclomatic="0"
+.   .   .   .   .   .   .   .   .   .   subregions:
+.   subfiles:
+.   subdirs:
+.   aggregated-data:  
+.   .   std.code.complexity:  
+.   .   .   cyclomatic: 
+.   .   .   .   count="12"
+.   .   .   .   max="4"
+.   .   .   .   avg="0.416666666667"
+.   .   .   .   total="5.0"
+.   .   .   .   min="0" 
+.   .   .   .   distribution-bars:
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="10"
+.   .   .   .   .   .   metric="0"
+.   .   .   .   .   .   ratio="0.8333"
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="1"
+.   .   .   .   .   .   metric="1"
+.   .   .   .   .   .   ratio="0.0833"
+.   .   .   .   
+.   .   .   .   .   distribution-bar: 
+.   .   .   .   .   .   count="1"
+.   .   .   .   .   .   metric="4"
+.   .   .   .   .   .   ratio="0.0833"
+================================================================================
+
+

+ 2 - 2
mainline/tests/general/test_std_code_java.py

@@ -30,11 +30,11 @@ class Test(tests.common.TestCase):
         runner = tests.common.ToolRunner('collect', ['--std.code.complexity.on'])
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('export', ['--general.nest-regions', '--general.format=xml'])
+        runner = tests.common.ToolRunner('view', ['--general.nest-regions', '--general.format=xml'])
         self.assertExec(runner.run())
 
         dirs_list = [os.path.join('.', each) for each in os.listdir(self.get_content_paths().cwd)]
-        runner = tests.common.ToolRunner('export',
+        runner = tests.common.ToolRunner('view',
                                          opts_list=['--general.nest-regions', '--general.format=txt'],
                                          dirs_list=dirs_list,
                                          prefix='files')

+ 26 - 0
mainline/tests/general/test_std_code_java/test_parser_view_default_stdout.gold.txt

@@ -0,0 +1,26 @@
+<export>
+
+    <data>
+        <info path="" id="1" />
+        <file-data />
+        <subfiles>
+        </subfiles>
+        <subdirs>
+            <subdir>.</subdir>
+        </subdirs>
+        <aggregated-data>
+            <std.code.complexity>
+                <cyclomatic count="119" max="6" avg="1.05882352941" total="126.0" min="0">
+                    <distribution-bars>
+                        <distribution-bar count="58" metric="0" ratio="0.4874" />
+                        <distribution-bar count="31" metric="1" ratio="0.2605" />
+                        <distribution-bar count="15" metric="2" ratio="0.1261" />
+                        <distribution-bar count="8" metric="3" ratio="0.0672" />
+                        <distribution-bar count="1" metric="5" ratio="0.0084" />
+                        <distribution-bar count="6" metric="6" ratio="0.0504" />
+                    </distribution-bars>
+                </cyclomatic>
+            </std.code.complexity>
+        </aggregated-data>
+    </data>
+</export>

File diff suppressed because it is too large
+ 1957 - 0
mainline/tests/general/test_std_code_java/test_parser_view_files_stdout.gold.txt


+ 244 - 0
mainline/tools/view.py

@@ -0,0 +1,244 @@
+#
+#    Metrix++, Copyright 2009-2013, Metrix++ Project
+#    Link: http://metrixplusplus.sourceforge.net
+#    
+#    This file is a part of Metrix++ Tool.
+#    
+#    Metrix++ is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation, version 3 of the License.
+#    
+#    Metrix++ is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+#    GNU General Public License for more details.
+#    
+#    You should have received a copy of the GNU General Public License
+#    along with Metrix++.  If not, see <http://www.gnu.org/licenses/>.
+#
+
+
+
+import logging
+import re
+
+import core.log
+import core.db.loader
+import core.db.post
+import core.db.utils
+import core.cmdparser
+import core.export.convert
+
+import core.api
+class Tool(core.api.ITool):
+    def run(self, tool_args):
+        return main(tool_args)
+
+def main(tool_args):
+    
+    log_plugin = core.log.Plugin()
+    db_plugin = core.db.post.Plugin()
+
+    parser = core.cmdparser.MultiOptionParser(usage="Usage: %prog export [options] -- [path 1] ... [path N]")
+    log_plugin.declare_configuration(parser)
+    db_plugin.declare_configuration(parser)
+    parser.add_option("--general.format", default='xml', choices=['txt', 'xml', 'python'], help="Format of the output data. "
+                      "Possible values are 'xml', 'txt' or 'python' [default: %default]")
+    parser.add_option("--general.namespaces", default=None, help="Allows to enumerate namespaces of interest."
+                      " If not defined all namespaces available in database file will be processed."
+                      " Separate several namespaces by comma, for example 'general,std.code.complexity'"
+                      " [default: %default]")
+    parser.add_option("--general.nest-regions", action="store_true", default=False,
+                      help="If the option is set (True), data for regions is exported in the form of a tree. "
+                      "Otherwise, all regions are exported in plain list. [default: %default]")
+
+    (options, args) = parser.parse_args(tool_args)
+    log_plugin.configure(options)
+    db_plugin.configure(options)
+    out_format = options.__dict__['general.format']
+    nest_regions = options.__dict__['general.nest_regions']
+    namespaces = None
+    if options.__dict__['general.namespaces'] != None:
+        namespaces = re.split(',', options.__dict__['general.namespaces'])
+
+    loader_prev = core.db.loader.Loader()
+    if db_plugin.dbfile_prev != None:
+        loader_prev.open_database(db_plugin.dbfile_prev)
+
+    loader = core.db.loader.Loader()
+    loader.open_database(db_plugin.dbfile)
+    
+    # Check for versions consistency
+    for each in loader.iterate_properties():
+        if db_plugin.dbfile_prev != None:
+            prev = loader_prev.get_property(each.name)
+            if prev != each.value:
+                logging.warn("Previous data has got different metadata:")
+                logging.warn(" - identification of change trends can be not reliable")
+                logging.warn(" - use 'info' tool to get more details")
+                break
+    
+    paths = None
+    if len(args) == 0:
+        paths = [""]
+    else:
+        paths = args
+        
+    (result, exit_code) = export_to_str(out_format, paths, loader, loader_prev, namespaces, nest_regions)
+    print result
+    return exit_code
+
+def export_to_str(out_format, paths, loader, loader_prev, namespaces, nest_regions):
+    exit_code = 0
+    result = ""
+    if out_format == 'txt':
+        result += "=" * 80 + "\n" + "Export" + "\n" + "_" * 80 + "\n\n"
+    elif out_format == 'xml':
+        result += "<export>\n"
+    elif out_format == 'python':
+        result += "{'export': ["
+
+    for (ind, path) in enumerate(paths):
+        logging.info("Processing: " + re.sub(r'''[\\]''', "/", path))
+        
+        aggregated_data = loader.load_aggregated_data(path, namespaces=namespaces)
+        aggregated_data_tree = {}
+        subdirs = []
+        subfiles = []
+        if aggregated_data != None:
+            aggregated_data_tree = aggregated_data.get_data_tree(namespaces=namespaces)
+            subdirs = aggregated_data.get_subdirs()
+            subfiles = aggregated_data.get_subfiles()
+        else:
+            logging.error("Specified path '" + path + "' is invalid (not found in the database records)")
+            exit_code += 1
+        aggregated_data_prev = loader_prev.load_aggregated_data(path, namespaces=namespaces)
+        if aggregated_data_prev != None:
+            aggregated_data_tree = append_diff(aggregated_data_tree,
+                                           aggregated_data_prev.get_data_tree(namespaces=namespaces))
+        
+        file_data = loader.load_file_data(path)
+        file_data_tree = {}
+        if file_data != None:
+            file_data_tree = file_data.get_data_tree(namespaces=namespaces) 
+            file_data_prev = loader_prev.load_file_data(path)
+            append_regions(file_data_tree, file_data, file_data_prev, namespaces, nest_regions)
+        
+        data = {"info": {"path": path, "id": ind + 1},
+                "aggregated-data": aggregated_data_tree,
+                "file-data": file_data_tree,
+                "subdirs": subdirs,
+                "subfiles": subfiles}
+
+        if out_format == 'txt':
+            result += core.export.convert.to_txt(data, root_name = "data") + "\n"
+        elif out_format == 'xml':
+            result += core.export.convert.to_xml(data, root_name = "data") + "\n"
+        elif out_format == 'python':
+            postfix = ""
+            if ind < len(paths) - 1:
+                postfix = ", "
+            result += core.export.convert.to_python(data, root_name = "data") + postfix
+
+    if out_format == 'txt':
+        result += "\n"
+    elif out_format == 'xml':
+        result += "</export>"
+    elif out_format == 'python':
+        result += "]}"
+        
+    return (result, exit_code)
+
+def append_regions(file_data_tree, file_data, file_data_prev, namespaces, nest_regions):
+    regions_matcher = None
+    if file_data_prev != None:
+        file_data_tree = append_diff(file_data_tree,
+                                     file_data_prev.get_data_tree(namespaces=namespaces))
+        regions_matcher = core.db.utils.FileRegionsMatcher(file_data, file_data_prev)
+    
+    if nest_regions == False:
+        regions = []
+        for region in file_data.iterate_regions():
+            region_data_tree = region.get_data_tree(namespaces=namespaces)
+            if regions_matcher != None and regions_matcher.is_matched(region.get_id()):
+                region_data_prev = file_data_prev.get_region(regions_matcher.get_prev_id(region.get_id()))
+                region_data_tree = append_diff(region_data_tree,
+                                               region_data_prev.get_data_tree(namespaces=namespaces))
+            regions.append({"info": {"name" : region.name,
+                                     'type' : file_data.get_region_types()().to_str(region.get_type()),
+                                     "cursor" : region.cursor,
+                                     'line_begin': region.line_begin,
+                                     'line_end': region.line_end,
+                                     'offset_begin': region.begin,
+                                     'offset_end': region.end},
+                            "data": region_data_tree})
+        file_data_tree['regions'] = regions
+    else:
+        def append_rec(region_id, file_data_tree, file_data, file_data_prev, namespaces):
+            region = file_data.get_region(region_id)
+            region_data_tree = region.get_data_tree(namespaces=namespaces)
+            if regions_matcher != None and regions_matcher.is_matched(region.get_id()):
+                region_data_prev = file_data_prev.get_region(regions_matcher.get_prev_id(region.get_id()))
+                region_data_tree = append_diff(region_data_tree,
+                                               region_data_prev.get_data_tree(namespaces=namespaces))
+            result = {"info": {"name" : region.name,
+                               'type' : file_data.get_region_types()().to_str(region.get_type()),
+                               "cursor" : region.cursor,
+                               'line_begin': region.line_begin,
+                               'line_end': region.line_end,
+                               'offset_begin': region.begin,
+                               'offset_end': region.end},
+                      "data": region_data_tree,
+                      "subregions": []}
+            for sub_id in file_data.get_region(region_id).iterate_subregion_ids():
+                result['subregions'].append(append_rec(sub_id, file_data_tree, file_data, file_data_prev, namespaces))
+            return result
+        file_data_tree['regions'] = []
+        file_data_tree['regions'].append(append_rec(1, file_data_tree, file_data, file_data_prev, namespaces))
+
+def append_diff(main_tree, prev_tree):
+    assert(main_tree != None)
+    assert(prev_tree != None)
+    
+    for name in main_tree.keys():
+        if name not in prev_tree.keys():
+            continue
+        for field in main_tree[name].keys():
+            if field not in prev_tree[name].keys():
+                continue
+            if isinstance(main_tree[name][field], dict) and isinstance(prev_tree[name][field], dict):
+                diff = {}
+                for key in main_tree[name][field].keys():
+                    if key not in prev_tree[name][field].keys():
+                        continue
+                    main_val = main_tree[name][field][key]
+                    prev_val = prev_tree[name][field][key]
+                    if main_val == None:
+                        main_val = 0
+                    if prev_val == None:
+                        prev_val = 0
+                    if isinstance(main_val, list) and isinstance(prev_val, list):
+                        main_tree[name][field][key] = append_diff_list(main_val, prev_val)
+                    else:
+                        diff[key] = main_val - prev_val
+                main_tree[name][field]['__diff__'] = diff
+            elif (not isinstance(main_tree[name][field], dict)) and (not isinstance(prev_tree[name][field], dict)):
+                if '__diff__' not in main_tree[name]:
+                    main_tree[name]['__diff__'] = {}
+                main_tree[name]['__diff__'][field] = main_tree[name][field] - prev_tree[name][field]
+    return main_tree
+
+def append_diff_list(main_list, prev_list):
+    merged_list = {}
+    for bar in main_list:
+        merged_list[bar['metric']] = {'count': bar['count'], '__diff__':0}
+    for bar in prev_list:
+        if bar['metric'] in merged_list.keys():
+            merged_list[bar['metric']]['__diff__'] = \
+                merged_list[bar['metric']]['count'] - bar['count']
+        else:
+            merged_list[bar['metric']] = {'count': 0, '__diff__':-bar['count']}
+    result = []
+    for metric in sorted(merged_list.keys()):
+        result.append({'metric':metric, 'count':merged_list[metric]['count'], '__diff__':merged_list[metric]['__diff__']})
+    return result