Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 


Eclipse JDT
Release 3.5

org.eclipse.jdt.ui.text.java
Class ClasspathFixProcessor

java.lang.Object
  extended by 
org.eclipse.jdt.ui.text.java.ClasspathFixProcessor

public abstract class ClasspathFixProcessor
extends Object

Class to be implemented by contributors to the extension point org.eclipse.jdt.ui.classpathFixProcessors.

Since:
3.4

Nested Class Summary
static class ClasspathFixProcessor.ClasspathFixProposal
          A proposal to fix a class path issue.
 
Constructor Summary
ClasspathFixProcessor ()
           
 
Method Summary
static  ClasspathFixProcessor.ClasspathFixProposal[] getContributedFixImportProposals ( IJavaProject project, String name, MultiStatus status)
          Evaluates all contributed proposals that can fix non-resolvable imports.
abstract   ClasspathFixProcessor.ClasspathFixProposal[] getFixImportProposals ( IJavaProject project, String name)
          Returns proposal that can fix non-resolvable imports.
 
Methods inherited from class java.lang. Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClasspathFixProcessor

public ClasspathFixProcessor()
Method Detail

getFixImportProposals

public abstract 
ClasspathFixProcessor.ClasspathFixProposal[] getFixImportProposals(
IJavaProject project,
                                                                                   
String name)
                                                                            throws 
CoreException
Returns proposal that can fix non-resolvable imports. The proposal is expected to change the class path or a classpath container so that the missing type can be resolved. A proposal should also consider to fix related types. For example, when a reference to junit.framework.TestCase is requested, it makes sense to import the full JUnit library, not just fixing the missing type.

Parameters:
project - the current project
name - the missing type to be added to the class path. The entries can be either a
  • qualified type name, like 'junit.framework.Test'
  • simple type name, like 'TestCase'
  • on demand import name, like 'org.junit.*'
Returns:
returns proposals to fix the class path so that the missing types are found. If no proposals can be offered, either null or the empty array can be returned. If null is returned, also the processors overridden by this processor are asked. If a non null result is returned, all overridden processors are skipped.
Throws:
CoreException - thrown when the creation of the proposals fails

getContributedFixImportProposals

public static 
ClasspathFixProcessor.ClasspathFixProposal[] getContributedFixImportProposals(
IJavaProject project,
                                                                                            
String name,
                                                                                            
MultiStatus status)
Evaluates all contributed proposals that can fix non-resolvable imports.

Parameters:
project - the current project
name - the missing type to be added to the class path. The entries can be either a
  • qualified type name, like 'junit.framework.Test'
  • simple type name, like 'TestCase'
  • on demand import name, like 'org.junit.*'
status - a MultiStatus to collect the resulting status or null to not collect status.
Returns:
returns proposals to fix the class path so that the missing types are found.

Eclipse JDT
Release 3.5

Copyright (c) IBM Corp. and others 2000, 2008. All Rights Reserved.

 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire