Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Copyright (c) 2008 IBM Corporation and others. All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at Contributors: IBM Corporation - initial API and implementation /
package org.eclipse.jdt.internal.codeassist.impl;
import  org.eclipse.core.runtime.IProgressMonitor;
public class AssistSourceMethod extends ResolvedSourceMethod {
	private Map bindingCache;
	private Map infoCache;
	private String uniqueKey;
	private boolean isResolved;
	public AssistSourceMethod(JavaElement parentString nameString[] parameterTypesMap bindingCacheMap infoCache) {
		this. = bindingCache;
		this. = infoCache;
	public Object getElementInfo(IProgressMonitor monitorthrows JavaModelException {
		return this..get(this);
	/* (non-Javadoc)
	 * @see org.eclipse.jdt.internal.core.SourceMethod#getKey()
	public String getKey() {
		if (this. == null) {
			Binding binding = (Bindingthis..get(this);
			if (binding != null) {
				this. = true;
				this. = new String(binding.computeUniqueKey());
else {
				this. = false;
				try {
					this. = getKey(thisfalse/*don't open*/);
catch (JavaModelException e) {
					// happen only if force open is true
					return null;
		return this.;
	public boolean isResolved() {
		return this.;
	protected void toStringInfo(int tabStringBuffer bufferObject info,boolean showResolvedInfo) {
		super.toStringInfo(tabbufferinfoshowResolvedInfo && isResolved());
	public IAnnotation getAnnotation(String annotationName) {
		return new AssistAnnotation(thisannotationNamethis.);
	public IType getType(String typeNameint count) {
		AssistSourceType type = new AssistSourceType(thistypeNamethis.this.);
		type.occurrenceCount = count;
		return type;
	public ITypeParameter getTypeParameter(String typeParameterName) {
		return new AssistTypeParameter(thistypeParameterNamethis.);
New to GrepCode? Check out our FAQ X