Skip to content
This repository was archived by the owner on Oct 8, 2020. It is now read-only.

Commit aa66bd9

Browse files
Added return type RDD[Triple] for better alignment with other layers.
1 parent a8be953 commit aa66bd9

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

sansa-inference-spark/src/main/scala/net/sansa_stack/inference/spark/forwardchaining/triples/ForwardRuleReasoner.scala

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,16 @@ import scala.collection.mutable
1515
*/
1616
trait ForwardRuleReasoner extends Profiler {
1717

18+
/**
19+
* Applies forward chaining to the given RDD of RDF triples and returns a new
20+
* RDD of RDF triples that contains all additional triples based on the underlying
21+
* set of rules.
22+
*
23+
* @param triples the RDF triples
24+
* @return the materialized set of RDF triples
25+
*/
26+
def apply(triples: RDD[Triple]) : RDD[Triple] = apply(RDFGraph(triples)).triples
27+
1828
/**
1929
* Applies forward chaining to the given RDF graph and returns a new RDF graph that contains all additional
2030
* triples based on the underlying set of rules.

0 commit comments

Comments
 (0)