Package fr.adrienbrault.idea.symfony2plugin.completion.lookup

Examples of fr.adrienbrault.idea.symfony2plugin.completion.lookup.ContainerTagLookupElement


        Set<String> uniqueTags = new HashSet<String>();

        XmlTagParser xmlEventParser = ServiceXmlParserFactory.getInstance(project, XmlTagParser.class);
        for(String tag: xmlEventParser.get()) {
            uniqueTags.add(tag);
            lookupElements.add(new ContainerTagLookupElement(tag));
        }

        SymfonyProcessors.CollectProjectUniqueKeys projectUniqueKeysStrong = new SymfonyProcessors.CollectProjectUniqueKeys(project, ServicesTagStubIndex.KEY);
        FileBasedIndexImpl.getInstance().processAllKeys(ServicesTagStubIndex.KEY, projectUniqueKeysStrong, project);

        for(String serviceName: projectUniqueKeysStrong.getResult()) {
            List<String[]> tags = FileBasedIndexImpl.getInstance().getValues(ServicesTagStubIndex.KEY, serviceName, GlobalSearchScope.getScopeRestrictedByFileTypes(GlobalSearchScope.allScope(project), XmlFileType.INSTANCE, YAMLFileType.YML));
            for(String[] tagDef: tags) {
                for(String tag: tagDef) {
                    if(!uniqueTags.contains(tag)) {
                        uniqueTags.add(tag);
                        lookupElements.add(new ContainerTagLookupElement(tag, true));
                    }
                }
            }
        }
        return lookupElements;
View Full Code Here

TOP

Related Classes of fr.adrienbrault.idea.symfony2plugin.completion.lookup.ContainerTagLookupElement

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.