public final class WorkerHelper extends Object
Modifier and Type | Method and Description |
---|---|
static void |
closeRTX(INodeReadTrx rtx,
ISession ses)
This method closes all open treetank connections concerning a
NodeReadTrx.
|
static void |
closeWTX(boolean abortTransaction,
INodeWriteTrx wtx,
ISession ses)
This method closes all open treetank connections concerning a
NodeWriteTrx.
|
StringBuilder |
createStringBuilderObject()
This method creates a new StringBuilder reference
|
static WorkerHelper |
getInstance()
This method return the singleton instance.
|
static XMLSerializer |
serializeXML(ISession session,
OutputStream out,
boolean serializeXMLDec,
boolean serializeRest,
Long revision)
This method creates a new XMLSerializer reference
|
static XMLSerializer |
serializeXML(ISession session,
OutputStream out,
boolean serializeXMLDec,
boolean serializeRest,
Long nodekey,
Long revision)
This method creates a new XMLSerializer reference
|
static void |
shredInputStream(INodeWriteTrx wtx,
InputStream value,
EShredderInsert child)
Shreds a given InputStream
|
EIdAccessType |
validateAccessType(String accessType)
This method checks the variable URL path after the node id resource (e.g.
|
public static void shredInputStream(INodeWriteTrx wtx, InputStream value, EShredderInsert child)
wtx
- current write transaction referencevalue
- InputStream to be shredpublic static XMLSerializer serializeXML(ISession session, OutputStream out, boolean serializeXMLDec, boolean serializeRest, Long revision)
session
- Associated session.out
- OutputStreamserializeXMLDec
- specifies whether XML declaration should be shownserializeRest
- specifies whether node id should be shownpublic static XMLSerializer serializeXML(ISession session, OutputStream out, boolean serializeXMLDec, boolean serializeRest, Long nodekey, Long revision)
session
- Associated session.out
- OutputStreamserializeXMLDec
- specifies whether XML declaration should be shownserializeRest
- specifies whether node id should be shownpublic StringBuilder createStringBuilderObject()
public static void closeWTX(boolean abortTransaction, INodeWriteTrx wtx, ISession ses) throws TTException
abortTransaction
- true
if the transaction has to be aborted, false
otherwise.wtx
- INodeWriteTrx to be closedses
- ISession to be closedTreetankException
TTException
public static void closeRTX(INodeReadTrx rtx, ISession ses) throws TTException
rtx
- INodeReadTrx to be closedses
- ISession to be closedTTException
public EIdAccessType validateAccessType(String accessType)
EIdAccessType
.accessType
- The access type as String value encoded in the URL request.public static WorkerHelper getInstance()
Copyright © 2013. All Rights Reserved.