CodeMetropolis
See your software as never before.
http://codemetropolis.github.io/CodeMetropolis/
Getting started
Setup for SourceMeter analysis
- Download SourceMeter from its webpage.
- Extract SourceMeter.
- Download Minecraft Java version from its webpage.
- Install Minecraft.
- Optionally you could use the Minecraft starter to change the version of Minecraft to 1.8 (the officialy supported one), but newer versions could also open CodeMetropolis generated worlds.
- Download the current stable releas of CodeMetropolis.
- Extract CodeMetropolis
Visualize source code meterics
- CodeMetropolis is able to visualize the static analysis results from SourceMeter. Currently Java is the most widely supported language. So to start, you have to locate a Java system, we will call this as target system.
- Analyze the target system with SourceMeter. You could use any settings as long as it will produce a
graph
file. This graph file contains all the necessary data for the CodeMetropolis.
- We will use the command line tools to create the visualization.
- Convert the data represented in the graph file into a more generic representations. Use the
converter
tool, with the sourcemeter conversion type option. It will produce an XML file which we call CDF
file (Common Data Format)
- Create a
mapping XML
file to define the mapping between the properties of the source code items and the graphical attributes of CodeMetropolis. There is several sample files in this repository.
- Execute the
mapping
tool with the CDF file and the mapping XML to produce the first (yet incomplete) representation of the city. It will stored as an XML file we called IXML
(Intermediate XML).
- The output of the
mapping
tool does not contain the placement and the size of the buildings. These data hava to be computed with the placing
tool.
- In the final step we need to use the
rendering
tool to convert the final IXML file into a Minecraft world.
- Installing the new visualization
- Start and close your Minecraft client (play the game) at least once to generate the necessary folder structure.
- Copy the generated world into the location of your saved worlds. On Windwos it is usually located under
C:\Users\<windows username>\AppData\Roaming\.minecraft\saves
. You have to copy the whole folder not just its content.
- Start the game and select the world from the list.
Complie from source
- clone repository
- checkout
develop
branch
- install Java 22
- install Maven 3.8.3 or newer
- navigate to
sources
folder
mvn clean package
- The current distribution will be aviable under
source/distro
.