Finds the Set of Essential Rings.
These rings are contained in every possible SSSR.
The returned set is uniquely defined.

@return      a RingSet containing the Essential Rings
10460
public IRingSet findEssentialRings() {
        if (atomContainer == null) {
            return null;
        }
        IRingSet ringSet = toRingSet(atomContainer, cycleBasis().essentialCycles());
        //		atomContainer.setProperty(CDKConstants.ESSENTIAL_RINGS, ringSet);
        return ringSet;
    }
754589
@Override
    public Set<PluralAttribute<? super X, ?, ?>> getPluralAttributes()
    {
        Set<PluralAttribute<? super X, ?, ?>> pluralAttributes = new HashSet<PluralAttribute<? super X, ?, ?>>();
        Set<PluralAttribute<X, ?, ?>> declaredAttribSet = getDeclaredPluralAttributes();
        if (declaredAttribSet != null)
        {
            pluralAttributes.addAll(declaredAttribSet);
        }

        if (superClazzType != null)
        {
            pluralAttributes.addAll(superClazzType.getPluralAttributes());
        }

        return pluralAttributes;
    }
1195426
public Set<NFAState<T>> getAll()
    {
        Set<NFAState<T>> set = new NumSet<>();
        Map<NFAState<T>,Integer> indexOf = new NumMap<>();
        Deque<NFAState<T>> stack = new ArrayDeque<>();
        for (NFAState<T> state : this)
        {
            if (!indexOf.containsKey(state))
            {
                collect(state, indexOf, stack, set);
            }

        }
        return set;
    }
1333019
public Set<String> getRoles() {
        HashSet<String> rolescopy;
        rolescopy = new HashSet<>(roles);
        return Collections.unmodifiableSet(rolescopy);
    }
852099
public synchronized Set<String> keySet() {
		if(size == 0) {
			return new HashSet<String>(0);
		} else {
			try {
				XAttributeMap map = deserialize();
				return map.keySet();
			} catch (IOException e) {
				e.printStackTrace();
				return null;
			}
		}
	}
1121815
@SuppressWarnings("deprecation") // The String ctor is deprecated, but fast.
  public Set<String> keys() {
    if (isEmpty()) {
      return Collections.emptySet();
    }
    Set<String> ks = new HashSet<>(size);
    for (int i = 0; i < size; i++) {
      ks.add(new String(name(i), 0 /* hibyte */));
    }
    // immutable in case we decide to change the implementation later.
    return Collections.unmodifiableSet(ks);
  }
673364
private function listSets()
    {
        $listNode = $this->response->createElement('ListSets');

        // fetch the sets either by resumption token or without
        if (isset($this->params['resumptionToken'])) {
            $sets = $this->repository->listSetsByToken($this->params['resumptionToken']);
        } else {
            $sets = $this->repository->listSets();
            if (!count($sets->getItems())) {
                throw new NoSetHierarchyException("The repository does not support sets.");
            }
        }

        //create node for all sets
        foreach ($sets->getItems() as $set) {
            $setNode = $this->response->createElement('set');
            $setNode->appendChild($this->response->createElement('setSpec', $set->getSpec()));
            $setNode->appendChild($this->response->createElement('setName', $set->getName()));
            if ($set->getDescription()) {
                $setNode->appendChild($this->response->createElement('setDescription', $set->getDescription()));
            }
            $listNode->appendChild($setNode);
        }

        $this->addResumptionToken($sets, $listNode);

        return $listNode;
    }
994982
@Override
    public Set<K> keySet() {
        final Set<K> localSet = this.localMap.keySet();

        if (isReadyOnly())
            return Collections.unmodifiableSet(localSet);

        return localSet;
    }
1156006
public java.util.List<String> getTaskSets() {
        if (taskSets == null) {
            taskSets = new com.amazonaws.internal.SdkInternalList<String>();
        }
        return taskSets;
    }
925194
public Map<ElementDescriptor<?>, Object> getSet()
	{
		return mSet == null ? null : Collections.unmodifiableMap(mSet);
	}
959598
public IRingSet getAllRings() throws NoSuchAtomException {
        IRingSet ringset = getBasicRings();
        IRing newring;

        int nBasicRings = ringset.getAtomContainerCount();
        for (int i = 0; i < nBasicRings; i++)
            getBondsInRing(molecule, (IRing) ringset.getAtomContainer(i), cb[i]);

        for (int i = 0; i < nBasicRings; i++) {
            for (int j = i + 1; j < nBasicRings; j++) {
                //logger.debug("combining rings "+(i+1)+","+(j+1));
                newring = combineRings(ringset, i, j);
                //newring = combineRings((Ring)ringset.get(i),(Ring)ringset.get(j));
                if (newring != null) ringset.addAtomContainer(newring);
            }
        }

        return ringset;
    }
3693
@Override
    public IRingSet getRingSet(IAtomContainer molecule) throws CDKException {

        Collection<List<IAtom>> cycles = findRings(molecule);

        IRingSet ringSet = molecule.getBuilder().newInstance(IRingSet.class);

        for (List<IAtom> ringAtoms : cycles) {
            IRing ring = molecule.getBuilder().newInstance(IRing.class);
            for (IAtom atom : ringAtoms) {
                atom.setFlag(CDKConstants.ISINRING, true);
                ring.addAtom(atom);
                for (IAtom atomNext : ringAtoms) {
                    if (!atom.equals(atomNext)) {
                        IBond bond = molecule.getBond(atom, atomNext);
                        if (bond != null) {
                            bond.setFlag(CDKConstants.ISINRING, true);
                            ring.addElectronContainer(bond);
                        }
                    }
                }
            }
            ringSet.addAtomContainer(ring);
        }
        return ringSet;
    }
550711
public static <T> Set<T> getSet(Collection<T> collection) {
    Set<T> set = new LinkedHashSet<T>();
    set.addAll(collection);

    return set;
  }
376587
public static String getSetContents(Set s) {
        StringBuffer sb = new StringBuffer(1000);

        Object[] sortedArray = s.toArray();
        Arrays.sort(sortedArray);

        int counter = 0;
        int elementsPerRow = 10;
        for (Object element : sortedArray) {
            sb.append(element.toString() + " ");
            counter++;
            if ((counter % elementsPerRow) == 0) {
                sb.append(System.getProperty("line.separator"));
            }
        }
        sb.append(System.getProperty("line.separator"));
        return sb.toString();
    }
291401
private IRingSet getRingSystemOfAtom(List ringSystems, IAtom ringAtom) {
        IRingSet ringSet = null;
        for (int f = 0; f < ringSystems.size(); f++) {
            ringSet = (IRingSet) ringSystems.get(f);
            if (ringSet.contains(ringAtom)) {
                return ringSet;
            }
        }
        return null;
    }
369390
@Override
    public Set<K> keySet() {
        try {
            lockAllSegments();
            Set<K> set = new HashSet<>();
            for (LinkedHashMapSegment<K, V> seg : segments) {
                set.addAll(seg.keySet());
            }
            return set;
        } finally {
            unlockAllSegments();
        }
    }
568813
@Override
    public Set keySet() {
        if (keySet != null) {
            return keySet;
        }
        keySet = new AbstractSet() {
            @Override
            public Iterator iterator() {
                return new KeyIterator();
            }            @Override
            public int size() {
                return size;
            }



            @Override
            public boolean contains(final Object o) {
                return containsKey(o);
            }


            @Override
            public boolean remove(final Object o) {
                final Object r = ReferenceMap.this.remove(o);
                return r != null;
            }

            @Override
            public void clear() {
                ReferenceMap.this.clear();
            }

        };
        return keySet;
    }