Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bbop-graph-noctua

Package Overview
Dependencies
Maintainers
1
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bbop-graph-noctua - npm Package Compare versions

Comparing version 0.0.26 to 0.0.27

tests/minerva-07.json

23

lib/edit.js

@@ -904,2 +904,3 @@ /**

var pid = fact['property'];
var plbl = fact['property-label'];
var anns = fact['annotations'] || [];

@@ -918,2 +919,6 @@ if( sid && oid && pid ){

}
// Add edge if possible.
if( plbl ){
new_edge.label(plbl);
}

@@ -2202,2 +2207,3 @@ // Add and ready to return edge.

this._id = bbop.uuid();
this._predicate_label = null;

@@ -2224,2 +2230,3 @@ this._annotations = [];

new_clone._id = anchor._id;
new_clone._predicate_label = anchor._predicate_label;

@@ -2243,3 +2250,3 @@ // Base class stuff.

/**
* Access to the "id".
* Access to the immutable "id".
*

@@ -2288,2 +2295,16 @@ * @returns {String} string

/**
* Access to the mutable "label" for the edge.
*
* @param {String} [value] - lbl
* @returns {String|null} string
*/
noctua_edge.prototype.label = function(lbl){
if( lbl === null || typeof(lbl) === 'string' ){
this._predicate_label = lbl;
}
return this._predicate_label;
};
// Add generic bulk annotation operations to: graph, edge, and node.

@@ -2290,0 +2311,0 @@ each([noctua_graph, noctua_node, noctua_edge], function(constructr){

2

package.json
{
"name": "bbop-graph-noctua",
"version": "0.0.26",
"version": "0.0.27",
"license": "BSD-3-Clause",

@@ -5,0 +5,0 @@ "description": "A subclass of bbop-graph that layers on a complete annotation and graph editing model for the Noctua set of tools.",

@@ -866,2 +866,19 @@ ////

describe("try looking at edge labels in minerva wire protocol", function(){
it('edge labels during creation', function(){
var raw_resp = require('./minerva-07.json');
var g = new model.graph();
g.load_data_basic(raw_resp['data']);
//g.report_state(); console.log('');
// Make sure we're starting at a sane point...
var an_edge = g.all_edges()[0];
assert.isNotNull(an_edge.label(), "label is there");
assert.notEqual(an_edge.id(), an_edge.label(), "label != id");
});
});
// var assert = require('chai').assert;

@@ -868,0 +885,0 @@ // var model = new require('..');

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