Skip to content

EscherConverter Understanding current code base

Devesh Khandelwal edited this page May 9, 2016 · 4 revisions

Part I

To be able to complete this project, we must first understand the current codebase of [EscherConverter]. As we are basically doing the reverse of the conversion process which EscherConverter currently supports, a clear understanding and mental model of how the conversion between Escher's format and SBML/SBGN takes place is necessary.

For that we will be going through the whole project, visiting and focussing on the important points, pondering on why is it important, what can be improved, what features will be added, what should be removed/replaced/updated, and most importantly, how it ties up to the larger process of the conversion. Let's get started then.

LICENSE

Let's get this cleared out first. Escher and inherently EscherConverter are open source, licensed under the MIT License. It is a higly permissive license, and we don't to stall research in systems biology just because of a license.

pom.xml

This is the build file for configuring the build of EscherConverter. Every Maven based project have one of these. While most of it is pretty trivial, I'll just point the things which are important.

  • Dependencies

    • junit - We will be using junit for unit testing. It is arguably the most popular testing framework for Java out there.
    • JSBML - The de facto library for handling and manipulating SBML files in Java and possibly most languages. Also, this is already used, so we would like to reuse code as much as possible.
    • libSBGN - Again, the de facto for SBGN files. There are also not much optinos here.
    • JSON - There a few options available for JSON handling. Currently, EscherConverter uses json-simple but we may look into other popular options such as Jackson and Gson.
    • SysBio
  • Build output

    <packaging>jar</packaging>

The build file is configured to produce an executable jar with EscherConverter as the main class which contains the main method. So, all calls from the command line goes to this class.

We would also like to structure this project so that it can also be used as a libray for other programmers to use.

EscherConverter.java

This is the entrypoint to the jar executable. To get a better understanding, we will first run the project and try to understand by what it does.

Model classes

There are many classes which represent the objects present in an SBML/SBGN file, e.g. Gene.java, Node.java, Segment.java, etc.

Also, object classes native to Escher exists such as EscherReaction.java, EscherMap, etc. There are abstract classes (AbstractEscherBase.java, etc.) also which are extended by concrete Escher classes.

An important point here is that, right now, all of these classes live in a single package, there is not heirarchy or logical arrangement of files. One of the goals of this project will be to also organize this project so that someone else is also able to contribute to it. We can have a separate package e.g. a model for files which represents objects in I/O files. In this we can have separate packages for Escher, SBGN, SBML, etc.

  1. one
  2. two
  • 2.2
  1. three

Clone this wiki locally