Created
August 7, 2012 22:31
-
-
Save niclashoyer/3290079 to your computer and use it in GitHub Desktop.
SPARQL Query for SHI3LD Access Policy Selection
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PREFIX dc: <http://purl.org/dc/elements/1.1/> | |
PREFIX s4ac: <http://ns.inria.fr/s4ac/v2#> | |
SELECT DISTINCT | |
?m ?p ?title ?protected ?privilege ?acs ?type ?query | |
WHERE {{ | |
BIND('1' AS ?m) | |
?p a s4ac:AccessPolicy ; | |
s4ac:appliesTo ?protected . | |
OPTIONAL { | |
?p dc:title ?title | |
} | |
} UNION { | |
BIND('2' AS ?m) | |
?p a s4ac:AccessPolicy ; | |
s4ac:hasAccessPrivilege [ a ?privilege ] . | |
} UNION { | |
BIND('3' AS ?m) | |
?p a s4ac:AccessPolicy ; | |
s4ac:hasAccessConditionSet ?acs . | |
?acs a s4ac:AccessConditionSet ; | |
a ?type . | |
FILTER(?type != s4ac:AccessConditionSet) | |
} UNION { | |
BIND('4' AS ?m) | |
?acs a s4ac:AccessConditionSet ; | |
s4ac:hasAccessCondition [ | |
s4ac:hasQueryAsk ?query | |
] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment