public virtual void TestIsEmpty()
        {
            IChemObjectSet <IAtomContainer> set = (IChemObjectSet <IAtomContainer>)NewChemObject();

            Assert.IsTrue(set.IsEmpty(), "new container set should be empty");
            set.Add(set.Builder.NewAtomContainer());
            Assert.IsFalse(set.IsEmpty(), "container set with a single container should not be empty");
            set.Clear();
            Assert.IsTrue(set.IsEmpty(), "container set with all containers removed should be empty");
        }
Пример #2
0
 /// <inheritdoc/>
 public bool IsEmpty()
 => (setOfMolecules == null || setOfMolecules.IsEmpty()) &&
 (setOfReactions == null || setOfReactions.IsEmpty()) &&
 (ringSet == null || ringSet.IsEmpty()) &&
 (crystal == null || crystal.IsEmpty());