That's the apply() method from a hullmod effect, isn't it? That's not really the same as what you'd do from a script.
Let's back up a bit - how much Java knowledge do you have?
Intermediate I would say.
OOP concepts should be known to me (Objects, Classes, inheritance, Polymorphism. I lack experience with abstraction tho.)
The deal here is. ShipAPI is an interface which does nothing by itself. Therefore it needs to take on a form of an object, and that is done by giving it a reference to an object which has the ShipAPI interface implemented. After that I can work with any function that is included in the ShipAPI (engine.getPlayerShip returns a reference to the player ship object as far as my understanding goes).
Interface ShipSkilleffect should work the same way. It offers two methods Apply and Unapply as far as the documentation says.
Logically in order to use the ShipSkillEffect interface, I would have to refer to a class that has the interface implemented.
The apply function takes mutableShipStatsAPI interface as an input, so again I would need to refer to an object which already has it implemented.
What I am saying might be or might not be completely and utterly wrong, so I do not mind being corrected. In fact I would appreciate it.
Thanks for the help in advance.