This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | Add a way for CodeCompletionHandler to know if the task has been canceled | ||
---|---|---|---|
Product: | editor | Reporter: | emi <emi> |
Component: | CSL (API & infrastructure) | Assignee: | Svata Dedic <sdedic> |
Status: | RESOLVED WONTFIX | ||
Severity: | normal | CC: | sdedic |
Priority: | P3 | Keywords: | PLAN |
Version: | 7.0 | ||
Hardware: | PC | ||
OS: | All | ||
Issue Type: | ENHANCEMENT | Exception Reporter: |
Description
emi
2011-11-24 08:18:18 UTC
BTW, the suggested api is: boolean org.netbeans.modules.csl.api.CodeCompletionContext.isTaskCanceled() I'll try it. Strictly speaking (thanks to the original design), adding a method to CCContext is an incompatible API change, so I wonder how the API will look like. My patch is on some older code and basically just a hack, so there isn't much to share. But overall, I've just added: public abstract boolean isTaskCanceled(); which defers to AsyncCompletionQuery.isTaskCancelled(). Not knowing if the task has been cancelled is a bug that wastes CPU and should allow client code to bail early if isTaskCanceled() starts returning 'true'. So I would say this is an API change that should be done in some form. This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue. Thanks for your cooperation, NetBeans IDE 8.2 Release Boss |