Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

...

An alternative ActionProxy can be configured thorugh through ActionProxyFactory. Typically, an ActionProxy will utilize the ActionInvocation to encapsulate the execution of a particular requiestrequest.

The ActionInvocation determines how an Action is handled: Is it being intercepted, is ? Is there a PreResultListener acting on it. ?

Essentially, ActionProxy encapsulates how an Action can be obtained. ActionInvocation encapsulates how the Action is executed when a request is invoked.

...

Code Block
 ActionProxyFactory.setFactory(new MyActionProxyFactory() {

    // Do something interesting.....

 });

ActionProxy

Code Block
 ActionProxyFactory.getFactory(new MyActionProxyFactory() {
    ....
    public ActionProxy createActionProxy(Configuration config, 
           String namespace, String actionName, Map extraContext) 
           throws Exception {
        createActionProxy(config, namespace, actionName, extraContext, true);
    }
    public ActionProxy createActionProxy(Configuration config, 
           String namespace, String actionName, Map extraContext, 
           boolean executeResult, boolean cleanupContext) 
           throws Exception {
        ....
   }
   ....
 });

...

Code Block
 ActionProxyFactory.getFactory(new MyActionProxyFactory() {
    ...
    public ActionInvocation createActionInvocation(ActionProxy actionProxy) 
                            throws Exception {
          createActionInvocation(actionProxy, new LinkedHashMap());
    }
    public ActionInvocation createActionInvocation(ActionProxy actionProxy, 
                            Map extraContext) throws Exception {
          createActionInvocation(actionProxy, extraContext, true);
    }
    public ActionInvocation createActionInvocation(ActionProxy actionProxy, 
                            Map extraContext, boolean pushAction) 
                            throws Exception {
          // doDo implementation of ActionInvocation hererhere
          .....
    }
    ...
 });

Next: Configuration Provider & Configuration