Package io.meeds.notes.plugin
Interface NotePublicationPlugin
public interface NotePublicationPlugin
Extension point letting an addon that depends on Notes take over the
publication of an existing note in its space activity stream, so that a
publication made outside the Notes UI (an MCP client for instance) follows
the same business rules as the UI publication drawer.
Contributions are collected from every Spring context: an implementation
must be a non-final @Service bean. When no contribution handles the
note, the caller falls back to the legacy Notes publication. An exception
thrown by a contribution is final: the caller doesn't fall back, so a
contribution refusing the publication decides who can publish the note.
-
Method Summary
Modifier and TypeMethodDescriptionpublishNote(Page note, org.exoplatform.services.security.Identity identity) Publishes the note in its space activity stream.
-
Method Details
-
publishNote
Publishes the note in its space activity stream.- Parameters:
note- the existing note to publish, already checked as editable by the given identityidentity- the identity of the user publishing the note- Returns:
- the identifier of the activity displaying the published note, or null when this plugin doesn't handle the publication of the note
- Throws:
IllegalAccessException- when the user isn't allowed to publish the noteException- when the publication fails
-