@ Override public IRingSet getRings ( IBond bond ) { IRingSet rings = bond . getBuilder ( ) . newInstance ( IRingSet . class ) ; Ring ring ; for ( int i = 0 ; i < getAtomContainerCount ( ) ; i ++ ) { ring = ( Ring ) getAtomContainer ( i ) ; if ( ring . contains ( bond ) ) { rings . addAtomContainer ( ring ) ; } } return rings ; }
Returns a vector of all rings that this bond is part of .