com.opensymphony.xwork2
Class DefaultUnknownHandlerManager

java.lang.Object
  extended by com.opensymphony.xwork2.DefaultUnknownHandlerManager
All Implemented Interfaces:
UnknownHandlerManager

public class DefaultUnknownHandlerManager
extends Object
implements UnknownHandlerManager

Default implementation of UnknownHandlerManager

See Also:
UnknownHandlerManager

Field Summary
protected  ArrayList<UnknownHandler> unknownHandlers
           
 
Constructor Summary
DefaultUnknownHandlerManager()
           
 
Method Summary
protected  void build()
          Builds a list of UnknownHandlers in the order specified by the configured "unknown-handler-stack".
 List<UnknownHandler> getUnknownHandlers()
           
 ActionConfig handleUnknownAction(String namespace, String actionName)
          Iterate over UnknownHandlers and return the result of the first one that can handle it
 Object handleUnknownMethod(Object action, String methodName)
          Iterate over UnknownHandlers and return the result of the first one that can handle it
 Result handleUnknownResult(ActionContext actionContext, String actionName, ActionConfig actionConfig, String resultCode)
          Iterate over UnknownHandlers and return the result of the first one that can handle it
 boolean hasUnknownHandlers()
           
 void setContainer(Container container)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

unknownHandlers

protected ArrayList<UnknownHandler> unknownHandlers
Constructor Detail

DefaultUnknownHandlerManager

public DefaultUnknownHandlerManager()
Method Detail

setContainer

public void setContainer(Container container)

build

protected void build()
              throws Exception
Builds a list of UnknownHandlers in the order specified by the configured "unknown-handler-stack". If "unknown-handler-stack" was not configured, all UnknownHandlers will be returned, in no specific order

Throws:
Exception

handleUnknownResult

public Result handleUnknownResult(ActionContext actionContext,
                                  String actionName,
                                  ActionConfig actionConfig,
                                  String resultCode)
Iterate over UnknownHandlers and return the result of the first one that can handle it

Specified by:
handleUnknownResult in interface UnknownHandlerManager

handleUnknownMethod

public Object handleUnknownMethod(Object action,
                                  String methodName)
                           throws NoSuchMethodException
Iterate over UnknownHandlers and return the result of the first one that can handle it

Specified by:
handleUnknownMethod in interface UnknownHandlerManager
Throws:
NoSuchMethodException

handleUnknownAction

public ActionConfig handleUnknownAction(String namespace,
                                        String actionName)
Iterate over UnknownHandlers and return the result of the first one that can handle it

Specified by:
handleUnknownAction in interface UnknownHandlerManager

hasUnknownHandlers

public boolean hasUnknownHandlers()
Specified by:
hasUnknownHandlers in interface UnknownHandlerManager

getUnknownHandlers

public List<UnknownHandler> getUnknownHandlers()
Specified by:
getUnknownHandlers in interface UnknownHandlerManager


Copyright © 2000–2017 Apache Software Foundation. All rights reserved.