JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 2
  • Score
    100M100P100Q64539F
  • License EPL-2.0

In Memory implementation of the Pandino Persistence Manager API

Package Exports

  • @pandino/persistence-manager-memory

Readme

persistence-manager-memory

In Memory implementation of the Pandino Persistence Manager API

Installation

Install via adding it to pandino-manifests

Only works, if @pandino/bundle-installer-dom is installed!

<script type="pandino-manifests">
  [
    ...,
    "./persistence-manager-memory-manifest.json"
  ]
</script>

Install via BundleContext API

E.g.: directly via the Pandino instance.

const pandino: Bundle;

// ...

pandino.getBundleContext().installBundle('./persistence-manager-memory-manifest.json');

Usage

export default class Activator {
  async start(context) {
    this.persistenceManagerReference = context.getServiceReference('@pandino/persistence-manager/PersistenceManager');
    this.persistenceManager = context.getService(this.persistenceManagerReference);

    console.log(this.persistenceManager.exists('test.pid'));
  }

  async stop(context) {
    context.ungetService(this.persistenceManagerReference);
  }
}

License

Eclipse Public License - v 2.0