PutSystemDateInSession extends FixedForwardPipe { @IbisDoc({"key of session variable to store systemdate in", "systemdate"}) public void setSessionKey(String newSessionKey) { sessionKey = newSessionKey; }  @Override void configure(); @Override PipeRunResult doPipe(Message message, IPipeLineSession session); @IbisDoc({"key of session variable to store systemdate in", "systemdate"}) void setSessionKey(String newSessionKey); String getSessionKey(); @IbisDoc({"format to store date in", "fullisoformat: yyyy-mm-dd't'hh:mm:sszzz"}) void setDateFormat(String rhs); String getDateFormat(); @IbisDoc({"the time zone to use for the formatter", "the default time zone for the jvm"}) void setTimeZone(String timeZone); @IbisDoc({"set to a time in millisecond to create a value that is different to the previous returned value by a putsystemdateinsession pipe in this virtual machine. the thread will sleep for the specified time before recalculating a new value. set the timezone to a value without daylight saving time (like gmt+1) to prevent this pipe to generate two equal value's when the clock is set back. <b>note:</b> when you're looking for a guid parameter for you xslt it might be better to use &lt;param name=&quot;guid&quot; pattern=&quot;{hostname}_{uid}&quot;/&gt;, see {@link nl.nn.adapterframework.parameters.parameter}", "-1 (disabled)"}) void setSleepWhenEqualToPrevious(long sleepWhenEqualToPrevious); @IbisDoc({"if <code>true</code>, the date/time returned will always be december 17, 2001, 09:30:47 (for testing purposes only). it is overridden by the value of the pipelinesession key <code>stub4testtool.fixeddate</code> when it exists", "<code>false</code>"}) void setReturnFixedDate(boolean b); boolean isReturnFixedDate(); boolean isGetCurrentTimeStampInMillis(); @IbisDoc({"If set to 'true' then current time stamp in millisecond will be stored in the sessionKey", "false"}) void setGetCurrentTimeStampInMillis(boolean getCurrentTimeStampInMillis); final static Object OBJECT; final static String FIXEDDATETIME; final static String FORMAT_FIXEDDATETIME; final static String FIXEDDATE_STUB4TESTTOOL_KEY; }
@Test public void testConfigureNullSessionKey() throws Exception { expectedEx.expectMessage("has a null value for sessionKey"); pipe.setSessionKey(null); configureAndStartPipe(); }