Class RBACProcessor

java.lang.Object
it.uniroma2.art.semanticturkey.rbac.RBACProcessor

public class RBACProcessor extends Object
  • Constructor Details

  • Method Details

    • initializeResources

      public void initializeResources(File roleFile) throws alice.tuprolog.InvalidTheoryException, TheoryNotFoundException
      Throws:
      alice.tuprolog.InvalidTheoryException
      TheoryNotFoundException
    • getRole

      public String getRole()
    • getCapabilitiesAsStringList

      public List<String> getCapabilitiesAsStringList() throws alice.tuprolog.MalformedGoalException, alice.tuprolog.NoSolutionException, alice.tuprolog.NoMoreSolutionException
      This method returns the capabilities terms as a list of String. It is better to use this method rather than getCapabilitiesAsTermList() since the method toString of the class Term serializes the "wildcard" _ followed by a so-called fingerprint (see Var. This fingerprint is increased each time, so eventual compare of string capabilities to term capabilities will fail due to this fingerprint even if the capabilities are the same.
      Returns:
      Throws:
      alice.tuprolog.MalformedGoalException
      alice.tuprolog.NoSolutionException
      alice.tuprolog.NoMoreSolutionException
    • runInterpreter

      public void runInterpreter() throws Exception
      Throws:
      Exception
    • authorizes

      public boolean authorizes(String goal) throws alice.tuprolog.MalformedGoalException, HaltedEngineException, HarmingGoalException
      Throws:
      alice.tuprolog.MalformedGoalException
      HaltedEngineException
      HarmingGoalException
    • main

      public static void main(String[] args) throws Exception
      Throws:
      Exception