Returns a set that contains given views as well as all implied views.
@param views
@return
188623
public static final Set<String> impliedSet(String... views)
    {
        Set<String> set = new HashSet<>();
        for (String view : views)
        {
            set.addAll(impliesMap.get(view));
        }
        return set;
    }
72161
public static <T> Set<T> set(T... values) {
        return new HashSet<T>(Arrays.asList(values));
    }
28938
@SuppressWarnings("unchecked")
	public Set<OGraphVertex> browseOutEdgesVertexes() {
		final Set<OGraphVertex> resultset = new HashSet<OGraphVertex>();

		Set<OGraphEdge> temp = out != null ? out.get() : null;

		if (temp == null) {
			final Set<OIdentifiable> docEdges = (Set<OIdentifiable>) document.field(OGraphDatabase.VERTEX_FIELD_OUT);

			// TRANSFORM ALL THE EDGES
			if (docEdges != null)
				for (OIdentifiable d : docEdges) {
					resultset.add((OGraphVertex) database.getUserObjectByRecord(
							(ODocument) ((ODocument) d.getRecord()).field(OGraphDatabase.EDGE_FIELD_IN), null));
				}
		} else {
			for (OGraphEdge edge : temp) {
				resultset.add(edge.getIn());
			}
		}

		return resultset;
	}
1051269
public static <T> Set<T> newSet(T... values) {
    Set<T> set = new HashSet<>(values.length);
    Collections.addAll(set, values);
    return set;
  }
251171
public static Set<Method> getAllMethods(Class<?> classs) {
    Set<Method> set = new HashSet<>();
    Class<?> c = classs;
    while (c != null) {
      set.addAll(Arrays.asList(c.getDeclaredMethods()));
      c = c.getSuperclass();
    }
    return set;
  }
7588
public Set<Map.Entry<String, String>> getSetEntries() {
      Set<Map.Entry<String, String>> entries = optionSet.stream()
                                                        .filter(this::isSet)
                                                        .map(no -> Tuple2.of(no.getName(),
                                                                             Convert.convert(no.getValue(),
                                                                                             String.class)))
                                                        .collect(Collectors.toSet());
      entries.addAll(unamedOptions.entrySet());
      return entries;
   }
442000
private final View getRecentContainer(View[] views) {
		View container = null;
		long drawingTime = 0;
		View view;

		for(int i = 0; i < views.length; i++){
			view = views[i];
			if (view != null && view.isShown() && view.hasWindowFocus() && view.getDrawingTime() > drawingTime) {
				container = view;
				drawingTime = view.getDrawingTime();
			}
		}
		return container;
	}
1256456
@CheckResult
    @NonNull
    public static PowerAdapter asAdapter(@NonNull Iterable<? extends ViewFactory> views) {
        checkNotNull(views, "views");
        return new ItemAdapter(ItemAdapter.toItems(views));
    }
972659
public final View getRecentDecorView(View[] views) {
		if(views == null)
			return null;

		final View[] decorViews = new View[views.length];
		int i = 0;
		View view;

		for (int j = 0; j < views.length; j++) {
			view = views[j];
			if (isDecorView(view)){ 
				decorViews[i] = view;
				i++;
			}
		}
		return getRecentContainer(decorViews);
	}
98087
public static <T extends View> ArrayList<T> removeInvisibleViews(Iterable<T> viewList) {
		ArrayList<T> tmpViewList = new ArrayList<T>();
		for (T view : viewList) {
			if (view != null && view.isShown()) {
				tmpViewList.add(view);
			}
		}
		return tmpViewList;
	}
1144118
public static DescriptorExtensionList<View,ViewDescriptor> all() {
        return Jenkins.getInstance().<View,ViewDescriptor>getDescriptorList(View.class);
    }
252775
public static <T> Set<T> intersection(Set<T>... sets) {
		return intersection(Arrays.asList(sets));
	}
550711
public static <T> Set<T> getSet(Collection<T> collection) {
    Set<T> set = new LinkedHashSet<T>();
    set.addAll(collection);

    return set;
  }
275827
@Deprecated
	@NonNull
	public SparseArray<ViewState> getViewStates() {
		final SparseArray<ViewState> list = new SparseArray<>();

		final Iterator<Map.Entry<Integer, ViewState>> iterator = getStates().entrySet().iterator();
		while (iterator.hasNext()) {
			final Map.Entry<Integer, ViewState> next = iterator.next();
			list.put(next.getKey(), next.getValue());
		}

		return list;
	}
350764
public Set<AbstractPlugin> getPlugins(final String viewName) {
        if (pluginCache.isEmpty()) {
            LOGGER.info("Plugin cache miss, reload");

            load();
        }

        final Set<AbstractPlugin> ret = pluginCache.get(viewName);

        if (null == ret) {
            return Collections.emptySet();
        }

        return ret;
    }
988772
View getViewWithKey(String key) {
        if (key == null) {
            throw new IllegalArgumentException("A key must be specified.");
        }

        Set<View> views = new HashSet<>();
        views.addAll(systemLandscapeViews);
        views.addAll(systemContextViews);
        views.addAll(containerViews);
        views.addAll(componentViews);
        views.addAll(dynamicViews);
        views.addAll(deploymentViews);

        return views.stream().filter(v -> key.equals(v.getKey())).findFirst().orElse(null);
    }
648569
@SafeVarargs
    public static <T> Set<T> newSets(T... values) {
        if(null == values || values.length == 0){
            Assert.notNull(values, "values not is null.");
        }
        return new HashSet<>(Arrays.asList(values));
    }