The MVC detail implementation of struts

Source: Internet
Author: User

Struts medium Core class: Actionservlet , the most important of these operations is Requestprocessor in the class Process method.

Struts Implement MVC The following is a detailed picture of:

  • 1, One start, according to web.xml Span style= "font-family: the song Body;" > load actionservlet read Span style= "FONT-FAMILY:CALIBRI;" >struts struts-config The configuration in
  • 2, according to url struts-config path path, get actionmapping 1.2processpath , 1.3processmapping
  • 3, according to actionmapping name name lookup actionform 1.4processactionform method)
  • 4, instantiation actionform map actionform assignment. Before assigning a value, first execute the reset method. ( 1.5processpopulate method) after assigning values, Then according to the third-party component beanutils Convert the string in the form to the type you want.
  • 5. Create an Action instance and place it in the Map . (1.6processActionCreate method)
  • 6. Let the Action Instance process the request and return a actionforward instance ( 1.7processActionPerform method).
  • actionforward 1.8processforwardconfig method)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.