Search in sources :

Example 1 with FilteringScope

use of org.eclipse.xtext.scoping.impl.FilteringScope in project xtext-xtend by eclipse.

the class XtendImportingTypesProposalProvider method createTextApplier.

@Override
protected ConfigurableCompletionProposal.IReplacementTextApplier createTextApplier(final ContentAssistContext context, final IScope typeScope, final IQualifiedNameConverter qualifiedNameConverter, final IValueConverter<String> valueConverter) {
    final Predicate<IEObjectDescription> _function = (IEObjectDescription it) -> {
        QualifiedName _name = it.getName();
        return (!Objects.equal(_name, XtendImportedNamespaceScopeProvider.OLD_DATA_ANNOTATION));
    };
    final FilteringScope scope = new FilteringScope(typeScope, _function);
    return super.createTextApplier(context, scope, qualifiedNameConverter, valueConverter);
}
Also used : QualifiedName(org.eclipse.xtext.naming.QualifiedName) FilteringScope(org.eclipse.xtext.scoping.impl.FilteringScope) IEObjectDescription(org.eclipse.xtext.resource.IEObjectDescription)

Aggregations

QualifiedName (org.eclipse.xtext.naming.QualifiedName)1 IEObjectDescription (org.eclipse.xtext.resource.IEObjectDescription)1 FilteringScope (org.eclipse.xtext.scoping.impl.FilteringScope)1