I need to import an OWL file that includes SWRL rules from Protégé and edit it in my own program which is written in C#. I used the OwlDotNetApi to import the file from Protégé, which worked fine. How can I work with the imported data? I have seen special classes for OWL classes and so on but nothing for SWRL. Is there any support for SWRL, or do I need to use another API? Is there a matching API at all?
Asked
Active
Viewed 997 times
0
-
SWRL is an extension to OWL (though many implementations support it), so it's not *too* surprising if a given OWL library doesn't support it. – Joshua Taylor Aug 01 '14 at 14:08
-
OK, thanks for your comment. Do you know any library for C# that supports SWRL? – hshUser Aug 04 '14 at 06:04
-
I don't really work in C#, so I don't have any exposure, unfortunately. This particular question is useful in general, but it's off topic for Stack Overflow, as "**Questions asking us to recommend or find a book, tool, software library, tutorial or other off-site resource are off-topic for Stack Overflow** as they tend to attract opinionated answers and spam." You might have better luck with answers.semanticweb.com. That said, the RDF serialization of SWRL rules isn't too complicated, and it shouldn't be too hard to work with them based on that. – Joshua Taylor Aug 04 '14 at 19:55
-
For reference, duplicated at http://answers.semanticweb.com/questions/29665/swrl-library-support-for-net-c. – Joshua Taylor Aug 06 '14 at 15:46
1 Answers
0
With dotNetRdf you can use rules with N3 syntax to reason :
{ ?x a ex:Car } => { ?x a ex:Vehicle }
So, as suggested by Joshua Taylor, you could first serialize your SWRL rules to N3 syntax and then use the reasoner.