private String resolveManager()

in com.microsoft.java.lsif.core/src/com/microsoft/java/lsif/core/internal/visitors/SymbolData.java [320:353]


	private String resolveManager(IClassFile cf, MonikerKind monikerKind, IJavaProject javaProject,
			boolean hasPackageInformation) {
		if (cf != null) {
			try {
				IPath path = cf.getPath();
				IPackageFragmentRoot root = javaProject.findPackageFragmentRoot(path);
				IClasspathEntry container = root.getRawClasspathEntry();
				IPath containerPath = container.getPath();
				String pathName = containerPath.toString();
				if (pathName.startsWith(JavaRuntime.JRE_CONTAINER)) {
					if (!(root instanceof JarPackageFragmentRoot)) {
						return "";
					}
					Manifest manifest = ((JarPackageFragmentRoot) root).getManifest();
					if (manifest == null) {
						return "";
					}
					Attributes attributes = manifest.getMainAttributes();
					String vendor = attributes.getValue("Implementation-Vendor");
					if (StringUtils.isEmpty(vendor)) {
						return "";
					}
					return String.format(PackageInformation.JDK + "(%1$s)", vendor);
				} else {
					return PackageInformation.MAVEN;
				}
			} catch (JavaModelException e) {
				JavaLanguageServerPlugin.logException(e.getMessage(), e);
			}
		} else if (monikerKind == MonikerKind.EXPORT && hasPackageInformation) {
			return PackageInformation.MAVEN;
		}
		return "";
	}