关于jsp当中smartupload组件的应用

项目是一个管理信息系统,要实现文档的上传下载,打算把上传的文档放在WEB-ROOT下的documents文件夹里,下载也是从这里下载。
把smartupload的jar架包导入到项目里,(import jspsmart.upload.(忘了具体是哪个了,反引用是对的))写servlet的时候,引用方法总是报错,比如初始化的方法,设置文件大小的方法等等。
什么原因啊?求助

把具体代码贴出来,以及把具体出错信息贴出来,否则很难判断啊。

参考
http://www.cnblogs.com/shenliang123/archive/2012/04/20/2459075.html
http://blog.sina.com.cn/s/blog_4cc16fc50100bwby.html

http://www.iteye.com/problems/16430

package GPMS.reply.servlet;

import java.io.File;
import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.jspsmart.upload.*;
public class SmartUpload extends HttpServlet {

public SmartUpload() {
    super();
}


public void destroy() {
    super.destroy(); // Just puts "destroy" string in log
    // Put your code here
}


public void doGet(HttpServletRequest request, HttpServletResponse response)
        throws ServletException, IOException {
    doPost(request,response);

}


public void doPost(HttpServletRequest request, HttpServletResponse response)
        throws ServletException, IOException {
    //设置文件保存路径
    String filePath=getServletContext().getRealPath("/")+"documents";
    File file=new File(filePath);
    if(!file.exists()){
        file.mkdir();
    }
    SmartUpload su=new SmartUpload();

    su.initialize(getServletConfig(),request,response);//从这里开始引用的initialize,setMaxFileSize等都报错了
    su.setMaxFileSize(1024*1024*20);
    su.setTotalMaxFileSize(1024*1024*200);
    su.setAllowedFilesList("txt,jpg,gif,doc");
    String result="上传成功";

        su.setDeniedFilesList("rar,jar,js");
        //上传文件
        su.upload();
        try{

        int count=su.save(filePath);
        System.out.println("上传成功"+count+"个文件!");
    }catch(Exception e){
        result="上传失败!";
        e.printStackTrace();
    }
    request.setAttribute("result", result);
    request.getRequestDispatcher("/GPMS/reply/upload.jsp").forward(request, response);
}

/**
 * Initialization of the servlet. <br>
 *
 * @throws ServletException if an error occurs
 */
public void init() throws ServletException {
    // Put your code here
}

}