Copyright© 2008-2022 Sitevision AB, all rights reserved.
@Requireable(value="ContentNodeUtil") public interface ContentNodeUtil
A "Content node" (e.g sv:portlet) is a Node that is located in the "content section" of a "Renderable node" (e.g. sv:page).
This utility is typically used to get the parent of a Content node, either the content parent (typically a sv:layout) or the renderable parent (typically a sv:page).
The types of a "Content node" is defined in NodeTypeUtil.isAnyContentType(Node).
The types of a "Renderable node" is defined in NodeTypeUtil.isAnyRenderableType(Node).
An instance of the Sitevision class implementing this interface can be obtained via
Utils.getContentNodeUtil().
See Utils for how to obtain an instance of the Utils interface.
| Modifier and Type | Method and Description |
|---|---|
Node |
getContentParent(Node aContentNode)
Gets the content parent of a given content node.
|
Node |
getRenderableParent(Node aContentNode)
Gets the renderable parent of a given content node.
|
Node getRenderableParent(Node aContentNode)
See NodeTypeUtil.isAnyRenderableType(Node) for what type a "Renderable node" can have.
aContentNode - a content node, typically a sv:portlet or sv:layoutNode getContentParent(Node aContentNode)
See NodeTypeUtil.isAnyContentType(Node) for what type a "Content node" can have.
Element disclaimer! The content structure of an Element (sv:moduleElement/sv:moduleElementDraft) potentially differs
in the OFFLINE and ONLINE versions.
Typically you should not use this method with aContentNode located within an Element.
aContentNode - a content node, typically a sv:portlet or sv:layoutSitevision - Portal and Content Management Made Easy
Sitevision is an advanced Java enterprise portal product and a portlet container (JSR 286) that implements Java Content Repository (JSR 283).
Copyright© 2008-2022 Sitevision AB, all rights reserved.