public class CreateRestViewPipe extends XsltPipe
RestListener
.
expected format after performing the XSLT transformation:
<page title="...">
...
</page>
example:
<page title="Generate WSDL">
<script type="text/javascript">
//<![CDATA[
function changeBg(obj,isOver) {
var color1="#8D0022";
var color2="#b4e2ff";
if (isOver) {
obj.style.backgroundColor=color1;
obj.style.color=color2;
} else {
obj.style.backgroundColor=color2;
obj.style.color=color1;
}
}
//]]>
</script>
<form method="post" action="" enctype="multipart/form-data">
<table border="0" width="100%">
<tr>
<td>Upload xsd/zip file</td>
<td>
<input type="file" name="file" value=""/>
</td>
</tr>
<tr>
<td/>
<td>
<input type="submit" onmouseover="changeBg(this,true);" onmouseout="changeBg(this,false);" value="send"/>
</td>
</tr>
</table>
</form>
</page>
example:
<page title="Show Generated WSDL">
<table>
<caption class="caption">Files</caption>
<tr>
<th class="colHeader">Name</th>
<th class="colHeader">Size</th>
<th class="colHeader">Date</th>
<th class="colHeader">Time</th>
<th class="colHeader">as</th>
</tr>
<tr class="filterRow">
<td class="filterRow">GetCollectionDisbursementAccountInformationOnPolicy_2_concrete.wsdl</td>
<td class="filterRow">25269</td>
<td class="filterRow">28-05-15</td>
<td class="filterRow">11:33:30</td>
<td class="filterRow">
<a href="../FileViewerServlet?resultType=xml&fileName=C:\Temp\GetCollectionDisbursementAccountInformationOnPolicy_2_concrete.wsdl">xml</a>
<a href="../FileViewerServlet?resultType=text&fileName=C:\Temp\GetCollectionDisbursementAccountInformationOnPolicy_2_concrete.wsdl">text</a>
</td>
</tr>
<tr class="rowEven">
<td class="filterRow">GetCollectionDisbursementAccountInformationOnPolicy_2_concrete.zip</td>
<td class="filterRow">5759</td>
<td class="filterRow">28-05-15</td>
<td class="filterRow">11:33:30</td>
<td class="filterRow">
<a href="../FileViewerServlet?resultType=zip&fileName=C:\Temp\GetCollectionDisbursementAccountInformationOnPolicy_2_concrete.zip">zip</a>
</td>
</tr>
</table>
</page>
AUTOMATIC_STREAMING
parameterNamesMustBeUnique
log
LONG_DURATION_MONITORING_EVENT, MESSAGE_SIZE_MONITORING_EVENT, PIPE_EXCEPTION_MONITORING_EVENT
Constructor and Description |
---|
CreateRestViewPipe() |
Modifier and Type | Method and Description |
---|---|
void |
configure()
The
configure() method instantiates a transformer for the specified
XSL. |
PipeRunResult |
doPipe(Message input,
PipeLineSession session)
This is where the action takes place.
|
String |
getContentType() |
void |
setContentType(String string)
content type of the servlet response
|
addParameter, afterPropertiesSet, canProvideOutputStream, canStreamToNextPipe, createXsltSender, getNamespaceDefs, getParameterList, getSessionKey, getXpathExpression, provideOutputStream, setDisableOutputEscaping, setHandleLexicalEvents, setIndentXml, setName, setNamespaceAware, setNamespaceDefs, setOmitXmlDeclaration, setOutputType, setRemoveNamespaces, setSessionKey, setSkipEmptyTags, setStreamingXslt, setStyleSheetCacheSize, setStyleSheetName, setStyleSheetNameSessionKey, setXpathExpression, setXslt2, setXsltVersion, start, stop, supportsOutputStreamPassThrough
getNextPipe, getTargetStream, isStreamingActive, provideOutputStream, setStreamingActive
getParameterValue, setIfParam, setIfValue, setOnlyIfSessionKey, setOnlyIfValue, setSkipOnEmptyInput, setUnlessSessionKey, setUnlessValue, skipPipe
consumesSessionVariable, createBean, findForward, getAdapter, getEventSourceName, getForwards, getInSizeStatDummyObject, getOutSizeStatDummyObject, hasSizeStatistics, registerEvent, registerForward, setApplicationContext, setChompCharSize, setDurationThreshold, setElementToMove, setElementToMoveChain, setElementToMoveSessionKey, setEmptyInputReplacement, setGetInputFromFixedValue, setGetInputFromSessionKey, setHideRegex, setLocker, setLogIntermediaryResults, setMaxThreads, setPreserveInput, setRemoveCompactMsgNamespaces, setRestoreMovedElements, setSecLogSessionKeys, setSizeStatistics, setStoreResultInSessionKey, setWriteToSecLog, throwEvent
configureTransactionAttributes, isTransacted, isTransacted, setTransacted, setTransactionTimeout
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getChompCharSize, getDurationThreshold, getElementToMove, getElementToMoveChain, getElementToMoveSessionKey, getEmptyInputReplacement, getGetInputFromFixedValue, getGetInputFromSessionKey, getLocker, getSecLogSessionKeys, getStoreResultInSessionKey, isPreserveInput, isRemoveCompactMsgNamespaces, isRestoreMovedElements, isWriteToSecLog, setPipeLine, throwEvent
getMaxThreads
getName
getApplicationContext, getName
getConfigurationClassLoader
getName
getTransactionAttribute, getTransactionTimeout, getTxDef, setTransactionAttribute
public void configure() throws ConfigurationException
XsltPipe
configure()
method instantiates a transformer for the specified
XSL. If the stylesheetname cannot be accessed, a ConfigurationException is thrown.configure
in interface IConfigurable
configure
in interface IPipe
configure
in class XsltPipe
ConfigurationException
public PipeRunResult doPipe(Message input, PipeLineSession session) throws PipeRunException
IPipe
FixedResultPipe
, the Pipe
can schedule the input to be closed at session exit, by calling Message.closeOnCloseOf(PipeLineSession, String)
This allows the previous Pipe to release any resources (e.g. connections) that it might have kept open
until the message was consumed. Doing so avoids connections leaking from pools, while it enables
efficient streaming processing of data while it is being read from a stream.doPipe
in interface IPipe
doPipe
in class XsltPipe
PipeRunException
public void setContentType(String string)
public String getContentType()
Copyright © 2023 Frank!Framework. All rights reserved.