170 likes | 288 Views
Bridging EMF applications and RDF Data Sources. Guillaume Hillairet , Frédéric Bertrand, Jean Yves Lafaye {guillaume.hillairet01, fbertran, jylafaye}@univ-lr.fr Laboratoire L3I, Université de La Rochelle, France. SWESE’08: Semantic Web Enabled Software Engineering @ ISWC’08.
E N D
Bridging EMF applications andRDF Data Sources Guillaume Hillairet, Frédéric Bertrand, Jean Yves Lafaye {guillaume.hillairet01, fbertran, jylafaye}@univ-lr.fr Laboratoire L3I, Université de La Rochelle, France. SWESE’08: Semantic Web Enabled Software Engineering @ ISWC’08. 26 October 2008
Agenda • Semantic Web Applications • Modeling Support for Semantic Web Apps • emf4sw: Eclipse Modeling Framework for Semantic Web • Conclusion SWESE'08
Semantic Web Applications refers to refers to described by described by described by described by provides access rdf data access rdf data SWESE'08
Semantic Web Applications • Web Applications: • Centralized, fixed schema, single data source … • Semantic Web: • Decentralized, arbitrary schema, many data sources … • From Web to Semantic Web Applications: • Using Semantic Web data in existing Web Applications. • Embedding Semantic Web data in common web development processes. • Our contribution: • Modeling support for Semantic Web Applications. • Use of RDF Data as EMF Objects • Similar approaches: • ActiveRDF, Topaz platform, … SWESE'08
Modeling Semantic Web Applications OWL/RDF(S) Generation JSF/HTML Generation SQL Generation Relational Persistence Semantic Web Data User Interface SWESE'08
emf4sw • Uses Eclipse Modeling Framework (EMF). • Links EMF applications with RDF Data Sources: • Mapping between OWL Ontology and EMF Model. • Load RDF data into M1 model. • Save M1 Model into RDF. • Manipulate RDF Data as EMF Objects. • Acts as an ORM but for RDF data. SWESE'08
emf4sw: main components • Resource Provider • Object/Ontology Mapping. • Loads/Saves objects. • Model Manager • Manages EMF Resources • Provides Model Transformations • Query Engine • Builds queries. • Provides query rewriting: • HQL to SPARQL, • SPARQL to HQL. • Data Source Manager • Accesses online data sources (SPARQL endpoints, …). • Supports access to multiple data sources. • Distributes/Federates query results. SWESE'08
emf4sw usage: initialization • First generate Java Classes from EMF Model. • Then, init a resource provider: • Add EPackages corresponding to the EMF Model • Add corresponding mapping file • Adding an RDF Data Source (RDF File, RDF DB, SPARQL endpoint): SWESE'08
Object/Ontology mapping • Need to explicitly define links between EMF Model and OWL Ontology • Proposition • Mapping language for Ecore/OWL • Map Ecore & OWL (MEO) SWESE'08
Object/Ontology Mapping • Mapping EMF Classes to OWL Classes • Map one EClass to one OWLClass • Map one EClass to many OWLClass • Have different views on same EClass, • Use of OCL constraints to define views. SWESE'08
Object/Ontology Mapping • Mapping EStructuralFeatures to OWLProperties • Map EAttribute to DataProperty • Map EReference to ObjectProperty SWESE'08
Object/Ontology Mapping SWESE'08
OOM: Model Transformations SWESE'08
emf4sw: Loading and Saving objects • Loading an EObject: • Saving an EObject: • Loading/Saving EMF Resources: SWESE'08
emf4sw: Querying RDF Data Source • Query RDF Data Source in HQL: • Or directly in SPARQL: SWESE'08
Conclusion • The goal of our approach is to ease import/export of Semantic Web data within current applications. • Object/Ontology mapping is necessary for embedding Semantic Web data in current applications (not only Web App.). • Model Driven Engineering simplifies and automates implementation and use of such complex process. • Well defined OWL ontologies are needed for describing RDF data sources. SWESE'08
Thank you, Questions ? SWESE'08