Example usage for org.eclipse.jdt.core.search TypeNameMatch getAccessibility

List of usage examples for org.eclipse.jdt.core.search TypeNameMatch getAccessibility

Introduction

In this page you can find the example usage for org.eclipse.jdt.core.search TypeNameMatch getAccessibility.

Prototype

public abstract int getAccessibility();

Source Link

Document

Returns the accessibility of the type name match

Usage

From source file:org.eclipse.scout.sdk.saml.importer.internal.jdt.imports.TypeNameMatchCollector.java

License:Open Source License

private boolean inScope(TypeNameMatch match) {
    //    if (TypeFilter.isFiltered(match)) return false;

    int accessibility = match.getAccessibility();
    switch (accessibility) {
    case IAccessRule.K_NON_ACCESSIBLE:
        return JavaCore.DISABLED.equals(JavaCore.getOption(JavaCore.CODEASSIST_FORBIDDEN_REFERENCE_CHECK));
    case IAccessRule.K_DISCOURAGED:
        return JavaCore.DISABLED.equals(JavaCore.getOption(JavaCore.CODEASSIST_DISCOURAGED_REFERENCE_CHECK));
    default:/*from  w  ww .  jav  a  2 s .  c o m*/
        return true;
    }
}