Make a decorator for plugin methods that are invocable #189

Closed
opened 2022-07-05 01:39:08 +02:00 by blacklight · 0 comments
Owner

Created by: BlackLight

Purposes:

  • Better identify (and automatically parse for external documentation) which methods of a plugin class are supposed to be invoked externally

  • Security - prevent internal methods from being invoked

class MyMusicPlugin(Plugin):
    # ...
    @invocable
    def play(self):
    # ...
*Created by: BlackLight* Purposes: * Better identify (and automatically parse for external documentation) which methods of a plugin class are supposed to be invoked externally * Security - prevent internal methods from being invoked ```python class MyMusicPlugin(Plugin): # ... @invocable def play(self): # ... ```
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: platypush/platypush#189
No description provided.