public interface Principal extends ActsForParam
| Modifier and Type | Method and Description |
|---|---|
boolean |
hasVariables()
Does the label contain any variables at all? This includes variables
that are in bounds of arg labels.
|
boolean |
isBottomPrincipal() |
boolean |
isTopPrincipal() |
PathMap |
labelCheck(JifContext A,
LabelChecker lc)
Label check the principal, which will determine how much information may be
gained if the principal is evaluated at runtime.
|
Principal |
simplify()
Simplify the label, using the actsfor relation if needed
|
Principal |
subst(LabelSubstitution labelSubst) |
java.util.List<polyglot.types.Type> |
throwTypes(polyglot.types.TypeSystem ts)
If the principal is runtime representable, when it is evaluated at
runtime it may throw exceptions.
|
java.util.Set<Variable> |
variables()
The set of variables that this label contains including variables contained
in upper bounds of arg labels.
|
toJavaisCanonical, isRuntimeRepresentable, typeSystemPrincipal subst(LabelSubstitution labelSubst) throws polyglot.types.SemanticException
subst in interface ActsForParamlabelSubst - The LabelSubstitution to apply to this
principalpolyglot.types.SemanticExceptionPathMap labelCheck(JifContext A, LabelChecker lc)
boolean{Alice:} secret = ...;
final principal{Alice:} p = secret?Bob:Chuck;
boolean{} leak = false;
if (p actsfor Bob) { // evaluation of p reveals
// information at level {Alice:}
leak = true;
}
java.util.List<polyglot.types.Type> throwTypes(polyglot.types.TypeSystem ts)
boolean hasVariables()
java.util.Set<Variable> variables()
boolean isTopPrincipal()
boolean isBottomPrincipal()
Principal simplify()
simplify in interface ActsForParam