| Previous CloneSet | Next CloneSet | Back to Main Report |
| Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
|---|---|---|---|---|
| 12 | 2 | 1 | 0.995 | class_body_declaration |
| Clone Abstraction | Parameter Bindings |
| Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
|---|---|---|---|
| 1 | 12 | 257 | plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/CompletionProposalCategory.java |
| 2 | 12 | 282 | plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/CompletionProposalCategory.java |
| ||||
/**
* Safely computes completion proposals of all computers of this category through their
* extension. If an extension is disabled, throws an exception or otherwise does not adhere to
* the contract described in {@link IJavaCompletionProposalComputer}, it is disabled.
*
* @param context the invocation context passed on to the extension
* @param partition the partition type where to invocation occurred
* @param monitor the progress monitor passed on to the extension
* @return the list of computed completion proposals (element type:
* {@link org.eclipse.jface.text.contentassist.ICompletionProposal})
*/
public List computeCompletionProposals(ContentAssistInvocationContext context, String partition, SubProgressMonitor monitor) {
fLastError = null;
List result = new ArrayList();
List descriptors = new ArrayList(fRegistry.getProposalComputerDescriptors(partition));
for (Iterator it = descriptors.iterator(); it.hasNext();) {
CompletionProposalComputerDescriptor desc = (CompletionProposalComputerDescriptor) it.next();
if (desc.getCategory() == this )
result.addAll(desc.computeCompletionProposals(context, monitor));
if (fLastError == null)
fLastError = desc.getErrorMessage();
}
return result;
}
|
| ||||
/**
* Safely computes context information objects of all computers of this category through their
* extension. If an extension is disabled, throws an exception or otherwise does not adhere to
* the contract described in {@link IJavaCompletionProposalComputer}, it is disabled.
*
* @param context the invocation context passed on to the extension
* @param partition the partition type where to invocation occurred
* @param monitor the progress monitor passed on to the extension
* @return the list of computed context information objects (element type:
* {@link org.eclipse.jface.text.contentassist.IContextInformation})
*/
public List computeContextInformation(ContentAssistInvocationContext context, String partition, SubProgressMonitor monitor) {
fLastError = null;
List result = new ArrayList();
List descriptors = new ArrayList(fRegistry.getProposalComputerDescriptors(partition));
for (Iterator it = descriptors.iterator(); it.hasNext();) {
CompletionProposalComputerDescriptor desc = (CompletionProposalComputerDescriptor) it.next();
if (desc.getCategory() == this )
result.addAll(desc.computeContextInformation(context, monitor));
if (fLastError == null)
fLastError = desc.getErrorMessage();
}
return result;
}
|
| |||
/**
* Safely computes completion proposals of all computers of this category through their
* extension. If an extension is disabled, throws an exception or otherwise does not adhere to
* the contract described in {@link IJavaCompletionProposalComputer}, it is disabled.
*
* @param context the invocation context passed on to the extension
* @param partition the partition type where to invocation occurred
* @param monitor the progress monitor passed on to the extension
* @return the list of computed completion proposals (element type:
* {@link org.eclipse.jface.text.contentassist.ICompletionProposal})
*/
/**
* Safely computes context information objects of all computers of this category through their
* extension. If an extension is disabled, throws an exception or otherwise does not adhere to
* the contract described in {@link IJavaCompletionProposalComputer}, it is disabled.
*
* @param context the invocation context passed on to the extension
* @param partition the partition type where to invocation occurred
* @param monitor the progress monitor passed on to the extension
* @return the list of computed context information objects (element type:
* {@link org.eclipse.jface.text.contentassist.IContextInformation})
*/
public List [[#variableb6b87240]](ContentAssistInvocationContext context, String partition, SubProgressMonitor monitor) {
fLastError = null;
List result = new ArrayList();
List descriptors = new ArrayList(fRegistry.getProposalComputerDescriptors(partition));
for (Iterator it = descriptors.iterator(); it.hasNext();) {
CompletionProposalComputerDescriptor desc = (CompletionProposalComputerDescriptor) it.next();
if (desc.getCategory() == this )
result.addAll(desc. [[#variableb6b87240]](context, monitor));
if (fLastError == null)
fLastError = desc.getErrorMessage();
}
return result;
}
|
| CloneAbstraction |
| Parameter Index | Clone Instance | Parameter Name | Value |
|---|---|---|---|
| 1 | 1 | [[#b6b87240]] | computeCompletionProposals |
| 1 | 2 | [[#b6b87240]] | computeContextInformation |