Skip to main content
Solved

XMLTemplater and geo data functions

  • November 14, 2013
  • 1 reply
  • 10 views

jorge_vidinha
Contributor
Forum|alt.badge.img+2
Hi all,

 

Some help with an XML chalenge would be great appreciated.

 

 

Geometry Data Functions

 

What geometry function or functions would you use when feeding a polyline into XMLTemplater to get a final result like:

 

 

<Point>

 

<LAT>{value Y}</LAT>

 

<LON>value X}</LON>

 

</Point>

 

<Point>

 

<LAT>{value Y}</LAT>

 

<LON>{value X}</LON>

 

</Point>

 

<Point>

 

<LAT>{value Y}</LAT>

 

<LON>{value X}</LON>

 

</Point>

 

 

geom:get-x-coord() and geom:get-y-coord() only works on Point geo, im feeding polylines and want to stay with them preferably.

 

 

Using a SUB Template like:

 

<Point>

 

    <LAT>{geom:get-points("y")}</LAT>

 

    <LON>{geom:get-points("x")}</LON>

 

</Point>

 

 

Results in ==>

 

<Point>

 

    <LAT>{value Y} {value Y} {value Y}</LAT>

 

    <LON>{value X} {value X} {value X}</LON>

 

</Point>

 

 

 

Any help appreciated

 

Jorge Vidinha

Best answer by fmelizard

Hi Jorge,

 

 

Since the lines will be preserved in the XML, if created acoordingly, you can chop your lines and feed them as points to the SUB template.

 

 

Itay

 

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

1 reply

fmelizard
Safer
Forum|alt.badge.img+21
  • Safer
  • Best Answer
  • November 14, 2013
Hi Jorge,

 

 

Since the lines will be preserved in the XML, if created acoordingly, you can chop your lines and feed them as points to the SUB template.

 

 

Itay