How can I extract the actual text found? I’ve been using getRangeText but I don’t see how to use the NodeIds in conjunction with the offsets to get the desired text.
You need to pass the starting node ID and ending node ID of the range to get the text of the specified range. Please check the following cURL command. To get the text of the second paragraph, we will pass the second paragraph node id as rangeStartIdentifier and the third paragraph node id as rangeEndIdentifier. Hopefully, it will help you accomplish the task.
I understand that I need to pass in the start and and end node. What I don’t understand is how to use the data returned by the call to Search to do this.
If I have some text:
find me
Text before find me
find me text after
Before find me text find me after
Thanks for sharing additional information. We have logged a ticket(WORDSCLOUD-2526) for further investigation. We will keep you updated on the issue resolution in this forum thread.
Sorry for the late response. To achieve your requirements, you need to specify the end attribute for the randeEndIdentifier because, by default, range operations take everything before rangeEndIdentifier; when you add end, it means you included the end node to the range.
In the scenario you posted, the start node will be id0.0.1.4, and the end node will be id0.0.1.6:end.
The issues you have found earlier (filed as WORDSCLOUD-2526) have been fixed in this update. This message was posted using Bugs notification tool by Ivanov_John