|
org.netbeans.modules.editor.lib/3 3.23.0 19 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
@MimeLocation(subfolderName="HyperlinkProviders") public interface HyperlinkProviderExt
This interface should be implemented by anyone who whats to provide hyperlinking
functionality in the source code.
Its methods are called for all the opened editors of the given mime-type
where the hyperlinking functionality gets requested.
The providers need to be registered.
For NetBeans IDE, the default approach is to use System FileSystem.
The HyperlinkProvider(s) should be registered as ".instance" objects under
Editors/<mime-type>/HyperlinkProviders directory.
Please see lib.editor.hyperlink.HyperlinkProviderManager
for more details.
Note: there is no assurance on the order of calling of the methods in this class. The callers may call the methods in any order and even do not call some of these methods at all.
| Method Summary | |
|---|---|
int[] |
getHyperlinkSpan(Document doc,
int offset,
HyperlinkType type)
Should determine the span of hyperlink on given offset. |
Set<HyperlinkType> |
getSupportedHyperlinkTypes()
Returns all hyperlink types that are supported by this HyperlinkProvider. |
String |
getTooltipText(Document doc,
int offset,
HyperlinkType type)
Get a short description/tooltip corresponding to the given offset. |
boolean |
isHyperlinkPoint(Document doc,
int offset,
HyperlinkType type)
Should determine whether there should be a hyperlink on the given offset in the given document. |
void |
performClickAction(Document doc,
int offset,
HyperlinkType type)
The implementor should perform an action corresponding to clicking on the hyperlink on the given offset. |
| Method Detail |
|---|
Set<HyperlinkType> getSupportedHyperlinkTypes()
boolean isHyperlinkPoint(Document doc,
int offset,
HyperlinkType type)
doc - document on which to operate.offset - >=0 offset to test (it generally should be offset < doc.getLength(), but
the implementations should not depend on it)type - the hyperlink type
int[] getHyperlinkSpan(Document doc,
int offset,
HyperlinkType type)
doc - document on which to operate.offset - >=0 offset to test (it generally should be offset < doc.getLength(), but
the implementations should not depend on it)type - the hyperlink type
void performClickAction(Document doc,
int offset,
HyperlinkType type)
doc - document on which to operate.offset - >=0 offset to test (it generally should be offset < doc.getLength(), but
the implementations should not depend on it)type - the hyperlink type
String getTooltipText(Document doc,
int offset,
HyperlinkType type)
null if there should
be no tooltip.
doc - document on which to operate.offset - >=0 offset to test (it generally should be offset < doc.getLength(), but
the implementations should not depend on it)type - the hyperlink type
|
org.netbeans.modules.editor.lib/3 3.23.0 19 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||