public class TargetSection extends Object
TargetMatchGroup
and represents the Subjects, Resources, Actions, and Environments
sections of an XACML Target. This section may apply to any request.Constructor and Description |
---|
TargetSection(List matchGroups,
int matchType,
int xacmlVersion)
Constructor that takes a group and a version.
|
Modifier and Type | Method and Description |
---|---|
void |
encode(OutputStream output)
Encodes this
TargetSection into its XML representation
and writes this encoding to the given OutputStream with
no indentation. |
void |
encode(OutputStream output,
Indenter indenter)
Encodes this
TargetSection into its XML representation and
writes this encoding to the given OutputStream with
indentation. |
static TargetSection |
getInstance(Node root,
int matchType,
PolicyMetaData metaData)
Creates a
Target by parsing a node. |
List |
getMatchGroups()
Returns the
TargetMatchGroup s contained in this group. |
MatchResult |
match(EvaluationCtx context)
Determines whether this
TargetSection matches
the input request (whether it is applicable). |
boolean |
matchesAny()
Returns whether this section matches any request.
|
public TargetSection(List matchGroups, int matchType, int xacmlVersion)
matchGroups
- a possibly null List
of
TargetMatchGroup
sxacmlVersion
- the version XACML being usedmatchType
- public static TargetSection getInstance(Node root, int matchType, PolicyMetaData metaData) throws ParsingException
Target
by parsing a node.root
- the node to parse for the Target
matchType
- metaData
- Target
constructed by parsingParsingException
- if the DOM node is invalidpublic List getMatchGroups()
TargetMatchGroup
s contained in this group.List
of TargetMatchGroup
spublic boolean matchesAny()
public MatchResult match(EvaluationCtx context)
TargetSection
matches
the input request (whether it is applicable).context
- the representation of the requestpublic void encode(OutputStream output)
TargetSection
into its XML representation
and writes this encoding to the given OutputStream
with
no indentation.output
- a stream into which the XML-encoded data is writtenpublic void encode(OutputStream output, Indenter indenter)
TargetSection
into its XML representation and
writes this encoding to the given OutputStream
with
indentation.output
- a stream into which the XML-encoded data is writtenindenter
- an object that creates indentation stringsCopyright © 2023 JBoss by Red Hat. All rights reserved.