Package de.l3s.boilerpipe.sax
Class TagActionMap
- java.lang.Object
-
- java.util.AbstractMap<K,V>
-
- java.util.HashMap<java.lang.String,TagAction>
-
- de.l3s.boilerpipe.sax.TagActionMap
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Cloneable,java.util.Map<java.lang.String,TagAction>
- Direct Known Subclasses:
DefaultTagActionMap
public abstract class TagActionMap extends java.util.HashMap<java.lang.String,TagAction>
Base class for definition a set ofTagActions that are to be used for the HTML parsing process.- See Also:
DefaultTagActionMap, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description TagActionMap()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddTagAction(java.lang.String tag, TagAction action)Adds a particularTagActionfor a given tag.protected voidsetTagAction(java.lang.String tag, TagAction action)Sets a particularTagActionfor a given tag.-
Methods inherited from class java.util.HashMap
clear, clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
-
-
-
-
Method Detail
-
setTagAction
protected void setTagAction(java.lang.String tag, TagAction action)Sets a particularTagActionfor a given tag. Any existing TagAction for that tag will be removed and overwritten.- Parameters:
tag- The tag (will be stored internally 1. as it is, 2. lower-case, 3. upper-case)action- TheTagAction
-
addTagAction
protected void addTagAction(java.lang.String tag, TagAction action)Adds a particularTagActionfor a given tag. If a TagAction already exists for that tag, a chained action, consisting of the previous and the newTagActionis created.- Parameters:
tag- The tag (will be stored internally 1. as it is, 2. lower-case, 3. upper-case)action- TheTagAction
-
-