Socket
Socket
Sign inDemoInstall

rdf-streaming-store

Package Overview
Dependencies
Maintainers
2
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rdf-streaming-store - npm Package Compare versions

Comparing version 1.1.2 to 1.1.3

2

lib/PendingStreamsIndex.js

@@ -65,5 +65,5 @@ "use strict";

}
exports.PendingStreamsIndex = PendingStreamsIndex;
PendingStreamsIndex.ID_VARIABLE = '?';
PendingStreamsIndex.ID_SEPARATOR = ':';
exports.PendingStreamsIndex = PendingStreamsIndex;
//# sourceMappingURL=PendingStreamsIndex.js.map

@@ -6,2 +6,5 @@ /// <reference types="node" />

import { PendingStreamsIndex } from './PendingStreamsIndex';
interface ILocalStore<Q extends RDF.BaseQuad> extends RDF.Store<Q> {
countQuads: (subject: RDF.Term | null, predicate: RDF.Term | null, object: RDF.Term | null, graph: RDF.Term | null) => number;
}
/**

@@ -16,3 +19,3 @@ * A StreamingStore allows data lookup and insertion to happen in parallel.

*/
export declare class StreamingStore<Q extends RDF.BaseQuad = RDF.Quad, S extends RDF.Store<Q> = Store<Q>> implements RDF.Source<Q>, RDF.Sink<RDF.Stream<Q>, EventEmitter> {
export declare class StreamingStore<Q extends RDF.BaseQuad = RDF.Quad, S extends ILocalStore<Q> = Store<Q>> implements RDF.Source<Q>, RDF.Sink<RDF.Stream<Q>, EventEmitter> {
protected readonly store: S;

@@ -37,1 +40,2 @@ protected readonly pendingStreams: PendingStreamsIndex<Q>;

}
export {};

@@ -38,4 +38,4 @@ "use strict";

stream.on('data', (quad) => {
for (const pendingStream of this.pendingStreams.getPendingStreamsForQuad(quad)) {
if (!this.ended) {
if (!this.ended && !this.store.countQuads(quad.subject, quad.predicate, quad.object, quad.graph)) {
for (const pendingStream of this.pendingStreams.getPendingStreamsForQuad(quad)) {
pendingStream.push(quad);

@@ -42,0 +42,0 @@ pendingStream.emit('quad', quad);

{
"name": "rdf-streaming-store",
"version": "1.1.2",
"version": "1.1.3",
"description": "A read-only RDF/JS store that allows parallel data lookup and insertion.",

@@ -5,0 +5,0 @@ "keywords": [

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc