Permalink
Browse files

Fix some trailing whitespace issues.

  • Loading branch information...
tgvashworth committed Jan 18, 2014
1 parent 8683aa1 commit d918ff445e78e22410b4b5388e33af4a4cbcec8c
View
@@ -15,7 +15,7 @@ History
## 0.7.1
* Fixed two bugs in the sort search algorithm:
1. The first was highlighted in levelgraph-jsonld and it created the
'homes in paris' test case. It was caused by a too early close of
View
@@ -210,7 +210,7 @@ db.put([{
});
```
#### Triple Generation
#### Triple Generation
It also allows to generate a stream of triples, instead of a solution:
```javascript
@@ -234,8 +234,8 @@ It also allows to generate a stream of triples, instead of a solution:
}
}, function(err, results) {
// this will print all the 'friend of a friend triples..'
// like so: {
// subject: "lucio",
// like so: {
// subject: "lucio",
// predicate: "friend-of-a-friend",
// object: "daniele"
// }
@@ -286,7 +286,7 @@ db.get({
, filter: function filter(triple) {
return triple.object !== 'daniele';
}
}, function process(err, results) {
}, function process(err, results) {
// results will not contain any triples that
// have 'daniele' as object
});
@@ -301,7 +301,7 @@ db.search({
, filter: function filter(triple) {
return triple.object !== 'daniele';
}
}, function process(err, solutions) {
}, function process(err, solutions) {
// results will not contain any solutions that
// have { x: 'daniele' }
});
@@ -323,7 +323,7 @@ db.search({
callback(null);
}
}
}, function process(err, solutions) {
}, function process(err, solutions) {
// results will not contain any solutions that
// have { x: 'daniele' }
});
@@ -355,7 +355,7 @@ db.search({
}
});
}
}, function process(err, solutions) {
}, function process(err, solutions) {
// results will not contain any solutions that
// do not satisfy the filter
});
@@ -417,7 +417,7 @@ Variable names can also be specified, like so:
```javascript
db.nav("marco").archIn("friend").as("a").archOut("friend").archOut("friend").as("a").
solutions(function(err, friends) {
console.log(friends); // will print [{ a: "daniele" }]
});
```
@@ -440,15 +440,15 @@ db.nav("matteo").archOut("friend").bind("lucio").archOut("friend").bind("marco")
object: db.v("b")
}
}, function(err, results) {
// this will return all the 'friend of a friend triples..'
// like so: {
// subject: "lucio",
// like so: {
// subject: "lucio",
// predicate: "friend-of-a-friend",
// object: "daniele"
// }
console.log(results);
console.log(results);
});
```
@@ -461,10 +461,10 @@ db.nav("marco").archIn("friend").as("a").go("matteo").archOut("friend").as("b").
// a: "daniele",
// b: "daniele"
// }, {
// a: "lucio",
// a: "lucio",
// b: "daniele"
// }]
});
```
@@ -567,7 +567,7 @@ Here are some ideas:
* [ ] Add more database operators (grouping, filtering).
* [x] Browser support
[#10](https://github.com/mcollina/levelgraph/issues/10)
* [ ] Live searches
* [ ] Live searches
[#3](https://github.com/mcollina/node-levelgraph/issues/3)
* Extensions
* [ ] RDFa
@@ -585,7 +585,7 @@ See the [CONTRIBUTING.md](https://github.com/mcollina/levelgraph/blob/master/CON
## Credits
*LevelGraph builds on the excellent work on both the LevelUp community
and the LevelDB and Snappy teams from Google and additional contributors.
and the LevelDB and Snappy teams from Google and additional contributors.
LevelDB and Snappy are both issued under the [New BSD Licence](http://opensource.org/licenses/BSD-3-Clause).*
## Contributors
@@ -601,7 +601,7 @@ href="https://github.com/jez0990">GitHub/jez0990</a></td></tr>
## LICENSE - "MIT License"
Copyright (c) 2013 Matteo Collina (http://matteocollina.com) and LevelGraph Contributors
Copyright (c) 2013 Matteo Collina (http://matteocollina.com) and LevelGraph Contributors
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
View
@@ -18,7 +18,7 @@ var level = require("level-test")()
return;
}
var triple = {
var triple = {
subject: "s" + counts,
predicate: "p" + counts,
object: "o" + counts
View
@@ -20,7 +20,7 @@ var level = require("level-test")()
doReads();
}
var triple = {
var triple = {
subject: "s" + counts,
predicate: "p" + counts,
object: "o" + counts
@@ -41,7 +41,7 @@ var level = require("level-test")()
var num = Math.round(Math.random() * startCounts);
var triple = {
var triple = {
subject: "s" + num
};
@@ -19,7 +19,7 @@ var level = require("level-test")()
return;
}
var triple = {
var triple = {
subject: vertexes[0]
, predicate: "p"
, object: vertexes[1]
View
@@ -19,13 +19,13 @@ var level = require("level-test")()
return;
}
var triple1 = {
var triple1 = {
subject: vertexes[0],
predicate: "p",
object: vertexes[1]
}
, triple2 = {
, triple2 = {
subject: vertexes[0],
predicate: "a",
object: "b" + counts % 2
View
@@ -21,7 +21,7 @@ var level = require("level-test")()
return;
}
var triple = {
var triple = {
subject: "s" + counts,
predicate: "p" + counts,
object: "o" + counts
@@ -10,7 +10,7 @@ var level = require("level-test")()
, startTime = new Date()
, endTime
, ws
, doBench = function() {
View
@@ -31,7 +31,7 @@ function FilterStream(options) {
options.objectMode = true;
Transform.call(this, options);
var that = this;
this.once('pipe', function(source) {
View
@@ -15,7 +15,7 @@ function JoinStream(options) {
options.objectMode = true;
Transform.call(this, options);
this.triple = options.triple;
this.matcher = matcher(options.triple);
this.mask = queryMask(options.triple);
View
@@ -103,7 +103,7 @@ Navigator.prototype.contextsStream = Navigator.prototype.triplesStream;
Navigator.prototype.valuesStream = function () {
var stream, options;
stream = new NavigatorStream({
_lastElement: this._lastElement
});
View
@@ -89,7 +89,7 @@ doSortQueryPlan = function(first, second) {
, secondVariables = Object.keys(secondVariablesMask).map(function(key) {
return secondVariablesMask[key];
})
, variableKey = function(obj, variable) {
return Object.keys(obj).filter(function(key) {
return obj[key].name === variable.name;
View
@@ -64,7 +64,7 @@ function possibleIndexes(types) {
matches++;
return true;
}
if (matches === types.length) {
return true;
}
@@ -228,7 +228,7 @@ module.exports = function(joinAlgorithm) {
subject: 'daniele'
, predicate: 'newpredicate'
, object: 'abcde'
}]
}]
, stream = db.searchStream([{
subject: 'matteo',
@@ -281,7 +281,7 @@ module.exports = function(joinAlgorithm) {
subject: db.v('y'),
predicate: 'friend',
object: db.v('x'),
filter: function(triple) {
filter: function(triple) {
return triple.object !== 'matteo';
}
}], function(err, results) {
@@ -303,7 +303,7 @@ module.exports = function(joinAlgorithm) {
predicate: 'friend',
object: db.v('x')
}], {
filter: function(context, callback) {
filter: function(context, callback) {
if (context.x !== 'matteo') {
callback(null, context);
} else {
@@ -2,55 +2,55 @@ module.exports = [{
subject: 'https://my-profile.eu/people/deiu/card#me',
predicate: 'http://xmlns.com/foaf/0.1/name',
object: '"Andrei Vlad Sambra"'
}, {
}, {
subject: 'http://bblfish.net/people/henry/card#me',
predicate: 'http://xmlns.com/foaf/0.1/name',
object: '"Henry Story"'
}, {
}, {
subject: 'http://presbrey.mit.edu/foaf#presbrey',
predicate: 'http://xmlns.com/foaf/0.1/name',
object: '"Joe Presbrey"'
}, {
}, {
subject: 'http://manu.sporny.org#person',
predicate: 'http://xmlns.com/foaf/0.1/name',
object: '"Manu Sporny"'
}, {
}, {
subject: 'http://melvincarvalho.com/#me',
predicate: 'http://xmlns.com/foaf/0.1/name',
object: '"Melvin Carvalho"'
}, {
}, {
subject: 'http://manu.sporny.org#person',
predicate: 'http://xmlns.com/foaf/0.1/knows',
object: 'http://bblfish.net/people/henry/card#me'
}, {
}, {
subject: 'http://presbrey.mit.edu/foaf#presbrey',
predicate: 'http://xmlns.com/foaf/0.1/based_near',
object: 'http://dbpedia.org/resource/Cambridge'
}, {
}, {
subject: 'http://melvincarvalho.com/#me',
predicate: 'http://xmlns.com/foaf/0.1/based_near',
object: 'http://dbpedia.org/resource/Honolulu'
}, {
}, {
subject: 'http://bblfish.net/people/henry/card#me',
predicate: 'http://xmlns.com/foaf/0.1/based_near',
object: 'http://dbpedia.org/resource/Paris'
}, {
}, {
subject: 'https://my-profile.eu/people/deiu/card#me',
predicate: 'http://xmlns.com/foaf/0.1/based_near',
object: 'http://dbpedia.org/resource/Paris'
}, {
}, {
subject: 'http://manu.sporny.org#person',
predicate: 'http://xmlns.com/foaf/0.1/homepage',
object: 'http://manu.sporny.org/'
}, {
}, {
subject: 'http://manu.sporny.org#person',
predicate: 'http://xmlns.com/foaf/0.1/knows',
object: 'http://melvincarvalho.com/#me'
}, {
}, {
subject: 'http://manu.sporny.org#person',
predicate: 'http://xmlns.com/foaf/0.1/knows',
object: 'http://presbrey.mit.edu/foaf#presbrey'
}, {
}, {
subject: 'http://manu.sporny.org#person',
predicate: 'http://xmlns.com/foaf/0.1/knows',
object: 'https://my-profile.eu/people/deiu/card#me'
Oops, something went wrong.

0 comments on commit d918ff4

Please sign in to comment.