This is my first attempt at helping in the community but here goes. I AM using the “ConnectorsTypeValue.STRAIGHT_LINES” property successfully. Your syntax appears correct. In your import statement(s), use:
I am using aspose version 21.9.
One other thing. This may not be related to the problem you are experiencing, but In order for it to work, I had to add the connector to the page first (the line you have just below your bold line --not sure why that would be the case) but if I did not, I got the error:
Cannot invoke “com.aspose.diagram.Shape.getGeoms()” because the return value of “com.aspose.diagram.Shape.getMasterShape()” is null