Returns all ScopeListExtension found in the given collection of extensions,
or an empty list if the extension collection does not contain ScopeListExtensions.
555177
public static List<ScopeListExtension> findAll(Collection<? extends Extension> extensions)
    {
        List<ScopeListExtension> result = new ArrayList<ScopeListExtension>();
        for (Extension extension : extensions)
        {
            if (SCOPE_LIST_EXTENSION_ID == extension.getId())
                result.add((ScopeListExtension)extension);
        }
        return result;
    }
514207
public void refreshExtensions() throws ExtensionRefreshException {
        ExtensionList<ExtensionFinder> finders = getExtensionList(ExtensionFinder.class);
        for (ExtensionFinder ef : finders) {
            if (!ef.isRefreshable())
                throw new ExtensionRefreshException(ef+" doesn't support refresh");
        }

        List<ExtensionComponentSet> fragments = Lists.newArrayList();
        for (ExtensionFinder ef : finders) {
            fragments.add(ef.refresh());
        }
        ExtensionComponentSet delta = ExtensionComponentSet.union(fragments).filtered();

        // if we find a new ExtensionFinder, we need it to list up all the extension points as well
        List<ExtensionComponent<ExtensionFinder>> newFinders = Lists.newArrayList(delta.find(ExtensionFinder.class));
        while (!newFinders.isEmpty()) {
            ExtensionFinder f = newFinders.remove(newFinders.size()-1).getInstance();

            ExtensionComponentSet ecs = ExtensionComponentSet.allOf(f).filtered();
            newFinders.addAll(ecs.find(ExtensionFinder.class));
            delta = ExtensionComponentSet.union(delta, ecs);
        }

        for (ExtensionList el : extensionLists.values()) {
            el.refresh(delta);
        }
        for (ExtensionList el : descriptorLists.values()) {
            el.refresh(delta);
        }

        // TODO: we need some generalization here so that extension points can be notified when a refresh happens?
        for (ExtensionComponent<RootAction> ea : delta.find(RootAction.class)) {
            Action a = ea.getInstance();
            if (!actions.contains(a)) actions.add(a);
        }
    }
1300615
def get_directories_with_extensions(self, start, extensions=None):
        
        return set([p.parent for ext in extensions for p in start.rglob(ext)])
746451
public List<List<String>> getAllScopes() {
    this.checkInitialized();
    final ImmutableList.Builder<List<String>> builder = ImmutableList.<List<String>>builder();
    final Consumer<Integer> _function = (Integer it) -> {
      List<String> _get = this.scopes.get(it);
      StringConcatenation _builder = new StringConcatenation();
      _builder.append("No scopes are available for index: ");
      _builder.append(it);
      builder.add(Preconditions.<List<String>>checkNotNull(_get, _builder));
    };
    this.scopes.keySet().forEach(_function);
    return builder.build();
  }
968695
def list_ext(self, collection, path, retrieve_all, **_params):
        """"""
        return self.list(collection, path, retrieve_all, **_params)
627932
public static DescriptorExtensionList<SectionedViewSection, SectionedViewSectionDescriptor> all() {
        return Hudson.getInstance().<SectionedViewSection, SectionedViewSectionDescriptor>getDescriptorList(SectionedViewSection.class);
    }
591946
public static List<File> getFilesByExtension(File dir, String[] extensions)
    {
        if (!dir.isDirectory() || extensions == null)
            return Collections.emptyList();
        List<File> files = new ArrayList<File>();
        addFilesByExtension(files, dir, extensions);
        return files;
    }
1054735
public static Iterable<Descriptor> listLegacyInstances() {
        return new Iterable<Descriptor>() {
            public Iterator<Descriptor> iterator() {
                return new AdaptedIterator<ExtensionComponent<Descriptor>,Descriptor>(
                    new FlattenIterator<ExtensionComponent<Descriptor>,CopyOnWriteArrayList<ExtensionComponent<Descriptor>>>(legacyDescriptors.values()) {
                        protected Iterator<ExtensionComponent<Descriptor>> expand(CopyOnWriteArrayList<ExtensionComponent<Descriptor>> v) {
                            return v.iterator();
                        }
                    }) {

                    protected Descriptor adapt(ExtensionComponent<Descriptor> item) {
                        return item.getInstance();
                    }
                };
            }
        };
    }
1035030
public List<TldExtensionType<FunctionType<T>>> getAllFunctionExtension()
   {
      List<TldExtensionType<FunctionType<T>>> list = new ArrayList<TldExtensionType<FunctionType<T>>>();
      List<Node> nodeList = childNode.get("function-extension");
      for(Node node: nodeList)
      {
         TldExtensionType<FunctionType<T>>  type = new TldExtensionTypeImpl<FunctionType<T>>(this, "function-extension", childNode, node);
         list.add(type);
      }
      return list;
   }
245260
public static List<LanguageExtension> findAll(Collection<? extends Extension> extensions)
    {
        List<LanguageExtension> result = new ArrayList<LanguageExtension>();
        for (Extension extension : extensions)
        {
            if (LANGUAGE_EXTENSION_ID == extension.getId())
                result.add((LanguageExtension)extension);
        }
        return result;
    }
1361880
public static Map<String,String> getExtensions() {
		 StackInfo result = MDC.get();
		 if (result == null) {
			 return StackInfo.collectExtensions();
		 } else {
			 return result.extensions;
		 }
	 }
439969
public static List<Instance> findAllScopedInstances( AbstractApplication app ) {

		List<Instance> instanceList = new ArrayList<> ();
		List<Instance> todo = new ArrayList<> ();
		todo.addAll( app.getRootInstances());

		while( ! todo.isEmpty()) {
			Instance current = todo.remove( 0 );
			todo.addAll( current.getChildren());
			if( isTarget( current ))
				instanceList.add( current );
		}

		return instanceList;
	}
701842
public <T> T getLocalExtension(Class<T> extensionType) {
        Object obj = extensions.get(extensionType);
        if (null != obj) {
            return extensionType.cast(obj);
        }
        return null;
    }
1275447
public Collection<XAttribute> getAttributesForExtension(XExtension extension) {
		if(extension == null) {
			return getAttributesWithoutExtension();
		} else {
			Set<XAttribute> extensionSet = extensionMap.get(extension);
			if(extensionSet == null) {
				extensionSet = new HashSet<XAttribute>(0);
			}
			return Collections.unmodifiableCollection(extensionSet);
		}
	}
739429
@Override
	public List<Scope> getAllScopes() {
		// Get all available scopes
		List<Scope> scopes = scopeRepository.findByOrderByProjectPathDesc();

		for (Scope scope : scopes) {
		    Collector collector = collectorRepository
				.findOne(scope.getCollectorId());
		    scope.setCollector(collector);
		}

		return scopes;
	}
503229
public function getExtensions()
		{

			// Loop through extension map
			$exts = array();
			foreach (self::$extensionMap as $ext => $type) {
				if ($type == $this->type) {
					$exts[] = $ext;
				}
			}
			return $exts;

		}
1019018
protected boolean has(String extensionName) {
		List<Extensions> extensions = getExtensions(extensionName);
		return extensions != null && !extensions.isEmpty();
	}