/** * {@inheritDoc} */ @Override public void addBond(int beg, int end, Order order) { addBond(beg, end, order, Stereo.NONE); }
/** * {@inheritDoc} */ @Override public void addBond(int beg, int end, Order order) { addBond(beg, end, order, Stereo.NONE); }
/** * {@inheritDoc} */ @Override public void addElectronContainer(IElectronContainer ec) { if (ec instanceof IBond) this.addBond((IBond) ec); if (ec instanceof ILonePair) this.addLonePair((ILonePair) ec); if (ec instanceof ISingleElectron) this.addSingleElectron((ISingleElectron) ec); notifyChanged(); }
/** * {@inheritDoc} */ @Override public void addElectronContainer(IElectronContainer ec) { if (ec instanceof IBond) this.addBond((IBond) ec); if (ec instanceof ILonePair) this.addLonePair((ILonePair) ec); if (ec instanceof ISingleElectron) this.addSingleElectron((ISingleElectron) ec); notifyChanged(); }
/** * {@inheritDoc} */ @Override public void addBond(int beg, int end, Order order, Stereo stereo) { IBond bond = getBuilder().newBond(); bond.setAtoms(new IAtom[]{getAtom(beg), getAtom(end)}); bond.setOrder(order); bond.setStereo(stereo); addBond(bond); }
/** * {@inheritDoc} */ @Override public void addBond(int beg, int end, Order order, Stereo stereo) { IBond bond = getBuilder().newBond(); bond.setAtoms(new IAtom[]{getAtom(beg), getAtom(end)}); bond.setOrder(order); bond.setStereo(stereo); addBond(bond); }
/** * Constructs a shallow copy of the provided IAtomContainer with the same * atoms, bonds, electron containers and stereochemistry of another * AtomContainer. Removing atoms/bonds in this copy will not affect * the original, however changing the properties will. * * @param src the source atom container */ AtomContainer2(IAtomContainer src) { this(src.getAtomCount(), src.getBondCount(), src.getLonePairCount(), src.getSingleElectronCount()); for (IAtom atom : src.atoms()) addAtom(atom); for (IBond bond : src.bonds()) addBond(bond); for (ISingleElectron se : src.singleElectrons()) addSingleElectron(se); for (ILonePair lp : src.lonePairs()) addLonePair(lp); for (IStereoElement se : src.stereoElements()) addStereoElement(se); }
/** * Constructs a shallow copy of the provided IAtomContainer with the same * atoms, bonds, electron containers and stereochemistry of another * AtomContainer. Removing atoms/bonds in this copy will not affect * the original, however changing the properties will. * * @param src the source atom container */ AtomContainer2(IAtomContainer src) { this(src.getAtomCount(), src.getBondCount(), src.getLonePairCount(), src.getSingleElectronCount()); for (IAtom atom : src.atoms()) addAtom(atom); for (IBond bond : src.bonds()) addBond(bond); for (ISingleElectron se : src.singleElectrons()) addSingleElectron(se); for (ILonePair lp : src.lonePairs()) addLonePair(lp); for (IStereoElement se : src.stereoElements()) addStereoElement(se); }
if (!bond.getFlag(CDKConstants.VISITED)) { bond.setFlag(CDKConstants.VISITED, true); addBond(bond);
if (!bond.getFlag(CDKConstants.VISITED)) { bond.setFlag(CDKConstants.VISITED, true); addBond(bond);