PsiTreeChangeListener defines 12 different events but only 3 receive notification
Hi all,
I'm using the PsiTreeChangeListener which defines the methods beforeChildAddition, beforeChildMovement, beforeChildRemoval, beforeChildrenChange, beforeChildReplacement, beforePropertyChange, childAdded,
childMoved, childRemoved, childrenChanged, childReplaced and propertyChanged. But when I implement it and add the listener, only beforeChildrenChange, childrenChanged and propertyChanged seem to receive events. Is this normal???
I want to listen to an event when somebody deletes a piece of code from a java file. Now I receive beforeChildrenChange and childrenChanged events, of which the element inside the event is the PsiJavaFile or the PsiClass which is not specific enough for me.
I added the listener just by getting the PsiManager instance and adding the listener to it.
TIA,
Raymond Brandon
Please sign in to leave a comment.