Module com.github.weisj.jsvg
Class BaseContainerNode<E>
- java.lang.Object
-
- com.github.weisj.jsvg.nodes.AbstractSVGNode
-
- com.github.weisj.jsvg.nodes.container.BaseContainerNode<E>
-
- Direct Known Subclasses:
CommonRenderableContainerNode,ContainerNode,TextContainer
public abstract class BaseContainerNode<E> extends AbstractSVGNode implements Container<E>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static classBaseContainerNode.CategoryCheckResult
-
Field Summary
Fields Modifier and Type Field Description private static booleanEXHAUSTIVE_CHECKprivate static java.util.logging.LoggerLOGGER
-
Constructor Summary
Constructors Constructor Description BaseContainerNode()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected booleanacceptChild(@Nullable java.lang.String id, @NotNull SVGNode node)Determine whether the container accepts thisSVGNodeas a child.voidaddChild(@Nullable java.lang.String id, @NotNull SVGNode node)protected abstract voiddoAdd(@NotNull SVGNode node)private BaseContainerNode.CategoryCheckResultdoIntersect(Category[] requested, Category[] provided)protected booleanisAcceptableType(@NotNull SVGNode node)-
Methods inherited from class com.github.weisj.jsvg.nodes.AbstractSVGNode
addContent, build, id, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.github.weisj.jsvg.nodes.prototype.Container
children, childrenOfType
-
-
-
-
Field Detail
-
EXHAUSTIVE_CHECK
private static final boolean EXHAUSTIVE_CHECK
- See Also:
- Constant Field Values
-
LOGGER
private static final java.util.logging.Logger LOGGER
-
-
Method Detail
-
addChild
public final void addChild(@Nullable @Nullable java.lang.String id, @NotNull @NotNull SVGNode node)
-
doAdd
protected abstract void doAdd(@NotNull @NotNull SVGNode node)
-
acceptChild
protected boolean acceptChild(@Nullable @Nullable java.lang.String id, @NotNull @NotNull SVGNode node)Determine whether the container accepts thisSVGNodeas a child. By default, this will always report true but subclasses may choose to reject certain types of nodes.- Parameters:
id- the id of the nodenode- the node itself- Returns:
- whether the node can be inserted as a child.
-
isAcceptableType
protected boolean isAcceptableType(@NotNull @NotNull SVGNode node)
-
doIntersect
private BaseContainerNode.CategoryCheckResult doIntersect(Category[] requested, Category[] provided)
-
-