Interface ScriptProcessor

  • All Superinterfaces:
    org.alfresco.processor.Processor
    All Known Implementing Classes:
    RhinoScriptProcessor

    public interface ScriptProcessor
    extends org.alfresco.processor.Processor
    Script processor interface
    Author:
    Roy Wetherall
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.Object execute​(java.lang.String location, java.util.Map<java.lang.String,​java.lang.Object> model)
      Execute script
      java.lang.Object execute​(org.alfresco.service.cmr.repository.NodeRef nodeRef, org.alfresco.service.namespace.QName contentProp, java.util.Map<java.lang.String,​java.lang.Object> model)
      Execute script
      java.lang.Object execute​(ScriptLocation location, java.util.Map<java.lang.String,​java.lang.Object> model)
      Execute script
      java.lang.Object executeString​(java.lang.String script, java.util.Map<java.lang.String,​java.lang.Object> model)
      Execute script string
      void reset()
      Reset the processor - such as clearing any internal caches etc.
      • Methods inherited from interface org.alfresco.processor.Processor

        getExtension, getName, registerProcessorExtension
    • Method Detail

      • execute

        java.lang.Object execute​(ScriptLocation location,
                                 java.util.Map<java.lang.String,​java.lang.Object> model)
        Execute script
        Parameters:
        location - the location of the script
        model - context model
        Returns:
        Object the result of the script
      • execute

        java.lang.Object execute​(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                                 org.alfresco.service.namespace.QName contentProp,
                                 java.util.Map<java.lang.String,​java.lang.Object> model)
        Execute script
        Parameters:
        nodeRef - the script node reference
        contentProp - the content property of the script
        model - the context model
        Returns:
        Object the result of the script
      • execute

        java.lang.Object execute​(java.lang.String location,
                                 java.util.Map<java.lang.String,​java.lang.Object> model)
        Execute script
        Parameters:
        location - the classpath string locating the script
        model - the context model
        Returns:
        Object the result of the script
      • executeString

        java.lang.Object executeString​(java.lang.String script,
                                       java.util.Map<java.lang.String,​java.lang.Object> model)
        Execute script string
        Parameters:
        script - the script string
        model - the context model
        Returns:
        Obejct the result of the script
      • reset

        void reset()
        Reset the processor - such as clearing any internal caches etc.