org.exoplatform.frameworks.jcr.command
Class JCRCommandHelper

java.lang.Object
  extended by org.exoplatform.frameworks.jcr.command.JCRCommandHelper

public class JCRCommandHelper
extends java.lang.Object

Created by The eXo Platform SAS.

Version:
$Id: JCRCommandHelper.java 35179 2009-08-07 13:58:20Z pnedonosko $
Author:
Gennady Azarenkov

Constructor Summary
JCRCommandHelper()
           
 
Method Summary
static javax.jcr.Node createResourceFile(javax.jcr.Node parentNode, java.lang.String relPath, java.lang.Object data, java.lang.String mimeType)
          creates nt:file node and fills it with incoming data
static javax.jcr.Node getNtResourceRecursively(javax.jcr.Node node)
          traverses incoming node trying to find primary nt:resource node
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JCRCommandHelper

public JCRCommandHelper()
Method Detail

createResourceFile

public static javax.jcr.Node createResourceFile(javax.jcr.Node parentNode,
                                                java.lang.String relPath,
                                                java.lang.Object data,
                                                java.lang.String mimeType)
                                         throws java.lang.Exception
creates nt:file node and fills it with incoming data

Parameters:
parentNode -
relPath -
data -
mimeType -
Returns:
Throws:
java.lang.Exception

getNtResourceRecursively

public static javax.jcr.Node getNtResourceRecursively(javax.jcr.Node node)
                                               throws javax.jcr.ItemNotFoundException,
                                                      javax.jcr.RepositoryException
traverses incoming node trying to find primary nt:resource node

Parameters:
node -
Returns:
nt:resource node
Throws:
javax.jcr.ItemNotFoundException - if no such node found
javax.jcr.RepositoryException


Copyright © 2012 eXo Platform SAS. All Rights Reserved.