AnsweredAssumed Answered

Barriers in Multimodal Network Dataset ArcGIS API WAB

Question asked by ARROCAL on Feb 26, 2018
Latest reply on Feb 26, 2018 by rscheitlin

I'm developing an application with WAB and the JS 3.22 API to calculate routes over a multimodal networks dataset.

 

When I add barriers I find that several lines of network 1 of the network dataset (subway for example) has the  same geometry that several lines in  network 2 (bus for example). And when I add barriers in the coordinates of the lines with the same geometry, the barrier applies to both networks (subway and bus),  and I need that the barrieres applies only to one network.

 

I am adding the barriers in this way:

 

                     var polylineJson = {

                            "paths":[[[x1, y1], [x2, y2]

                            ]],

                            "spatialReference":{"wkid":this.config.spatialReference}

                          };

        

                        var polyline = new Polyline(polylineJson);

                        

                        var myGraphic = new Graphic(polyline, null);

myGraphic.setAttributes(…);

                        

                        routeParams.polylineBarriers.features.push(myGraphic);

 

 

But I do not know how to indicate that the barrier affects only the network that I want.

 

I don`t know if I have to change  my  JS  code or the Network Dataset

 

 Does this problem have a solution?

 

Thanks, greetings.

Outcomes