org.apache.jackrabbit.ocm.repository
Class NodeUtil

java.lang.Object
  extended by org.apache.jackrabbit.ocm.repository.NodeUtil

public class NodeUtil
extends Object

Utility class for managing JCR nodes.

Version:
$Id: Exp $
Author:
Lombart Christophe

Field Summary
static String PATH_SEPARATOR
          Item path separator
 
Constructor Summary
NodeUtil()
           
 
Method Summary
static String getNodeName(String path)
          Get the node name
static String getParentPath(String path)
          Get the parent path
static boolean isValidPath(String path)
          Check if a path is valid
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PATH_SEPARATOR

public static final String PATH_SEPARATOR
Item path separator

See Also:
Constant Field Values
Constructor Detail

NodeUtil

public NodeUtil()
Method Detail

isValidPath

public static boolean isValidPath(String path)
Check if a path is valid

Parameters:
path - The path to validate
Returns:
true if the path is valid, else false

getParentPath

public static String getParentPath(String path)
                            throws ObjectContentManagerException
Get the parent path

Parameters:
path - The path from wich the parent path has to be returned
Returns:
The parent path
Throws:
ObjectContentManagerException - when the path is invalid

getNodeName

public static String getNodeName(String path)
                          throws ObjectContentManagerException
Get the node name

Parameters:
path - The path from which the node name has to be retrieved
Returns:
The node name
Throws:
ObjectContentManagerException - when the path is invalid


Copyright © 2004-2008 The Apache Software Foundation. All Rights Reserved.