// Path: bionetdb-core/src/main/java/org/opencb/bionetdb/core/models/network/Network.java
// public class Network extends Graph {
// 
//     private String id;
//     private String name;
//     private String description;
// 
//     private Map<String, Object> attributes;
// 
//     private long numNodes;
//     private long numRelations;
// 
//     public Network() {
//         this("", "", "");
//     }
// 
//     public Network(String id, String name, String description) {
//         super();
//         this.id = id;
//         this.name = name;
//         this.description = description;
// 
//         attributes = new HashMap<>();
//     }
// 
//     public void write(File file) throws FileNotFoundException, JsonProcessingException {
//         Network network = new Network(id, name, description);
//         network.setAttributes(attributes);
//         network.setNumNodes(nodes.size());
//         network.setNumRelations(relations.size());
// 
//         ObjectMapper mapper = new ObjectMapper();
//         mapper.setSerializationInclusion(JsonInclude.Include.NON_NULL);
//         mapper.configure(MapperFeature.REQUIRE_SETTERS_FOR_GETTERS, true);
// 
//         PrintWriter pw = new PrintWriter(file);
// 
//         pw.println(mapper.writer().writeValueAsString(network));
//         for (Node node: nodes) {
//             pw.println(mapper.writer().writeValueAsString(node));
//         }
//         for (Relation relation: relations) {
//             pw.println(mapper.writer().writeValueAsString(relation));
//         }
// 
//         pw.close();
// 
// 
//     }
// 
// 
//     @Override
//     public String toString() {
//         final StringBuilder sb = new StringBuilder("Network{");
//         sb.append("id='").append(id).append('\'');
//         sb.append(", name='").append(name).append('\'');
//         sb.append(", description='").append(description).append('\'');
//         sb.append(", nodes=").append(nodes);
//         sb.append(", relations=").append(relations);
//         sb.append(", attributes=").append(attributes);
//         sb.append('}');
//         return sb.toString();
//     }
// 
//     public String getId() {
//         return id;
//     }
// 
//     public Network setId(String id) {
//         this.id = id;
//         return this;
//     }
// 
//     public String getName() {
//         return name;
//     }
// 
//     public Network setName(String name) {
//         this.name = name;
//         return this;
//     }
// 
//     public String getDescription() {
//         return description;
//     }
// 
//     public Network setDescription(String description) {
//         this.description = description;
//         return this;
//     }
// 
//     public Map<String, Object> getAttributes() {
//         return attributes;
//     }
// 
//     public Network setAttributes(Map<String, Object> attributes) {
//         this.attributes = attributes;
//         return this;
//     }
// 
//     public Network setNumNodes(long numNodes) {
//         this.numNodes = numNodes;
//         return this;
//     }
// 
//     public Network setNumRelations(long numRelations) {
//         this.numRelations = numRelations;
//         return this;
//     }
// }


import org.opencb.bionetdb.core.models.network.Network;
import java.io.IOException;
import java.nio.file.Path;
                    + " which one you are using) to make sure it list the"
                    + " directories needed to find the "
                    + System.mapLibraryName("sbmlj") + " library file and"
                    + " libraries it depends upon (e.g., the XML parser).");
            System.exit(1);
        } catch (ClassNotFoundException e) {
            System.err.println("Error: unable to load the file 'libsbmlj.jar'."
                    + " It is likely that your -classpath command line "
                    + " setting or your CLASSPATH environment variable "
                    + " do not include the file 'libsbmlj.jar'.");
            e.printStackTrace();
            System.exit(1);
        } catch (SecurityException e) {
            System.err.println("Error encountered while attempting to load libSBML:");
            e.printStackTrace();
            System.err.println("Could not load the libSBML library files due to a"
                    + " security exception.\n");
            System.exit(1);
        }
    }

    private static final String REACTOME_FEAT = "reactome.";

    public SbmlParser() {
        init();
    }

    private void init() {
    }

// Path: bionetdb-core/src/main/java/org/opencb/bionetdb/core/models/network/Network.java
// public class Network extends Graph {
// 
//     private String id;
//     private String name;
//     private String description;
// 
//     private Map<String, Object> attributes;
// 
//     private long numNodes;
//     private long numRelations;
// 
//     public Network() {
//         this("", "", "");
//     }
// 
//     public Network(String id, String name, String description) {
//         super();
//         this.id = id;
//         this.name = name;
//         this.description = description;
// 
//         attributes = new HashMap<>();
//     }
// 
//     public void write(File file) throws FileNotFoundException, JsonProcessingException {
//         Network network = new Network(id, name, description);
//         network.setAttributes(attributes);
//         network.setNumNodes(nodes.size());
//         network.setNumRelations(relations.size());
// 
//         ObjectMapper mapper = new ObjectMapper();
//         mapper.setSerializationInclusion(JsonInclude.Include.NON_NULL);
//         mapper.configure(MapperFeature.REQUIRE_SETTERS_FOR_GETTERS, true);
// 
//         PrintWriter pw = new PrintWriter(file);
// 
//         pw.println(mapper.writer().writeValueAsString(network));
//         for (Node node: nodes) {
//             pw.println(mapper.writer().writeValueAsString(node));
//         }
//         for (Relation relation: relations) {
//             pw.println(mapper.writer().writeValueAsString(relation));
//         }
// 
//         pw.close();
// 
// 
//     }
// 
// 
//     @Override
//     public String toString() {
//         final StringBuilder sb = new StringBuilder("Network{");
//         sb.append("id='").append(id).append('\'');
//         sb.append(", name='").append(name).append('\'');
//         sb.append(", description='").append(description).append('\'');
//         sb.append(", nodes=").append(nodes);
//         sb.append(", relations=").append(relations);
//         sb.append(", attributes=").append(attributes);
//         sb.append('}');
//         return sb.toString();
//     }
// 
//     public String getId() {
//         return id;
//     }
// 
//     public Network setId(String id) {
//         this.id = id;
//         return this;
//     }
// 
//     public String getName() {
//         return name;
//     }
// 
//     public Network setName(String name) {
//         this.name = name;
//         return this;
//     }
// 
//     public String getDescription() {
//         return description;
//     }
// 
//     public Network setDescription(String description) {
//         this.description = description;
//         return this;
//     }
// 
//     public Map<String, Object> getAttributes() {
//         return attributes;
//     }
// 
//     public Network setAttributes(Map<String, Object> attributes) {
//         this.attributes = attributes;
//         return this;
//     }
// 
//     public Network setNumNodes(long numNodes) {
//         this.numNodes = numNodes;
//         return this;
//     }
// 
//     public Network setNumRelations(long numRelations) {
//         this.numRelations = numRelations;
//         return this;
//     }
// }


// Path: bionetdb-core/src/main/java/org/opencb/bionetdb/core/io/SbmlParser.java
import org.opencb.bionetdb.core.models.network.Network;
import java.io.IOException;
import java.nio.file.Path;

                    + " which one you are using) to make sure it list the"
                    + " directories needed to find the "
                    + System.mapLibraryName("sbmlj") + " library file and"
                    + " libraries it depends upon (e.g., the XML parser).");
            System.exit(1);
        } catch (ClassNotFoundException e) {
            System.err.println("Error: unable to load the file 'libsbmlj.jar'."
                    + " It is likely that your -classpath command line "
                    + " setting or your CLASSPATH environment variable "
                    + " do not include the file 'libsbmlj.jar'.");
            e.printStackTrace();
            System.exit(1);
        } catch (SecurityException e) {
            System.err.println("Error encountered while attempting to load libSBML:");
            e.printStackTrace();
            System.err.println("Could not load the libSBML library files due to a"
                    + " security exception.\n");
            System.exit(1);
        }
    }

    private static final String REACTOME_FEAT = "reactome.";

    public SbmlParser() {
        init();
    }

    private void init() {
    }

    public Network parse(Path path) throws IOException {