Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Namespaces

Namespaces are a an important concept that help manage large applications with hundreds of actions. Within the Web, namespaces are managed by paths. When a request comes in, the ServletDispatcher will extract the action and namespace to determine the appropriate action to execute. For more information regarding namespaces, please refer to the xwork docs XWork documentation regarding namespaces (see Configuration). Below gives a short example of using namespaces with webworkWebWork.

Note: If a request is made to /barspace/foo.action, the action foo will be searched for in a namespace of /barspace. If the action is not found, the action will then be searched for in the default namespace. Unless specified, the default namespace will be "". In our example below, their is no action foo in the namespace /barspace, therefore the default will be searched and /foo.action will be executed.

...