Split with regex and group not working

2018-06-19 Thread Rory Gilfillan
The following code doesn't work: .split().tokenize("\n|\r\n", true, 100, true) It tries to reinsert the token between the lines without taking into account that the token is a regex string. The follow code in the GroupTokenIterator is the culprit: // include token in b

Re: Evaluate JSON using Rhino 1.6R7?

2015-07-08 Thread rory
Just an update, I've tried updating Rhino to this version: /opt/aepona/ase/system/org/apache/servicemix/bundles/org.apache.servicemix.bundles.rhino/1.7R2_3/org.apache.servicemix.bundles.rhino-1.7R2_3.jar ans then tried using JSON.parse again. This time I no longer see the 'JSON is not defined' e

Re: Evaluate JSON using Rhino 1.6R7?

2015-07-07 Thread rory
Hi, thanks for your reply. However, as stated in my question, JSON.parse is not implemented in Rhino 1.6R7, thus eval is used. -- View this message in context: http://camel.465427.n5.nabble.com/Evaluate-JSON-using-Rhino-1-6R7-tp5768944p5768946.html Sent from the Camel - Users mailing list archi

Evaluate JSON using Rhino 1.6R7?

2015-07-07 Thread rory
I'm using Rhino (https://github.com/mozilla/rhino) 1.67R via Apache Camel and am trying to evaluate the following JSON: { "coord": { "lon": -4.75, "lat": 54.08 }, "weather": [ { "id": 801, "main": "Clouds", "description": "few clouds", "icon": "02d" }

Camel XML Simple problem using operators?

2015-06-29 Thread rory
I'm using Camel 2.10. I'm using org.apache.camel.model.RouteDefinition. I can set the body of my request fine using the variables described in the docs: http://camel.apache.org/simple.html For example, if I create a org.apache.camel.model.RouteDefinition which looks like: // Calling toString