Example usage for org.eclipse.jdt.core NamingConventions BK_TYPE_NAME

List of usage examples for org.eclipse.jdt.core NamingConventions BK_TYPE_NAME

Introduction

In this page you can find the example usage for org.eclipse.jdt.core NamingConventions BK_TYPE_NAME.

Prototype

int BK_TYPE_NAME

To view the source code for org.eclipse.jdt.core NamingConventions BK_TYPE_NAME.

Click Source Link

Document

The base name associated to this base name kind is a simple type name.

Usage

From source file:org.eclipse.xtext.common.types.xtext.ui.JdtVariableCompletions.java

License:Open Source License

public String[] getVariableProposals(String simpleTypeName, boolean isPlural, EObject ctx, VariableType varType,
        Set<String> excludedNames) {
    if (!org.eclipse.xtext.util.Strings.isEmpty(simpleTypeName)) {
        IJavaProject javaProject = null;
        if (ctx != null && ctx.eResource() != null && ctx.eResource().getResourceSet() != null)
            javaProject = javaProjectProvider.getJavaProject(ctx.eResource().getResourceSet());
        return NamingConventions.suggestVariableNames(getVariableKind(varType), NamingConventions.BK_TYPE_NAME,
                simpleTypeName, javaProject, isPlural ? 1 : 0,
                excludedNames.toArray(new String[excludedNames.size()]), false);
    }/* w  w  w .  j a v  a2  s .  c o  m*/
    return new String[0];
}