Class NodeTypeUtil
- java.lang.Object
-
- org.exoplatform.services.jcr.webdav.util.NodeTypeUtil
-
public class NodeTypeUtil extends Object
Created by The eXo Platform SAS.- Version:
- $Id: $
- Author:
- Vitaly Guly - gavrikvetal@gmail.com
-
-
Constructor Summary
Constructors Constructor Description NodeTypeUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidcheckContentResourceType(javax.jcr.nodetype.NodeType contentNodeType)Cheks if the NodeType of content node extends nt:resource.static StringgetContentNodeType(String contentNodeTypeHeader)Returns the NodeType of content node according to the Content-NodeType header.static ArrayList<String>getMixinTypes(String mixinTypes)Returns the list of node mixins.static StringgetNodeType(String nodeTypeHeader, String defaultNodeType, Set<String> allowedNodeTypes)Returns parsed nodeType obtained from node-type header.
-
-
-
Method Detail
-
getNodeType
public static String getNodeType(String nodeTypeHeader, String defaultNodeType, Set<String> allowedNodeTypes) throws javax.jcr.nodetype.NoSuchNodeTypeException
Returns parsed nodeType obtained from node-type header. This method is unified for files and folders.- Parameters:
nodeTypeHeader-defaultNodeType-allowedNodeTypes-- Returns:
- Throws:
javax.jcr.nodetype.NoSuchNodeTypeException- is thrown if node-type header contains not allowed node type
-
getContentNodeType
public static String getContentNodeType(String contentNodeTypeHeader)
Returns the NodeType of content node according to the Content-NodeType header.- Parameters:
contentNodeTypeHeader- Content-NodeType header- Returns:
- Nodetype
-
checkContentResourceType
public static void checkContentResourceType(javax.jcr.nodetype.NodeType contentNodeType) throws javax.jcr.nodetype.NoSuchNodeTypeExceptionCheks if the NodeType of content node extends nt:resource.- Parameters:
contentNodeType- Content-NodeType header- Throws:
javax.jcr.nodetype.NoSuchNodeTypeException-NoSuchNodeTypeException
-
-