code: public static List<IRingSet> partitionRings(IRingSet ringSet) {
          List<IRingSet> ringSets = new ArrayList<IRingSet>();
          if (ringSet.getAtomContainerCount() == 0) return ringSets;
          IRing ring = (IRing) ringSet.getAtomContainer(0);
          if (ring == null) return ringSets;
          IRingSet rs = ring.getBuilder().newInstance(IRingSet.class);
          for (int f = 0; f < ringSet.getAtomContainerCount(); f++) {
              rs.addAtomContainer(ringSet.getAtomContainer(f));
          }
          do {
              ring = (IRing) rs.getAtomContainer(0);
              IRingSet newRs = ring.getBuilder().newInstance(IRingSet.class);
              newRs.addAtomContainer(ring);
              ringSets.add(walkRingSystem(rs, ring, newRs));
  
          } while (rs.getAtomContainerCount() > 0);
  
          return ringSets;
      }
docs: Partitions a RingSet into RingSets of connected rings. Rings which share
  an Atom, a Bond or three or more atoms with at least on other ring in
  the RingSet are considered connected. Thus molecules such as azulene and
  indole will return a List with 1 element.
  
  <p>Note that an isolated ring is considered to be <i>self-connect</i>. As a result
  a molecule such as biphenyl will result in a 2-element List being returned (each
  element corresponding to a phenyl ring).
  
  @param  ringSet  The RingSet to be partitioned
  @return          A {@link List} of connected RingSets