detecting the end of the inspections: no addXxxListener in InspectionManager

I want to start an action - print statistics - when all the inspections
have finished.
Is that possible?

Alain

5 comments
Comment actions Permalink

No, you should vote for http://jetbrains.net/jira/browse/IDEA-2036 and
http://jetbrains.net/jira/browse/IDEABKL-2742

Alain Ravet wrote:

I want to start an action - print statistics - when all the inspections
have finished.
Is that possible?

Alain

0
Comment actions Permalink

>> Is that possible?
> No


JB, please comment.
I need - *1 - to inject some code before and after the analysis. I'm
sure it's possible. Perhaps not through the openAPI.

Use case:
10 inspections all use a slow operation - finding references -, that
takes 90% of their time.
As inspections are independant, this action is repeated 10 times.
Obviously, it should be done only once, and cached.

==> the cache must be initialized, before the analysis begins, and
deleted when it's finished.

Alain

0
Comment actions Permalink

Not JetBrains, but I'll comment anyway. I'm absolutely sure Keith is correct, and this isn't possible with the current API. I've got about forty global inspections teed up that I'd love to do, but can't due to lack of the functionality you are describing (plus some other odds and sods missing, see the referenced JIRA items). I've given a lot of thought to workarounds, but have unable to come up with any suitable ones.

The request is backlogged, but Maxim saw fit to put it's priority as "Major". Perhaps an early post-Irida release...

--Dave Griffith

0
Comment actions Permalink

Dave Griffith wrote:

>..
>The request is backlogged, but Maxim saw fit to put it's priority as "Major".
>

>


Adding a simple (add/remove)Analysis(Start/End)Listener would already
help a lot.
Am I missing a hidden danger, that would make implementing this a
difficult task.


Alain

0
Comment actions Permalink

Adding a simple (add/remove)Analysis(Start/End)Listener would already help a lot.

Agreed.

+
Am I missing a hidden danger, that would make implementing this a difficult task.
+

Swing threading issues would be my guess, with a side-order of fear of memory leaks...

--Dave Griffith

0

Please sign in to leave a comment.