Skip to main content
Question

how can i find devices that connected with lines


i have a map and it has too many devices and lines and lines connected to different devices and i want to know for specific lines ,which lines connected to which device and show me the ID of this device ( i mean at end of the line or start from this line should be connected to device )i want to know exactly which device is it ? and how many lines get in and out from each device . how can i write function for this line .Thanks

4 replies

danilo_fme
Evangelist
Forum|alt.badge.img+41
  • Evangelist
  • December 24, 2019

Hi @zoro40

There are so many transformers for Spatial Relator that you can use.

What kind of geometry are devices? If are Polygons I suggest you to use transformers for Overlayer - for example LineOnAreaOverlayer.

Is possible with these transformers to get all attributes that were spatial detected.

 

Thanks,

Danilo

 


  • Author
  • December 24, 2019
danilo_fme wrote:

Hi @zoro40

There are so many transformers for Spatial Relator that you can use.

What kind of geometry are devices? If are Polygons I suggest you to use transformers for Overlayer - for example LineOnAreaOverlayer.

Is possible with these transformers to get all attributes that were spatial detected.

 

Thanks,

Danilo

 

they are polygons , but how can I know ,how many lines get in or out from polygon and give each line id.Thanks for ur answer


danilo_fme
Evangelist
Forum|alt.badge.img+41
  • Evangelist
  • December 24, 2019

Excellent.

You can use the transformer LineonAreaOverlayer :

The yellow attribute ( Overlap Count Attribute ) show how many interactions that have between the geometries.

 

In the Attribute Accumulation you set the Option Merge Attributes.

 

If you want to share the Readers lines and polygons.

 

Thanks,

Danilo

 


veroh
Contributor
Forum|alt.badge.img+5
  • Contributor
  • January 2, 2020

Hello, if your polygons are not overlapping, you can have the number of lines being on the polygon with the overlap_count_attribute that will be created using the lineoverarea transformer.

According to FME Help for this transformer :

"The Overlap Count Attribute added to output area features holds the number of linear features that they contained."

But you will not be able to separate between the lines getting in and out.

If your input line got ID, you can use the "Attribute Acccumulation" parametre in the lineoverarea transformer and merge the attributes. This will add the attribute of the line on the area. But be careful because if your area has already attribute named ID, the attribute ID from the line will not be written. Use a list or bulkrename the attribut of the line with a prefix.

If you need to separate the lines getting IN from the line getting OUT, it is another matter.

Hope this help you a bit

V.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings