Link configuration from node - to node without linking

I made a sample layout similar to orgChartEditor.

I have a scenario where I want to restrict nodes from having multiple ports.

For example I have nodes A, B, C, D, E etc and i want a connection B -> C -> D -> A. And at the same time it should not allow connection from C -> A or A -> B. by which I mean it should be sequential order and once a link is drawn from FROM node that node should not accept a TO reference back again.

I’m not sure exactly what you want, but this page discusses all of the possibilities:

@walter All I mean is one node should have only one link and that can be outgoing or incoming to it. if a node gets outgoing first that same node should not allow any incoming to it and vise versa. and one node should not allow two incoming links to it.

Hope I’m making sense now.

Does this cover your desired validation?

@walter yes it did work, thank you