CEP Module - escaping square brackets in expressions

Hi,

I’m trying to write a simple expression in Esper CEP to extract particular part of a string. However, when using String.split method, I need to process an array returned. Whenever I use square brackets in the script though, I gen a syntax error. How do I correctly use arrays in the “create expression” statement?

My expression is very simple:
create expression String getCellId(value) [
String tail = value.split("")[1];
String cellID = tail.split("")[0];
cellID;
];

“value” is a body from a SOAP call I do in my module. The result should have tag, the value of which I need to return.

Thanks,
Peter

Hi,

as paying customer you can raise this question via Empower Ticket.

best regards
Michael