Link validation while drawing from one node to another using the adornment

Hi,
I have adornments on my nodes, I am drawing the links from one node to another using the adornments. I want to put restrictions on links. If a link is drawn using an adornment to make the connection then it should not allow to create another link with the same adornment, If different adornment is used then the link can be drawn to a different Node.
Thanks in advance.

I do not know enough about your situation to recommend anything specific. All I can say at this time is to make sure you have read about link validation: GoJS Validation -- Northwoods Software

Surely your general linkValidation predicate can consider the same properties that cause the choice of adornment.

Thanks for sharing, I did go through it.
Basically I want to achieve this suppose there are Node (A,B,C,D)
connection I am expecting is AB, CD, DB. If I have AB, I cannot create AC this should throw an error. A node can have Multiple inputs but only one output of any adornment .

consider A has adornment yes and no. Consider
A,with yes adornment to node B
A,with no adornment to node C if we try to make one more connection with any of the yes or no adornment to D it should give me an error

I think I am not understanding your rules. Try implementing a predicate that you can assign to your diagram’s LinkingTool.linkValidation property.