Skip to content

Instantly share code, notes, and snippets.

@SriniBlog
Last active February 9, 2018 01:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save SriniBlog/b77ab0a7bec57e581833 to your computer and use it in GitHub Desktop.
Save SriniBlog/b77ab0a7bec57e581833 to your computer and use it in GitHub Desktop.
This UDF can be used to read the Seerburger Variable
public String getSeeburgerVariable(String variableName, Container container) throws StreamTransformationException{
AbstractTrace trace;
trace = container.getTrace();
String variableValue = "";
try
{
VariableBean be=VariableFactory.getVariableInstance("");
variableValue = be.getStringVariable(variableName);
if ( variableValue!= null)
{
return variableValue;
}
else
{
trace.addInfo("Value Not Found!!");
throw new RuntimeException("Value Not found for variable");
}
}catch (Exception e){
throw new RuntimeException(e);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment