const NodeWayUtils = Java.type('org.openstreetmap.josm.plugins.utilsplugin2.selection.NodeWayUtils')
gives error:
TypeError: Access to host class org.openstreetmap.josm.plugins.utilsplugin2.selection.NodeWayUtils is not allowed or does not exist.
const AddIntersectionsAction = Java.type('org.openstreetmap.josm.plugins.utilsplugin2.actions.AddIntersectionsAction')
TypeError: Access to host class org.openstreetmap.josm.plugins.utilsplugin2.actions.AddIntersectionsAction is not allowed or does not exist.
How to run menu command "Selection -> Intersecting ways" or "More tools -> Add nodes at intersections" or access JOSM classes directly? https://josm.openstreetmap.de/wiki/Help/Action/SelectIntersectingWays https://josm.openstreetmap.de/wiki/Help/Action/AddNodeIntersection
const NodeWayUtils = Java.type('org.openstreetmap.josm.plugins.utilsplugin2.selection.NodeWayUtils') gives error: TypeError: Access to host class org.openstreetmap.josm.plugins.utilsplugin2.selection.NodeWayUtils is not allowed or does not exist.
const AddIntersectionsAction = Java.type('org.openstreetmap.josm.plugins.utilsplugin2.actions.AddIntersectionsAction') TypeError: Access to host class org.openstreetmap.josm.plugins.utilsplugin2.actions.AddIntersectionsAction is not allowed or does not exist.
https://github.com/JOSM/josm-plugins/blob/498f6617765a13c7455db496ac0b70604f457cd7/utilsplugin2/src/org/openstreetmap/josm/plugins/utilsplugin2/actions/AddIntersectionsAction.java#L33