// This sample demonstrates how to customize links' arrowheads

  // Create two nodes
  ShapeNode start, end;
  start = diagram.getFactory().createShapeNode(10102020);
  end = diagram.getFactory().createShapeNode(80102020);

  // Create the link
  DiagramLink link = diagram.getFactory().createDiagramLink(start, end);

  // Set the arrowhead shape
  link.setHeadShape(ArrowHeads.BowArrow);
  link.setHeadShapeSize(6);

  // Set the base shape
  link.setBaseShape(ArrowHeads.Circle);
  link.setBaseShapeSize(4);

  // Set the intermediate shape
  link.setIntermediateShape(ArrowHeads.PointerArrow);
  link.setIntermediateShapeSize(3);

  // Create pen for all arrowheads
  Pen pen = new Pen(0.5f, Color.RED);
  link.setPen(pen);
  link.setHeadPen(pen);