Class SetPageTagsAction

  • All Implemented Interfaces:
    Action

    public class SetPageTagsAction
    extends Object
    implements Action
    Sets tags to the page of a given resource. This will overwrite existing tags.
    Author:
    Roland Gruber
    • Constructor Detail

      • SetPageTagsAction

        public SetPageTagsAction​(BindingContext context,
                                 String... tags)
        Constructor
        Parameters:
        context - binding context
        tags - tag names
    • Method Detail

      • doAction

        public String doAction​(org.apache.sling.api.resource.Resource resource)
                        throws org.apache.sling.api.resource.PersistenceException
        Description copied from interface: Action
        Runs an action.
        Specified by:
        doAction in interface Action
        Parameters:
        resource - resource to run action on
        Returns:
        output message
        Throws:
        org.apache.sling.api.resource.PersistenceException - error saving to JCR