请教怎么传法?
public ArrayList Test() throws SQLException {
        ArrayList a1 = new ArrayList();
        this.connect();
        ResultSet rs = getdata("select * from");
        while (rs.next()) {
            testbean type = new testbean();
            type.setTest_a(rs.getString("test_a"));
            type.setTest_B(rs.getString("test_b"));
            a1.add(type);           //则处要调用发mail的程序(主要参加是mail的正文)
           .......
            
        }
        this.diconnect();
        return a1;