org.apache.jackrabbit.standalone.cli.xml
Class AbstractExportViewToFile

java.lang.Object
  extended by org.apache.jackrabbit.standalone.cli.xml.AbstractExportViewToFile
All Implemented Interfaces:
org.apache.commons.chain.Command
Direct Known Subclasses:
ExportDocViewToFile, ExportSysViewToFile

public abstract class AbstractExportViewToFile
extends Object
implements org.apache.commons.chain.Command

Export the xml view to a file


Field Summary
protected  String desFsPathKey
          target file key
protected  String noRecurseKey
          no recurse flag key
protected  String overwriteKey
          overwrite flag key
protected  String skipBinaryKey
          skip binary flag key
protected  String srcAbsPathKey
          from literal
 
Constructor Summary
AbstractExportViewToFile()
           
 
Method Summary
 boolean execute(org.apache.commons.chain.Context ctx)
          
protected abstract  void exportView(Node node, OutputStream out, boolean skipBinary, boolean noRecurse)
          Export the view to the given OutputStream
 String getDesFsPathKey()
           
 String getNoRecurseKey()
           
protected  OutputStream getOutputStream(org.apache.commons.chain.Context ctx)
           
 String getOverwriteKey()
           
 String getSkipBinaryKey()
           
 String getSrcAbsPathKey()
           
 void setDesFsPathKey(String toKey)
           
 void setNoRecurseKey(String noRecurseKey)
           
 void setOverwriteKey(String overwriteKey)
           
 void setSkipBinaryKey(String skipBinaryKey)
           
 void setSrcAbsPathKey(String fromKey)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

srcAbsPathKey

protected String srcAbsPathKey
from literal


desFsPathKey

protected String desFsPathKey
target file key


overwriteKey

protected String overwriteKey
overwrite flag key


skipBinaryKey

protected String skipBinaryKey
skip binary flag key


noRecurseKey

protected String noRecurseKey
no recurse flag key

Constructor Detail

AbstractExportViewToFile

public AbstractExportViewToFile()
Method Detail

getOutputStream

protected OutputStream getOutputStream(org.apache.commons.chain.Context ctx)
                                throws CommandException,
                                       IOException
Returns:
the OutputStream for the given file
Throws:
CommandException
IOException

getNoRecurseKey

public String getNoRecurseKey()
Returns:
the no recurse key

setNoRecurseKey

public void setNoRecurseKey(String noRecurseKey)
Parameters:
noRecurseKey - the no recurse key to set

getOverwriteKey

public String getOverwriteKey()
Returns:
the overwrite key

setOverwriteKey

public void setOverwriteKey(String overwriteKey)
Parameters:
overwriteKey - the overwrite key to set

getSkipBinaryKey

public String getSkipBinaryKey()
Returns:
the skip binary key

setSkipBinaryKey

public void setSkipBinaryKey(String skipBinaryKey)
Parameters:
skipBinaryKey - the skip binary key to set

getSrcAbsPathKey

public String getSrcAbsPathKey()
Returns:
the from key

setSrcAbsPathKey

public void setSrcAbsPathKey(String fromKey)
Parameters:
fromKey - the from key to set

getDesFsPathKey

public String getDesFsPathKey()
Returns:
the to key

setDesFsPathKey

public void setDesFsPathKey(String toKey)
Parameters:
toKey - the to key to set

execute

public final boolean execute(org.apache.commons.chain.Context ctx)
                      throws Exception

Specified by:
execute in interface org.apache.commons.chain.Command
Throws:
Exception

exportView

protected abstract void exportView(Node node,
                                   OutputStream out,
                                   boolean skipBinary,
                                   boolean noRecurse)
                            throws PathNotFoundException,
                                   IOException,
                                   RepositoryException
Export the view to the given OutputStream

Parameters:
node - the Node
out - the OutputStream
skipBinary -
noRecurse -
Throws:
RepositoryException
IOException
PathNotFoundException


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