requestor parameter in VirtualFile operations
已回答
All write operations in VirtualFile need a "requestor" parameter, from the document I know it should be the caller of the operation and it could be anything but null (null has special meaning).
I use my class.this as the requestor, it works, anyway I still don't understand what it should be in most case and when it will be used in IDEA.
Thanks
请先登录再写评论。
It's just some user data to pass with the change. Some listeners use it to make decisions. There are 2 special values:
Everything else is at your discretion. Most clients pass "this" in it, just because they have to pass something.
Thank you Peter.