ElementPolicy.JoinableElementPolicy
public interface ElementPolicy
Element policies are applied after
attribute policies
so
they can be used to add extra attributes.
HtmlPolicyBuilder.allowElements(ElementPolicy, String...)
Modifier and Type | Interface | Description |
---|---|---|
static interface |
ElementPolicy.JoinableElementPolicy |
|
static class |
ElementPolicy.Util |
Utilities for working with element policies.
|
Modifier and Type | Field | Description |
---|---|---|
static ElementPolicy |
IDENTITY_ELEMENT_POLICY |
An element policy that returns the element unchanged.
|
static ElementPolicy |
REJECT_ALL_ELEMENT_POLICY |
An element policy that rejects all elements.
|
Modifier and Type | Method | Description |
---|---|---|
java.lang.String |
apply(java.lang.String elementName,
java.util.List<java.lang.String> attrs) |
static final ElementPolicy IDENTITY_ELEMENT_POLICY
static final ElementPolicy REJECT_ALL_ELEMENT_POLICY
@Nullable java.lang.String apply(java.lang.String elementName, java.util.List<java.lang.String> attrs)
elementName
- the lower-case element name.attrs
- a list of alternating attribute names and values.
The list may be added to or removed from. When removing, be
careful to remove both the name and its associated value.null
to disallow the element, or the adjusted element name.Copyright © 2019 OWASP. All rights reserved.