Class AbacReference
java.lang.Object
edu.internet2.middleware.grouper.abac.AbacReference
Represents a reference extracted from an ABAC/JEXL script for visualization purposes.
Can be a leaf reference (group, attribute, row) or a compound node grouping
OR/AND subexpressions.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic enum -
Constructor Summary
ConstructorsConstructorDescriptionAbacReference(AbacReference.Connective compoundConnective, boolean negated, AbacReference.Connective parentConnective) Constructor for compound references (OR or AND subexpressions).AbacReference(AbacReference.RefType refType, String name, String value, boolean negated, AbacReference.Connective connective) Constructor for leaf references (group, attribute, row). -
Method Summary
Modifier and TypeMethodDescriptionvoidaddChild(AbacReference child) Returns a human-readable display label for this reference.Returns a unique identifier for this reference, suitable for use as a node ID.getName()intgetValue()booleanbooleanbooleanbooleanbooleanbooleanvoidsetAttributeNullCheck(boolean attributeNullCheck) voidsetAttributeValues(List<String> attributeValues) voidsetConnective(AbacReference.Connective connective) voidsetContainsSubject(boolean containsSubject) voidsetDisplayDescription(String displayDescription) voidsetMemberOfAny(boolean memberOfAny) voidsetNegated(boolean negated) voidsetPopulationCount(int populationCount) voidsetRowInnerOr(boolean rowInnerOr) voidsetTerseUnsupported(boolean terseUnsupported)
-
Constructor Details
-
AbacReference
public AbacReference(AbacReference.RefType refType, String name, String value, boolean negated, AbacReference.Connective connective) Constructor for leaf references (group, attribute, row).- Parameters:
refType- the type of reference (group, attribute, or row)name- the group name, attribute alias, or row aliasvalue- for attributes: the value condition (or null); for rows: the filter expression; for groups: nullnegated- whether this reference is negated (preceded by NOT in the script)connective- the parent connective context (AND or OR)
-
AbacReference
public AbacReference(AbacReference.Connective compoundConnective, boolean negated, AbacReference.Connective parentConnective) Constructor for compound references (OR or AND subexpressions).- Parameters:
compoundConnective- the internal connective of this compound (OR or AND)negated- whether this compound is negatedparentConnective- how this compound connects to its parent (AND or OR)
-
-
Method Details
-
getRefType
-
getName
-
getValue
-
isNegated
public boolean isNegated() -
setNegated
public void setNegated(boolean negated) -
getConnective
-
setConnective
-
getChildren
-
addChild
-
getPopulationCount
public int getPopulationCount() -
setPopulationCount
public void setPopulationCount(int populationCount) -
getDisplayDescription
-
setDisplayDescription
-
isContainsSubject
public boolean isContainsSubject() -
setContainsSubject
public void setContainsSubject(boolean containsSubject) -
isMemberOfAny
public boolean isMemberOfAny() -
setMemberOfAny
public void setMemberOfAny(boolean memberOfAny) -
getAttributeValues
-
setAttributeValues
-
isAttributeNullCheck
public boolean isAttributeNullCheck() -
setAttributeNullCheck
public void setAttributeNullCheck(boolean attributeNullCheck) -
isTerseUnsupported
public boolean isTerseUnsupported() -
setTerseUnsupported
public void setTerseUnsupported(boolean terseUnsupported) -
isRowInnerOr
public boolean isRowInnerOr() -
setRowInnerOr
public void setRowInnerOr(boolean rowInnerOr) -
computeId
Returns a unique identifier for this reference, suitable for use as a node ID. The negated flag is folded into the prefix so a positive and a negated reference with the same description (e.g. positive "affiliationActive" and the post-strip rendering of "!affiliationActive" elsewhere in the same script) do not collapse to the same graph node. -
computeDisplayLabel
Returns a human-readable display label for this reference.
-