switch(proposal.getKind()) { case CompletionProposal.KEYWORD: internalAcceptKeyword( proposal.getName(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance()); break; case CompletionProposal.PACKAGE_REF: internalAcceptPackage( proposal.getDeclarationSignature(), proposal.getCompletion(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance()); break; case CompletionProposal.TYPE_REF: internalAcceptType(proposal); break; case CompletionProposal.FIELD_REF: char[] signatureSimpleName= Signature.getSignatureSimpleName(proposal.getSignature()); if (signatureSimpleName == null) signatureSimpleName= CharOperation.NO_CHAR; internalAcceptField( Signature.getSignatureQualifier(proposal.getDeclarationSignature()), Signature.getSignatureSimpleName(proposal.getDeclarationSignature()), proposal.getName(), Signature.getSignatureQualifier(proposal.getSignature()), signatureSimpleName, proposal.getCompletion(), proposal.getFlags(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance() ); break; case CompletionProposal.METHOD_REF: internalAcceptMethod(proposal); break; case CompletionProposal.METHOD_DECLARATION: internalAcceptMethodDeclaration( Signature.getSignatureQualifier(proposal.getDeclarationSignature()), Signature.getSignatureSimpleName(proposal.getDeclarationSignature()), proposal.getName(), getParameterPackages(proposal.getSignature()), getParameterTypes(proposal.getSignature()), proposal.findParameterNames(null) == null ? CharOperation.NO_CHAR_CHAR : proposal.findParameterNames(null), Signature.getSignatureQualifier(Signature.getReturnType(proposal.getSignature())), Signature.getSignatureSimpleName(Signature.getReturnType(proposal.getSignature())), proposal.getCompletion(), proposal.getFlags(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance() ); break; case CompletionProposal.ANONYMOUS_CLASS_DECLARATION: internalAcceptAnonymousType( Signature.getSignatureQualifier(proposal.getDeclarationSignature()), Signature.getSignatureSimpleName(proposal.getDeclarationSignature()), getParameterPackages(proposal.getSignature()), getParameterTypes(proposal.getSignature()), proposal.findParameterNames(null) == null ? CharOperation.NO_CHAR_CHAR : proposal.findParameterNames(null), proposal.getCompletion(), proposal.getFlags(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance() ); break; case CompletionProposal.LABEL_REF : internalAcceptLabel( proposal.getCompletion(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance() ); break; case CompletionProposal.LOCAL_VARIABLE_REF: signatureSimpleName= Signature.getSignatureSimpleName(proposal.getSignature()); if (signatureSimpleName == null) signatureSimpleName= CharOperation.NO_CHAR; internalAcceptLocalVariable( proposal.getCompletion(), Signature.getSignatureQualifier(proposal.getSignature()), signatureSimpleName, proposal.getFlags(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance() ); break; case CompletionProposal.VARIABLE_DECLARATION: signatureSimpleName= Signature.getSignatureSimpleName(proposal.getSignature()); if (signatureSimpleName == null) signatureSimpleName= CharOperation.NO_CHAR; internalAcceptLocalVariable( proposal.getCompletion(), Signature.getSignatureQualifier(proposal.getSignature()), signatureSimpleName, proposal.getFlags(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance() ); break; case CompletionProposal.POTENTIAL_METHOD_DECLARATION: internalAcceptPotentialMethodDeclaration( Signature.getSignatureQualifier(proposal.getDeclarationSignature()), Signature.getSignatureSimpleName(proposal.getDeclarationSignature()), proposal.getName(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance() ); break;
try { switch (proposal.getKind()) { case CompletionProposal.KEYWORD: internalAcceptKeyword(proposal.getName(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance()); break; case CompletionProposal.PACKAGE_REF: internalAcceptPackage(proposal.getDeclarationSignature(), proposal.getCompletion(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance()); break; case CompletionProposal.TYPE_REF: internalAcceptType(proposal); break; case CompletionProposal.FIELD_REF: char[] signatureSimpleName= Signature.getSignatureSimpleName(proposal.getSignature()); if (signatureSimpleName == null) signatureSimpleName= CharOperation.NO_CHAR; internalAcceptField(Signature.getSignatureQualifier(proposal.getDeclarationSignature()), Signature.getSignatureSimpleName(proposal.getDeclarationSignature()), proposal.getName(), Signature.getSignatureQualifier(proposal.getSignature()), signatureSimpleName, proposal.getCompletion(), proposal.getFlags(), proposal.getReplaceStart(), proposal .getReplaceEnd(), proposal.getRelevance()); break; case CompletionProposal.METHOD_REF: internalAcceptMethod(proposal); break; case CompletionProposal.METHOD_DECLARATION: internalAcceptMethodDeclaration(Signature.getSignatureQualifier(proposal.getDeclarationSignature()), Signature.getSignatureSimpleName(proposal.getDeclarationSignature()), proposal .getName(), getParameterPackages(proposal.getSignature()), getParameterTypes(proposal.getSignature()), proposal.findParameterNames(null) == null ? CharOperation.NO_CHAR_CHAR : proposal.findParameterNames(null), Signature.getSignatureQualifier(Signature .getReturnType(proposal.getSignature())), Signature.getSignatureSimpleName(Signature.getReturnType(proposal.getSignature())), proposal.getCompletion(), proposal .getFlags(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance()); break; case CompletionProposal.ANONYMOUS_CLASS_DECLARATION: internalAcceptAnonymousType(Signature.getSignatureQualifier(proposal.getDeclarationSignature()), Signature.getSignatureSimpleName(proposal.getDeclarationSignature()), getParameterPackages(proposal.getSignature()), getParameterTypes(proposal.getSignature()), proposal.findParameterNames(null) == null ? CharOperation.NO_CHAR_CHAR : proposal.findParameterNames(null), proposal.getCompletion(), proposal.getFlags(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance()); break; case CompletionProposal.LABEL_REF: internalAcceptLabel(proposal.getCompletion(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance()); break; case CompletionProposal.LOCAL_VARIABLE_REF: signatureSimpleName= Signature.getSignatureSimpleName(proposal.getSignature()); if (signatureSimpleName == null) signatureSimpleName= CharOperation.NO_CHAR; internalAcceptLocalVariable(proposal.getCompletion(), Signature.getSignatureQualifier(proposal.getSignature()), signatureSimpleName, proposal.getFlags(), proposal .getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance()); break; case CompletionProposal.VARIABLE_DECLARATION: signatureSimpleName= Signature.getSignatureSimpleName(proposal.getSignature()); if (signatureSimpleName == null) signatureSimpleName= CharOperation.NO_CHAR; internalAcceptLocalVariable(proposal.getCompletion(), Signature.getSignatureQualifier(proposal.getSignature()), signatureSimpleName, proposal.getFlags(), proposal .getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance()); break; case CompletionProposal.POTENTIAL_METHOD_DECLARATION: internalAcceptPotentialMethodDeclaration(Signature.getSignatureQualifier(proposal.getDeclarationSignature()), Signature.getSignatureSimpleName(proposal.getDeclarationSignature()), proposal.getName(), proposal.getReplaceStart(), proposal.getReplaceEnd(), proposal.getRelevance()); break;  } } catch (IllegalArgumentException e) {    JavaPlugin.log(new Status(IStatus.ERROR, JavaPlugin.getPluginId(), IStatus.OK, "Exception when processing proposal for: " + String.valueOf(proposal.getName()), e));
	public void accept(CompletionProposal proposal) {		if (isIgnored(proposal.getKind()))			return;				switch(proposal.getKind()) {			case CompletionProposal.KEYWORD:				internalAcceptKeyword(						proposal.getName(),						proposal.getReplaceStart(),						proposal.getReplaceEnd(),						proposal.getRelevance());				break;			case CompletionProposal.PACKAGE_REF:				internalAcceptPackage(						proposal.getDeclarationSignature(),						proposal.getCompletion(),						proposal.getReplaceStart(),						proposal.getReplaceEnd(),						proposal.getRelevance());				break;			case CompletionProposal.TYPE_REF:				internalAcceptType(proposal);				break;			case CompletionProposal.FIELD_REF:				char[] signatureSimpleName= Signature.getSignatureSimpleName(proposal.getSignature());				if (signatureSimpleName == null) signatureSimpleName= CharOperation.NO_CHAR;				internalAcceptField(						Signature.getSignatureQualifier(proposal.getDeclarationSignature()),						Signature.getSignatureSimpleName(proposal.getDeclarationSignature()),						proposal.getName(),						Signature.getSignatureQualifier(proposal.getSignature()),						signatureSimpleName, 						proposal.getCompletion(),						proposal.getFlags(),						proposal.getReplaceStart(),						proposal.getReplaceEnd(),						proposal.getRelevance()				);				break;			case CompletionProposal.METHOD_REF:				internalAcceptMethod(proposal);				break;			case CompletionProposal.METHOD_DECLARATION:				internalAcceptMethodDeclaration(						Signature.getSignatureQualifier(proposal.getDeclarationSignature()),						Signature.getSignatureSimpleName(proposal.getDeclarationSignature()),						proposal.getName(),						getParameterPackages(proposal.getSignature()),						getParameterTypes(proposal.getSignature()),						proposal.findParameterNames(null) == null ? CharOperation.NO_CHAR_CHAR : proposal.findParameterNames(null),						Signature.getSignatureQualifier(Signature.getReturnType(proposal.getSignature())),						Signature.getSignatureSimpleName(Signature.getReturnType(proposal.getSignature())),						proposal.getCompletion(),						proposal.getFlags(),						proposal.getReplaceStart(),						proposal.getReplaceEnd(),						proposal.getRelevance()				);				break;			case CompletionProposal.ANONYMOUS_CLASS_DECLARATION:				internalAcceptAnonymousType(						Signature.getSignatureQualifier(proposal.getDeclarationSignature()),						Signature.getSignatureSimpleName(proposal.getDeclarationSignature()), 						getParameterPackages(proposal.getSignature()),						getParameterTypes(proposal.getSignature()),						proposal.findParameterNames(null) == null ? CharOperation.NO_CHAR_CHAR : proposal.findParameterNames(null),						proposal.getCompletion(),						proposal.getFlags(),						proposal.getReplaceStart(),						proposal.getReplaceEnd(),						proposal.getRelevance()				);				break;			case CompletionProposal.LABEL_REF :				internalAcceptLabel(						proposal.getCompletion(),						proposal.getReplaceStart(),						proposal.getReplaceEnd(),						proposal.getRelevance()				);				break;			case CompletionProposal.LOCAL_VARIABLE_REF:				signatureSimpleName= Signature.getSignatureSimpleName(proposal.getSignature());				if (signatureSimpleName == null) signatureSimpleName= CharOperation.NO_CHAR;				internalAcceptLocalVariable(						proposal.getCompletion(),						Signature.getSignatureQualifier(proposal.getSignature()),						signatureSimpleName,						proposal.getFlags(),						proposal.getReplaceStart(),						proposal.getReplaceEnd(),						proposal.getRelevance()				);				break;			case CompletionProposal.VARIABLE_DECLARATION:				signatureSimpleName= Signature.getSignatureSimpleName(proposal.getSignature());				if (signatureSimpleName == null) signatureSimpleName= CharOperation.NO_CHAR;				internalAcceptLocalVariable(						proposal.getCompletion(),						Signature.getSignatureQualifier(proposal.getSignature()),						signatureSimpleName,						proposal.getFlags(),						proposal.getReplaceStart(),						proposal.getReplaceEnd(),						proposal.getRelevance()				);				break;			case CompletionProposal.POTENTIAL_METHOD_DECLARATION:				internalAcceptPotentialMethodDeclaration(						Signature.getSignatureQualifier(proposal.getDeclarationSignature()),						Signature.getSignatureSimpleName(proposal.getDeclarationSignature()),						proposal.getName(),						proposal.getReplaceStart(),						proposal.getReplaceEnd(),						proposal.getRelevance()				);				break;						}	}	