/** * Returns a cached instance of the computer as described in the * extension's xml. The computer is * {@link #createComputer() created} the first time that this method * is called and then cached. * * @return a new instance of the completion proposal computer as * described by this descriptor * @throws CoreException if the creation fails * @throws InvalidRegistryObjectException if the extension is not * valid any longer (e.g. due to plug-in unloading) */ private synchronized IJavaCompletionProposalComputer getComputer() throws CoreException, InvalidRegistryObjectException { if (fComputer == null && (fActivate || isPluginLoaded())) fComputer= createComputer(); return fComputer; }
/** * Returns a cached instance of the computer as described in the * extension's xml. If the computer is not yet created and * <code>canCreate</code> is <code>true</code> then {@link #createComputer()} * is called and the result cached. * * @param canCreate <code>true</code> if the proposal computer can be created * @return a new instance of the completion proposal computer as * described by this descriptor * @throws CoreException if the creation fails * @throws InvalidRegistryObjectException if the extension is not * valid any longer (e.g. due to plug-in unloading) */ private synchronized IJavaCompletionProposalComputer getComputer(boolean canCreate) throws CoreException, InvalidRegistryObjectException { if (fComputer == null && canCreate && !fTriedLoadingComputer && (fActivate || isPluginLoaded())) { fTriedLoadingComputer= true; fComputer= createComputer(); } return fComputer; }
/** * Returns a cached instance of the computer as described in the * extension's xml. If the computer is not yet created and * <code>canCreate</code> is <code>true</code> then {@link #createComputer()} * is called and the result cached. * * @param canCreate <code>true</code> if the proposal computer can be created * @return a new instance of the completion proposal computer as * described by this descriptor * @throws CoreException if the creation fails * @throws InvalidRegistryObjectException if the extension is not * valid any longer (e.g. due to plug-in unloading) */ private synchronized IJavaCompletionProposalComputer getComputer(boolean canCreate) throws CoreException, InvalidRegistryObjectException { if (fComputer == null && canCreate && !fTriedLoadingComputer && (fActivate || isPluginLoaded())) { fTriedLoadingComputer= true; fComputer= createComputer(); } return fComputer; }