Просмотр исходного кода

Commit generation of R2RML mapping

Christophe Debruyne 8 лет назад
Родитель
Сommit
360ead9e66

+ 21 - 0
.classpath

@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" output="target/classes" path="src">
+		<attributes>
+			<attribute name="optional" value="true"/>
+			<attribute name="maven.pomderived" value="true"/>
+		</attributes>
+	</classpathentry>
+	<classpathentry kind="src" path="test"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8">
+		<attributes>
+			<attribute name="maven.pomderived" value="true"/>
+		</attributes>
+	</classpathentry>
+	<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
+		<attributes>
+			<attribute name="maven.pomderived" value="true"/>
+		</attributes>
+	</classpathentry>
+	<classpathentry kind="output" path="target/classes"/>
+</classpath>

+ 2 - 0
.gitignore

@@ -12,3 +12,5 @@
 # virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
 hs_err_pid*
 
+/bin/
+/target/

+ 23 - 0
.project

@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>generate-mapping</name>
+	<comment></comment>
+	<projects>
+	</projects>
+	<buildSpec>
+		<buildCommand>
+			<name>org.eclipse.jdt.core.javabuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+		<buildCommand>
+			<name>org.eclipse.m2e.core.maven2Builder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.eclipse.m2e.core.maven2Nature</nature>
+		<nature>org.eclipse.jdt.core.javanature</nature>
+	</natures>
+</projectDescription>

+ 5 - 0
.settings/org.eclipse.jdt.core.prefs

@@ -0,0 +1,5 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
+org.eclipse.jdt.core.compiler.compliance=1.8
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
+org.eclipse.jdt.core.compiler.source=1.8

+ 4 - 0
.settings/org.eclipse.m2e.core.prefs

@@ -0,0 +1,4 @@
+activeProfiles=
+eclipse.preferences.version=1
+resolveWorkspaceProjects=true
+version=1

+ 18 - 5
LICENSE

@@ -1,8 +1,21 @@
-MIT License
-Copyright (c) <year> <copyright holders>
+The MIT License (MIT)
 
-Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
+Copyright (c) 2017 Christophe Debruyne, ADAPT Centre, Trinity College Dublin, Ireland
 
-The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
 
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.

+ 89 - 0
pom.xml

@@ -0,0 +1,89 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+	<modelVersion>4.0.0</modelVersion>
+	<groupId>generate-mapping</groupId>
+	<artifactId>generate-mapping</artifactId>
+	<version>0.0.1-SNAPSHOT</version>
+	<build>
+		<finalName>generate-mapping</finalName>
+		<sourceDirectory>src</sourceDirectory>
+		<plugins>
+			<plugin>
+				<artifactId>maven-compiler-plugin</artifactId>
+				<version>3.3</version>
+				<configuration>
+					<source>1.8</source>
+					<target>1.8</target>
+				</configuration>
+			</plugin>
+			<plugin>
+				<groupId>org.apache.maven.plugins</groupId>
+				<artifactId>maven-jar-plugin</artifactId>
+				<configuration>
+					<archive>
+						<manifest>
+							<addClasspath>true</addClasspath>
+							<classpathPrefix>dependency/</classpathPrefix>
+							<mainClass>r2rml.GenerateMapping</mainClass>
+						</manifest>
+					</archive>
+				</configuration>
+			</plugin>
+			<plugin>
+				<groupId>org.apache.maven.plugins</groupId>
+				<artifactId>maven-shade-plugin</artifactId>
+				<version>2.4.3</version>
+				<executions>
+					<execution>
+						<phase>package</phase>
+						<goals>
+							<goal>shade</goal>
+						</goals>
+						<configuration>
+							<finalName>generate-mapping-fat</finalName>
+							<transformers>
+								<transformer
+									implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
+									<mainClass>r2rml.GenerateMapping</mainClass>
+								</transformer>
+							</transformers>
+						</configuration>
+					</execution>
+				</executions>
+			</plugin>
+		</plugins>
+	</build>
+
+	<dependencies>
+		<dependency>
+			<groupId>org.apache.jena</groupId>
+			<artifactId>jena-arq</artifactId>
+			<version>3.0.1</version>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.jena</groupId>
+			<artifactId>jena-core</artifactId>
+			<version>3.0.1</version>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.jena</groupId>
+			<artifactId>jena-iri</artifactId>
+			<version>3.0.1</version>
+		</dependency>
+		<dependency>
+			<groupId>junit</groupId>
+			<artifactId>junit</artifactId>
+			<version>4.11</version>
+		</dependency>
+		<dependency>
+			<groupId>com.h2database</groupId>
+			<artifactId>h2</artifactId>
+			<version>1.4.193</version>
+		</dependency>
+	</dependencies>
+
+	<organization>
+		<name>Adapt Centre, Trinity College Dublin</name>
+		<url>http://www.adaptcentre.ie/</url>
+	</organization>
+</project>

+ 8 - 0
src/log4j.properties

@@ -0,0 +1,8 @@
+# Root logger option
+log4j.rootLogger=INFO, stdout
+
+# Direct log messages to stdout
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.Target=System.out
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n

+ 19 - 0
src/r2rml/GenMapException.java

@@ -0,0 +1,19 @@
+package r2rml;
+
+public class GenMapException extends Exception {
+
+	private static final long serialVersionUID = -195670607332859688L;
+
+	public GenMapException() {
+		super();
+	}
+
+	public GenMapException(String message, Throwable cause) {
+		super(message, cause);
+	}
+
+	public GenMapException(String message) {
+		super(message);
+	}
+	
+}

+ 213 - 0
src/r2rml/GenerateMapping.java

@@ -0,0 +1,213 @@
+package r2rml;
+
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.OutputStream;
+import java.net.URLEncoder;
+import java.sql.Connection;
+import java.sql.DriverManager;
+import java.sql.ResultSet;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Properties;
+
+import org.apache.commons.cli.CommandLine;
+import org.apache.commons.cli.CommandLineParser;
+import org.apache.commons.cli.DefaultParser;
+import org.apache.commons.cli.HelpFormatter;
+import org.apache.commons.cli.Options;
+import org.apache.commons.cli.ParseException;
+import org.apache.commons.io.FilenameUtils;
+import org.apache.jena.rdf.model.Model;
+import org.apache.jena.rdf.model.ModelFactory;
+import org.apache.jena.rdf.model.Resource;
+import org.apache.jena.rdf.model.ResourceFactory;
+import org.apache.jena.riot.Lang;
+import org.apache.jena.riot.RDFDataMgr;
+import org.apache.log4j.Logger;
+
+public class GenerateMapping {
+
+	private static Logger logger = Logger.getLogger(GenerateMapping.class.getName());
+
+	private static File csvFile = null;
+	private static File conFile = null;
+	private static File mapFile = null;
+
+	private static String NS = "http://adaptcentre.ie/ont/odef#";
+	private static Resource Record = ResourceFactory.createResource(NS + "Record");
+
+	private static Model mapping = ModelFactory.createDefaultModel();
+
+	public static void main(String[] args) {
+
+		try {
+			parseArguments(args);
+
+			createMappingFromCSVFile();
+
+			writeMappingFile();
+
+			writeConfigurationFile();
+		} catch (Exception e) {
+			logger.error(e.getMessage());
+		}
+	}
+
+	private static void createMappingFromCSVFile() throws GenMapException {
+		try {
+			String CSV = csvFile.getCanonicalPath() + "#";
+
+			mapping = ModelFactory.createDefaultModel();
+			mapping.setNsPrefix("rr", R2RML.NS);
+			mapping.setNsPrefix("odef", NS);
+			mapping.setNsPrefix("csv", CSV);
+			
+			Resource triplesmap = mapping.createResource("#TriplesMap");
+
+			// create the TriplesMap with the logical table
+			Resource lt = mapping.createResource();
+			mapping.add(triplesmap, R2RML.logicalTable, lt);
+			String name = createTableNameForFile(csvFile);
+			mapping.add(lt, R2RML.sqlQuery, "SELECT rownum() AS ROW_NUM, * FROM " + name + ";");
+
+			// create the SubjectMap
+			Resource sm = mapping.createResource();
+			mapping.add(triplesmap, R2RML.subjectMap, sm);
+			mapping.add(sm, R2RML.template, "http://www.example.org/record/{ROW_NUM}");
+			mapping.add(sm, R2RML.clazz, Record);
+			
+			for(String cname : getColumnNames()) {
+				// create PredicateObjectMaps
+				Resource pom = mapping.createResource();
+				mapping.add(triplesmap, R2RML.predicateObjectMap, pom);
+				Resource predicate = mapping.createResource(CSV + URLEncoder.encode(cname, "UTF-8"));
+				mapping.add(pom, R2RML.predicate, predicate);
+
+				Resource om = mapping.createResource();
+				mapping.add(pom, R2RML.objectMap, om);
+				mapping.add(om, R2RML.column, cname);
+			}
+
+		} catch (Exception e) {
+			throw new GenMapException("Problem processing CSV file: " + e .getMessage(), e);
+		}
+	}
+
+	private static List<String> getColumnNames() throws GenMapException {
+		List<String> columnNames = new ArrayList<String>();
+		
+		try {
+			String connectionURL = "jdbc:h2:mem:" + System.currentTimeMillis();
+			DriverManager.getConnection(connectionURL + ";create=true").close();
+
+			Connection connection = DriverManager.getConnection(connectionURL);
+			java.sql.Statement statement = connection.createStatement();
+
+			String sql = "SELECT rownum() AS ROW_NUM, * FROM CSVREAD('"  + csvFile.getAbsolutePath() + "', NULL, NULL) LIMIT 1;";
+			ResultSet rs = statement.executeQuery(sql);
+			for(int i = 1; i <= rs.getMetaData().getColumnCount(); i++) {
+				columnNames.add(rs.getMetaData().getColumnName(i));
+			}
+			
+			statement.close();
+			connection.close();			
+		} catch(Exception e){
+			throw new GenMapException("Problem processing CSV file: " + e .getMessage(), e);
+		}
+		
+		return columnNames;
+	}
+
+	private static void writeMappingFile() throws GenMapException {
+		try {
+			mapFile.createNewFile();
+			RDFDataMgr.write(new FileOutputStream(mapFile), mapping, Lang.TURTLE);
+		} catch (IOException e) {
+			throw new GenMapException("Problem writing R2RML mapping file: " + e .getMessage(), e);
+		}
+
+	}
+
+	private static void writeConfigurationFile() throws GenMapException {
+		Properties prop = new Properties();
+		prop.setProperty("CSVFiles", csvFile.toString());
+		prop.setProperty("mappingFile", mapFile.toString());
+		prop.setProperty("outputFile", csvFile.toString() + ".ttl");
+		prop.setProperty("format", "TURTLE");
+
+		OutputStream out = null;
+
+		try {
+			out = new FileOutputStream(conFile);
+			prop.store(out, "Generated with the generate-mapping tool.");
+		} catch (IOException e) {
+			throw new GenMapException("Error writing config file: " + e.getMessage(), e);
+		} finally {
+			if (out != null) {
+				try {
+					out.close();
+				} catch (IOException e) {
+					throw new GenMapException("Error closing config file: " + e.getMessage(), e);
+				}
+			}
+		}
+	}
+
+	private static String createTableNameForFile(File file) {
+		String name = FilenameUtils.getBaseName(file.getAbsolutePath());
+		return name;
+	}
+
+	private static void parseArguments(String[] args) throws GenMapException {
+		Options options = new Options();
+		options.addOption("f", true, "The CSV file for which a R2RML mapping will be generated.");
+		options.addOption("c", true, "The filename for the R2RML configuration file (default = config.properties).");
+		options.addOption("m", true, "The filename for the R2RML mapping file (default = mapping.ttl).");
+		options.addOption("h", false, "Display help.");
+
+		try {
+			CommandLineParser parser = new DefaultParser();
+			CommandLine cmd = parser.parse(options, args);
+
+			// Display help
+			if(cmd.hasOption("h")) {
+				HelpFormatter formatter = new HelpFormatter();
+				formatter.printHelp("generate-mapping.jar", options);
+				System.exit(0);
+			}
+
+			String csv = null, con = null, map = null;
+
+			// Process CSV file
+			if(cmd.hasOption("f")) {
+				csv = cmd.getOptionValue("f");
+				logger.info("Using CSV file " + csv);
+			} else {				
+				throw new GenMapException("Providing a CSV file is mandatory.");
+			}
+
+			csvFile = new File(csv);
+
+			if(!csvFile.exists()) {
+				throw new GenMapException("CSV file does not exist.");
+			}
+
+			// Process config file
+			con = cmd.getOptionValue("c", "config.properties");
+			logger.info("Using R2RML config file " + con);
+			conFile = new File(con);
+
+			// Process mapping file
+			map = cmd.getOptionValue("m", "mapping.ttl");
+			logger.info("Using R2RML mapping file " + map);
+			mapFile = new File(map);
+
+		} catch(ParseException e) {
+			throw new GenMapException("Parsing failed.  Reason: " + e.getMessage(), e);
+		}
+
+	}
+
+}

+ 61 - 0
src/r2rml/R2RML.java

@@ -0,0 +1,61 @@
+package r2rml;
+
+import org.apache.jena.rdf.model.Property;
+import org.apache.jena.rdf.model.Resource;
+import org.apache.jena.rdf.model.ResourceFactory;
+
+/**
+ * R2RML Class.
+ * 
+ * @author Christophe Debruyne
+ * @version 0.1
+ *
+ */
+public final class R2RML {
+	
+	public static final String NS = "http://www.w3.org/ns/r2rml#";
+	
+	public static final Resource BLANKNODE = ResourceFactory.createResource(NS + "BlankNode");
+	public static final Resource IRI = ResourceFactory.createResource(NS + "IRI");
+	public static final Resource LITERAL = ResourceFactory.createResource(NS + "Literal");
+	
+	// Special resource for default graph
+	public static final Resource defaultGraph = ResourceFactory.createResource(NS + "defaultGraph");
+
+	// Classes
+	public static final Resource BaseTableOrView = ResourceFactory.createResource(NS + "BaseTableOrView");
+	public static final Resource GraphMap = ResourceFactory.createResource(NS + "GraphMap");
+	public static final Resource LogicalTable = ResourceFactory.createResource(NS + "LogicalTable");
+	public static final Resource ObjectMap = ResourceFactory.createResource(NS + "ObjectMap");
+	public static final Resource R2RMLView = ResourceFactory.createResource(NS + "R2RMLView");
+	public static final Resource RefObjectMap = ResourceFactory.createResource(NS + "RefObjectMap");
+	public static final Resource SubjectMap = ResourceFactory.createResource(NS + "SubjectMap");
+	public static final Resource TermMap = ResourceFactory.createResource(NS + "TermMap");
+	public static final Resource TriplesMap = ResourceFactory.createResource(NS + "TriplesMap");
+	
+	// Properties
+	public static final Property child = ResourceFactory.createProperty(NS + "child");
+	public static final Property clazz = ResourceFactory.createProperty(NS + "class");
+	public static final Property column = ResourceFactory.createProperty(NS + "column");
+	public static final Property constant = ResourceFactory.createProperty(NS + "constant");
+	public static final Property datatype = ResourceFactory.createProperty(NS + "datatype");
+	public static final Property graph = ResourceFactory.createProperty(NS + "graph");
+	public static final Property graphMap = ResourceFactory.createProperty(NS + "graphMap");
+	public static final Property joinCondition = ResourceFactory.createProperty(NS + "joinCondition");
+	public static final Property language = ResourceFactory.createProperty(NS + "language");
+	public static final Property logicalTable = ResourceFactory.createProperty(NS + "logicalTable");
+	public static final Property object = ResourceFactory.createProperty(NS + "object");
+	public static final Property objectMap = ResourceFactory.createProperty(NS + "objectMap");
+	public static final Property parent = ResourceFactory.createProperty(NS + "parent");
+	public static final Property parentTriplesMap = ResourceFactory.createProperty(NS + "parentTriplesMap");
+	public static final Property predicate = ResourceFactory.createProperty(NS + "predicate");
+	public static final Property predicateMap = ResourceFactory.createProperty(NS + "predicateMap");
+	public static final Property predicateObjectMap = ResourceFactory.createProperty(NS + "predicateObjectMap");
+	public static final Property sqlQuery = ResourceFactory.createProperty(NS + "sqlQuery");
+	public static final Property subject = ResourceFactory.createProperty(NS + "subject");
+	public static final Property subjectMap = ResourceFactory.createProperty(NS + "subjectMap");
+	public static final Property tableName = ResourceFactory.createProperty(NS + "tableName");
+	public static final Property template = ResourceFactory.createProperty(NS + "template");
+	public static final Property termType = ResourceFactory.createProperty(NS + "termType");
+	
+}

+ 6 - 0
test/resources/config.properties

@@ -0,0 +1,6 @@
+#Generated with the generate-mapping tool.
+#Wed Feb 08 17:28:10 GMT 2017
+CSVFiles=./test/resources/fccweatherstationsp201108292221.csv
+format=TURTLE
+outputFile=./test/resources/fccweatherstationsp201108292221.csv.ttl
+mappingFile=./test/resources/mapping.ttl

+ 4 - 0
test/resources/fccweatherstationsp20110829-2221.csv

@@ -0,0 +1,4 @@
+Name,Weather_Reading,Agency,LAT,LONG
+M50 Blanchardstown,http://www.nratraffic.ie/weather/default.asp?weatherstation=IR26&selected=true&showonly=true,National Roads Authority,53.3704660326011,-6.38085144711153
+M50 Dublin Airport,http://www.nratraffic.ie/weather/default.asp?weatherstation=IR57&selected=true&showonly=true,National Roads Authority,53.4096411069945,-6.22759742761812
+Dublin Airport,http://www.met.ie/latest/reports.asp,Met Éireann,53.4215060785623,-6.29784754004026

+ 4 - 0
test/resources/fccweatherstationsp201108292221.csv

@@ -0,0 +1,4 @@
+Name,Weather_Reading,Agency,LAT,LONG
+M50 Blanchardstown,http://www.nratraffic.ie/weather/default.asp?weatherstation=IR26&selected=true&showonly=true,National Roads Authority,53.3704660326011,-6.38085144711153
+M50 Dublin Airport,http://www.nratraffic.ie/weather/default.asp?weatherstation=IR57&selected=true&showonly=true,National Roads Authority,53.4096411069945,-6.22759742761812
+Dublin Airport,http://www.met.ie/latest/reports.asp,Met �ireann,53.4215060785623,-6.29784754004026

+ 26 - 0
test/resources/mapping.ttl

@@ -0,0 +1,26 @@
+@prefix rr:    <http://www.w3.org/ns/r2rml#> .
+@prefix odef:  <http://adaptcentre.ie/ont/odef#> .
+@prefix csv:   </Users/chrdebru/GITHUB/generate-mapping/test/resources/fccweatherstationsp201108292221.csv#> .
+
+<#TriplesMap>  rr:logicalTable  [ rr:sqlQuery  "SELECT rownum() AS ROW_NUM, * FROM fccweatherstationsp201108292221;" ] ;
+        rr:predicateObjectMap  [ rr:objectMap  [ rr:column  "LONG" ] ;
+                                 rr:predicate  csv:LONG
+                               ] ;
+        rr:predicateObjectMap  [ rr:objectMap  [ rr:column  "LAT" ] ;
+                                 rr:predicate  csv:LAT
+                               ] ;
+        rr:predicateObjectMap  [ rr:objectMap  [ rr:column  "AGENCY" ] ;
+                                 rr:predicate  csv:AGENCY
+                               ] ;
+        rr:predicateObjectMap  [ rr:objectMap  [ rr:column  "WEATHER_READING" ] ;
+                                 rr:predicate  csv:WEATHER_READING
+                               ] ;
+        rr:predicateObjectMap  [ rr:objectMap  [ rr:column  "NAME" ] ;
+                                 rr:predicate  csv:NAME
+                               ] ;
+        rr:predicateObjectMap  [ rr:objectMap  [ rr:column  "ROW_NUM" ] ;
+                                 rr:predicate  csv:ROW_NUM
+                               ] ;
+        rr:subjectMap          [ rr:class     odef:Record ;
+                                 rr:template  "http://www.example.org/record/{ROW_NUM}"
+                               ] .

+ 18 - 0
test/test/TestGenerateMapping.java

@@ -0,0 +1,18 @@
+package test;
+
+import r2rml.GenerateMapping;
+
+public class TestGenerateMapping {
+
+	public static void main(String[] args) {
+		args = new String[] { 
+				"-f", "./test/resources/fccweatherstationsp201108292221.csv",
+				"-c", "./test/resources/config.properties",
+				"-m", "./test/resources/mapping.ttl"
+		};
+		
+		GenerateMapping.main(args);
+
+	}
+
+}