Hi,
I would use the SpatialRelator, ListSorter and ListIndexcer.
Send polygons to Requestor (BASE), lines to Supplier (CANDIDATE) of the SpatialRelator. Output features are polygons, and each of them will have a list attribute (named "_relationships{}" by default) containing all attributes of spatially related lines.
The list is a structured one. If lines have an attribute called "line_type" for the type of line, output polygons will have "_relationships{}.line_type".
Next, sort the list with the ListSorter so that the first element is the largest line type.
List Attribute: _relationships{}.line_type
Sorting Type: Numeric
Sorting Order: Decreasing
And then, extract the first element of the list with the ListIndexcer.
List Attribute: _relationships{}
List Index: 0
Hope this helps.
Takashi
Another idea that parallels Takashi's would be to user a sorter, descending numerically by "type of line."
Then use a duplicate remover and the set the "Key Attribute" as the unique ID that defines each set of lines. Note, if there are no key attributes, then the Sorter and DuplicateRemover can be set after the ListExploder.
Back to the first workflow, send the data to a LineOnAreaOverlayer, name the list, and then send the "Area Output" onto a ListExploder. Explode the list by the name you previously gave the list. Now your polygon will have the attributes of the highest value "type of line."
or the second method
Hi,
thanks for your reply..i have another problem..two ore more polygons have the same line with the highest value..how to assign the value 7 both polygons?
I think the SpacialRelator approach I suggested should work also in that case.
LineOnAreaoverlayer with a listname. Listrangeextractor on Areaoutput. (Ditch the _min.)