code: public IRenderingElement generateBondElement(IBond bond, IBond.Order type, RendererModel model) {
          // More than 2 atoms per bond not supported by this module
          if (bond.getAtomCount() > 2) return null;
  
          // is object right? if not replace with a good one
          Point2d point1 = bond.getBegin().getPoint2d();
          Point2d point2 = bond.getEnd().getPoint2d();
          Color color = this.getColorForBond(bond, model);
          double bondWidth = this.getWidthForBond(bond, model);
          double bondDistance = (Double) model.get(BondDistance.class) / model.getParameter(Scale.class).getValue();
          if (type == IBond.Order.SINGLE) {
              return new LineElement(point1.x, point1.y, point2.x, point2.y, bondWidth, color);
          } else {
              ElementGroup group = new ElementGroup();
              switch (type) {
                  case DOUBLE:
                      createLines(point1, point2, bondWidth, bondDistance, color, group);
                      break;
                  case TRIPLE:
                      createLines(point1, point2, bondWidth, bondDistance * 2, color, group);
                      group.add(new LineElement(point1.x, point1.y, point2.x, point2.y, bondWidth, color));
                      break;
                  case QUADRUPLE:
                      createLines(point1, point2, bondWidth, bondDistance, color, group);
                      createLines(point1, point2, bondWidth, bondDistance * 4, color, group);
                  default:
                      break;
              }
              return group;
          }
      }
docs: Generate a LineElement or an ElementGroup of LineElements for this bond.
  This version should be used if you want to override the type - for
  example, for ring double bonds.
  
  @param bond the bond to generate for
  @param type the type of the bond - single, double, etc
  @param model the renderer model
  @return one or more rendering elements