Wednesday 23 May 2007

Predicate Library Summary

A summary of the built-in DeepWeaver predicates and their expected functions.
  • allBoxIter(A)
  • args(A,B) A call to method A has a list of argument objects B
  • assign(A,B,L) Variable A is assigned value B at location L
  • between(a,z,X,B) X is a codeblock between ground/atomic codeblocks a and z if boolean B is true. If B is false, then X may or may not be between a and z.
  • body(a,B) Finds a method body location B in an atom or ground variable a, the code block location may be in only non-abstract, real method bodys which should be included in a.
  • call(A,B,C) Instruction A calls method B which takes some sort of object C.
  • class(A) A is a class. Returns any class if A is unbound
  • defBoxes(a,B) Finds a definition box B within unit a
  • doms(A,B,C)
  • element(A,N,B)
  • end(a,B) B is the soot-generated final piece of code of method a. See start.
  • forall(A,B) Standard Prolog forall, for all cases of A, B is true.
  • jump(A) Returns a statment which causes a jump in the code
  • target(A,L) Returns the Location of a jump in the code at statement A
  • method(A,B)
  • methodMatches(A,B)
  • member(A,B) Standard Prolog member, returns true if A is an element of list B
  • name(A,B)
  • not(X) Standard Prolog negation, if X cannot be proved, this statement returns true.
  • parentMethod(a,B) Gets the entire parent method of atom or ground variable a as a codeblock bound to B.
  • path(A,B,C)
  • precedes(A,B) Code block A occurs at or before Code block B in a method (or logical Soot code flow)
  • pred(A,B)
  • print(A) Prints the type and toString() result of A
  • sameValue(A,B)
  • sootmethod(A,B)
  • start(a,B) B is the soot-generated first code piece of method a. Note that this is soot generated, so the start block includes all code that comes between the first method call, loop block, or other non-trivial piece of code.
  • statement(A,B) A is the location of the statement that results in B.
  • succ(A,B) Same as pred(B,A)
  • type(A,a) Restricts A to be of the same type as a.
  • units(A,B)
  • unused(A)
  • useboxes(A,B)
  • uses(A,L) Code block A is used at location L.
  • value(A,B) B is the value of variable A, returned as a CodeValue. Common usage: value(A,X), value(B,X).

No comments: