Git Product home page Git Product logo

emf-model-demo's Introduction

emf_estore_demo

Demo for EMF EStore feature

This little demo shows how to implement EStore custom storage with EMF.

Storage is very simple it takes Eclipse Resources IFile and store each 500 objects into separate files. It uses LRUCache to implement model in memory caching.

How to test demo.

  1. Create new "New EStore Demo Model" via Eclipse new file wizard.
  2. Check generate checkbox.
  3. Wait for generation.
  4. Open "EStore Demo" and select generated file in project explorer.
  5. View and navigate for data.

Implementation details:

  1. com.xored.estore_demo.ModelEntry Persistence layer based on top of Persistence EMF Model class.
  2. com.xored.estore_demo.ResourceBasedEStoreModel EStore interface implementation. Most of sugar are here.

How EStore are work.

Then we specify featureDelegation="Reflective" in our genmodel, EMF will delegate all operations to EStore class. EStore class itself contain set/get and so on methods with signature (InternalEObject, EStructuralFeature, Object..) so it is possible to set/get data from any source. In this example this is file based source. It could be DB and so on.

Because of this Objects itself are just a handles to real data. In sample I've used proxyURI of InternalEObject class to do a object identity.

Screenshots

Demo Demo Demo Demo

emf-model-demo's People

Contributors

haiodo avatar

Stargazers

 avatar

Watchers

Leon Deriglazov avatar Yuriy Kashnikov avatar Alexey Kutepov avatar Sergey Todyshev avatar Ilya Kuznetsov avatar Timofey Vasenin avatar Andrey Platov avatar Ivan Kornienko avatar Aleksander avatar Oleg M. avatar Vasili Gulevich avatar Aleksei Shpitalev avatar Fedor Yudanov avatar James Cloos avatar Anton Kiselev avatar  avatar Alexander Alexeyenko avatar Sergey Shelomentsev avatar Igor Zapletnev avatar Denis Naygeborin avatar Sergey Sitnikov avatar Ulyana Skorokhodova avatar  avatar Alexander Tretyakevich avatar Vasily Loginov avatar Belyakov Stanislav avatar Eugeny Tulupov avatar Krisitna Bekker avatar  avatar Evgeniy Storozhenko avatar  avatar Vadim Kuzmenko avatar Evgeny Smirnov avatar Ruslan Shakirov avatar Mixail Bobylev avatar  avatar Andrey Martianov avatar Stanislav Belyakov avatar Mikhail Beloshapkin avatar  avatar  avatar Johny avatar Alexander Zubarev avatar Anatoly Belonog avatar Roman Kuskov avatar Vadim Geraskin avatar Iaroslav Pankratev avatar Alexey Zinoviev avatar Daniil Efremov avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.