Class SampleAction

java.lang.Object
org.apache.struts2.ActionSupport
org.conical.common.bbl.web.struts.actions.BaseAction
org.conical.common.bbl.web.struts.actions.SampleAction
All Implemented Interfaces:
Serializable, org.apache.struts2.action.Action, org.apache.struts2.action.ServletRequestAware, org.apache.struts2.action.ServletResponseAware, org.apache.struts2.interceptor.ValidationAware, org.apache.struts2.locale.LocaleProvider, org.apache.struts2.text.TextProvider, org.apache.struts2.Validateable

public class SampleAction extends BaseAction
This class exists as a simple child of BaseAction to show how little code must be written to implement an action. It can be used as a model for those learning Struts and the BBL Struts framework.
Author:
rdoherty
See Also:
  • Constructor Details

    • SampleAction

      public SampleAction()
  • Method Details

    • actionRequiresLogin

      protected boolean actionRequiresLogin()
      Returns true since most applications require login.
      Specified by:
      actionRequiresLogin in class BaseAction
      Returns:
      true
    • doWork

      protected String doWork() throws Exception
      Performs no side effects; simply returns success.
      Specified by:
      doWork in class BaseAction
      Returns:
      success
      Throws:
      Exception - if something goes wrong