Class ClassCompletion
java.lang.Object
org.fife.ui.autocomplete.AbstractCompletion
org.fife.ui.autocomplete.BasicCompletion
org.fife.rsta.ac.java.AbstractJavaSourceCompletion
org.fife.rsta.ac.java.ClassCompletion
- All Implemented Interfaces:
Comparable<org.fife.ui.autocomplete.Completion>, JavaSourceCompletion, org.fife.ui.autocomplete.Completion
Completion for a Java class, interface or enum.
- Version:
- 1.0
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionClassCompletion(org.fife.ui.autocomplete.CompletionProvider provider, ClassFile cf) -
Method Summary
Modifier and TypeMethodDescriptionintcompareTo(org.fife.ui.autocomplete.Completion c2) Overridden to ensure that two completions don't just have the same text value (ignoring case), but that they're of the same "type" ofCompletionas well, so, for example, a completion for the "String" class won't clash with a completion for a "string" LocalVar.booleanForce subclasses to override equals().getClassName(boolean fullyQualified) Returns the name of the class represented by this completion.getIcon()Returns the package this class or interface is in.inthashCode()voidrendererText(Graphics g, int x, int y, boolean selected) Used byJavaCellRendererto render this completion choice.Methods inherited from class AbstractJavaSourceCompletion
getAlreadyEnteredMethods inherited from class org.fife.ui.autocomplete.BasicCompletion
getReplacementText, getShortDescription, setShortDescription, setSummary, toStringMethods inherited from class org.fife.ui.autocomplete.AbstractCompletion
getInputText, getProvider, getRelevance, setIcon, setRelevanceMethods inherited from interface org.fife.ui.autocomplete.Completion
getInputText, getProvider, getRelevance, getReplacementText
-
Field Details
-
cf
-
-
Constructor Details
-
ClassCompletion
ClassCompletion(org.fife.ui.autocomplete.CompletionProvider provider, ClassFile cf)
-
-
Method Details
-
compareTo
public int compareTo(org.fife.ui.autocomplete.Completion c2) Description copied from class:AbstractJavaSourceCompletionOverridden to ensure that two completions don't just have the same text value (ignoring case), but that they're of the same "type" ofCompletionas well, so, for example, a completion for the "String" class won't clash with a completion for a "string" LocalVar.- Specified by:
compareToin interfaceComparable<org.fife.ui.autocomplete.Completion>- Specified by:
compareToin interfaceorg.fife.ui.autocomplete.Completion- Overrides:
compareToin classAbstractJavaSourceCompletion- Parameters:
c2- Another completion instance.- Returns:
- How this completion compares to the other one.
-
equals
Description copied from interface:JavaSourceCompletionForce subclasses to override equals(). TODO: Remove me- Specified by:
equalsin interfaceJavaSourceCompletion- Overrides:
equalsin classObject
-
getClassName
Returns the name of the class represented by this completion.- Parameters:
fullyQualified- Whether the returned name should be fully qualified.- Returns:
- The class name.
- See Also:
-
getIcon
- Specified by:
getIconin interfaceorg.fife.ui.autocomplete.Completion- Overrides:
getIconin classorg.fife.ui.autocomplete.AbstractCompletion
-
getPackageName
Returns the package this class or interface is in.- Returns:
- The package, or
nullif it is not in a package. - See Also:
-
getSummary
- Specified by:
getSummaryin interfaceorg.fife.ui.autocomplete.Completion- Overrides:
getSummaryin classorg.fife.ui.autocomplete.BasicCompletion
-
getToolTipText
- Specified by:
getToolTipTextin interfaceorg.fife.ui.autocomplete.Completion- Overrides:
getToolTipTextin classorg.fife.ui.autocomplete.AbstractCompletion
-
hashCode
-
rendererText
Description copied from interface:JavaSourceCompletionUsed byJavaCellRendererto render this completion choice.- Parameters:
g- The graphics context to render to.x- The x-offset at which to render.y- The y-offset at which to render.selected- Whether this completion is currently selected/active.
-