code: void processNames(Collection<String> namesToResolve) {
          for (String name : namesToResolve) {
              SampleResource sample = sampleIndex.get(name.toLowerCase());
              if (sample != null) {
                  // Found a sample, add it and any required features
                  samplesToInstall.add(sample);
                  if (sample.getRequireFeature() != null) {
                      featureNamesToResolve.addAll(sample.getRequireFeature());
                  }
              } else {
                  // Name didn't match any samples, assume it's a feature name
                  NameAndVersion nameAndVersion = splitRequestedNameAndVersion(name);
                  if (nameAndVersion.version != null) {
                      resolverRepository.setPreferredVersion(nameAndVersion.name, nameAndVersion.version);
                  }
  
                  featureNamesToResolve.add(nameAndVersion.name);
                  requestedFeatureNames.add(nameAndVersion.name);
              }
          }
      }
docs: Populates {@link #samplesToInstall} and {@link #featureNamesToResolve} by processing the list of names to resolve and identifying which are samples.