Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
What are EventArguments for?
sprockett
New
I'm currently looking through plugins to see how they work.
Can anyone explain to me in a nutshell what EventArguments are for?
It seems as though they are a way for the controller to pass objects to plugins (by reference), allowing plugins to modify those objects on the fly.
Would this be the main purpose of having eventarguments?
Thanks
Can anyone explain to me in a nutshell what EventArguments are for?
It seems as though they are a way for the controller to pass objects to plugins (by reference), allowing plugins to modify those objects on the fly.
Would this be the main purpose of having eventarguments?
Thanks
0
Comments
The event does have access to the object calling the event, so any properties of that object are already available to the handler. The even arguments are just a way to pass further arguments in to the event handler that may not be in the calling object.
ie. not all object properties are available to event handler, hence the need for eventarguments.