Struts build File Upload (ii)

Source: Internet
Author: User

This is the second class Actionform,

Package Tester.business.maitain
Import org.apache.struts.action.*;
Import javax.servlet.http.*;
Import org.apache.struts.upload.*;
public class Maintainform
extends Actionform {
/** private String p_title;
private int post_index;
PR Ivate String Issue_time;
Private String issue;
Private String p_content;
Private String p_accessory;
Private int p_id;
Private Java.util.ArrayList post_indexopts;
*/
Private Trainplan Trainplan = new Trainplan ();
private org.apache.struts.upload.FormFile theFile1;
PR Ivate Org.apache.struts.upload.FormFile TheFile2;
Private Org.apache.struts.upload.FormFile TheFile3;
Public String Getp_title () {
return trainplan.getp_title ();
}
public void Setp_title (String p_title) {
Trainplan.setp_title (p_title);
}
public void Settrainplan (Trainplan trainp) {
This.trainplan = TRAINP;
}
Public Trainplan Gettrainplan () {
return this.trainplan;
}
public void SetTheFile1 (Org.apache.struts.upload.FormFile theFile1) {
This.thefile1 = theFile1;
}
Public Org.apache.struts.upload.FormFile GetTheFile2 () {
return theFile2;
}
public void SetTheFile2 (Org.apache.struts.upload.FormFile theFile2) {
This.thefile2 = theFile2;
}
Public Org.apache.struts.upload.FormFile GetTheFile3 () {
return theFile3;
}
public void SetTheFile3 (Org.apache.struts.upload.FormFile theFile3) {
This.thefile3 = theFile3;
}
Public Org.apache.struts.upload.FormFile GetTheFile1 () {
return theFile1;
}
Public actionerrors Validate (actionmapping actionmapping,
HttpServletRequest httpservletrequest) {
/**@ Todo:finish this method, which just the skeleton.*/
return null;
}
public void Reset (actionmapping actionmapping,
HttpServletRequest httpservletrequest) {
}
}

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.