일반 ActionForm 생성

황제낙엽 2006.01.16 18:14 조회 수 : 180 추천:79

1. struts-config.xml파일내에
- <form-beans>태그내에 다음과 같이 폼의 정보를 삽입
    <form-bean
      name="communityMessageForm"
      type="action.community.CommunityMessageForm"
    />

- 다음과 같이 액션폼을 정의
    <action
      path="/community_message_form"
      type="action.community.CommunityMessageFormAction"
      name="communityMessageForm"
      scope="request"
      unknown="false"
      validate="true"
    >
      <forward
        name="next"
        path="/view/community/message_form.vm"
        redirect="false"
      />
    </action>


2. CommunityMessageFormAction 클래스에서
- 다음과 같은 친절한 주석도 잊지말자
/**
* @struts.action path="/community_message_form" name="communityMessageForm" scope="request"
* @struts.action-forward name="next" path="/view/community/message_form.vm"
*/
public class CommunityMessageFormAction extends Action


3. CommunityMessageForm 클래스에서
- 다음과 같은 친절한 주석도 잊지말자
/**
* @author Lee
* @struts.form name="communityMessageForm"
*/
public class CommunityMessageForm extends ActionForm
번호 제목 글쓴이 날짜 조회 수
31 샘플예제 file 황제낙엽 2009.03.02 445
30 A Walking Tour of the Struts 2 MailReader Application (2) 황제낙엽 2008.12.10 314
29 A Walking Tour of the Struts 2 MailReader Application (1) 황제낙엽 2008.12.10 458
28 스트러츠2 샘플 어플리케이션 (MailReader Demonstration Application) file 황제낙엽 2008.11.20 904
27 스트러츠2 실습 예제 모음 (Struts Showcase) 황제낙엽 2008.11.20 58252
26 Struts와 Struts2의 로그인 매커니즘 비교 황제낙엽 2008.10.23 319
25 Struts2 시작하기 황제낙엽 2008.09.22 54365
24 Struts2(스트럿츠2) Feature(특징) 황제낙엽 2008.07.12 351
23 책 Starting Struts 2 - Free Online Version (InfoQ.com) file 황제낙엽 2008.07.11 730
22 스트러츠2 활용 Upload 예제 file 황제낙엽 2007.08.14 344
21 Struts 프레임워크를 이용한 효율적인 개발 전략 황제낙엽 2007.01.30 324
20 MyEclipse를 사용한 Struts 빠른 시작 황제낙엽 2007.01.26 585
19 EJB+JSP를 활용한 J2EE기반의 샘플 프로젝트 (JPetStore-5.0) 황제낙엽 2007.01.18 397
18 EJB+JSP를 활용한 J2EE기반의 샘플 프로젝트 (JPetStore-4.0.5) file 황제낙엽 2005.10.28 491
17 Struts GUI XML 작성 Tool 들 황제낙엽 2006.02.24 486
16 스트러츠로 작성된 웹서점 샘플화일 (Struts+Hsql) 황제낙엽 2005.11.24 305
15 Validation과 Dispatcher액션 황제낙엽 2006.05.22 550
14 폼빈의 Reset 황제낙엽 2006.05.22 371
13 Struts-Config.xml 과 액션과 JSP의 관계 황제낙엽 2006.05.22 327
12 struts-config 설명 및 작성방법 황제낙엽 2006.02.27 331