FileDocCategorySizeDatePackage
MultipleFileUploadUsingListAction.javaAPI DocApache Struts 2.0.9 Apps2787Mon Jul 23 13:43:26 BST 2007org.apache.struts2.showcase.fileupload

MultipleFileUploadUsingListAction

public class MultipleFileUploadUsingListAction extends com.opensymphony.xwork2.ActionSupport
Showcase action - multiple file upload using List
version
$Date: 2006-11-23 12:31:52 -0500 (Thu, 23 Nov 2006) $ $Id: MultipleFileUploadUsingListAction.java 478625 2006-11-23 17:31:52Z wsmoak $

Fields Summary
private List
uploads
private List
uploadFileNames
private List
uploadContentTypes
Constructors Summary
Methods Summary
public java.util.ListgetUpload()



       
        return this.uploads;
    
public java.util.ListgetUploadContentType()

        return this.uploadContentTypes;
    
public java.util.ListgetUploadFileName()

        return this.uploadFileNames;
    
public voidsetUpload(java.util.List uploads)

        this.uploads = uploads;
    
public voidsetUploadContentType(java.util.List contentTypes)

        this.uploadContentTypes = contentTypes;
    
public voidsetUploadFileName(java.util.List uploadFileNames)

        this.uploadFileNames = uploadFileNames;
    
public java.lang.Stringupload()


        System.out.println("\n\n upload1");
        System.out.println("files:");
        for (File u: uploads) {
            System.out.println("*** "+u+"\t"+u.length());
        }
        System.out.println("filenames:");
        for (String n: uploadFileNames) {
            System.out.println("*** "+n);
        }
        System.out.println("content types:");
        for (String c: uploadContentTypes) {
            System.out.println("*** "+c);
        }
        System.out.println("\n\n");
        return SUCCESS;