code: public static Set<Object> findInstancesInScopes(Injector injector, Class<? extends Annotation>... scopeAnnotations) {
      Set<Object> objects = new TreeSet<Object>(new Comparator<Object>() {
  
        @Override
        public int compare(Object o0, Object o1) {
          return o0.getClass().getName().compareTo(o1.getClass().getName());
        }
        
      });
      for( Map.Entry<Key<?>, Binding<?>> entry : findBindingsInScope(injector, scopeAnnotations).entrySet()) {
        Object object = injector.getInstance(entry.getKey());
        objects.add(object);
      }
      return objects;
    }
docs: Finds all of the instances in the specified scopes.
  
  <p>
  Returns a list of the objects from the specified scope, sorted by their class name.
  </p>
  
  @param injector the injector to search.
  @param scopeAnnotations the scopes to search for.
  @return the objects bound in the injector.