Proxy Class Reference

Collaboration diagram for Proxy:
[legend]

List of all members.

Public Member Functions

void setProxyList ()
void closeProxy ()
void updateStatus ()

Public Attributes

ResultSet rs = null
ResultSet crs = null
String updateIds = ""


Member Function Documentation

void Proxy::closeProxy (  )  [inline]

00023                                 {
00024 
00025                 if (rs != null) {
00026                         try {
00027                                 rs.close();
00028                         } catch (Exception e) { }
00029                         rs = null;
00030                 }
00031 //              if (this.stmt != null) {
00032 //                      try {
00033 //                              this.stmt.close();
00034 //                      } catch (SQLException sqlEx) { }
00035 //                      this.stmt = null;
00036 //              }
00037                 //System.out.println("Proxy closed!");
00038         }

void Proxy::setProxyList (  )  [inline]

00011                                    {
00012 
00013                 try {
00014                         rs = db.getResult("SELECT SQL_CALC_FOUND_ROWS ProxyID, Url, Port FROM Proxies WHERE Used = 0");
00015                         crs = db.getResult("SELECT FOUND_ROWS()");
00016                         crs.next();
00017                         //System.out.println("Num rows = " + crs.getString(1));
00018                 } catch (Exception e) {
00019                         System.out.println("Proxy list failed with " + e);
00020                 }
00021         }

Here is the call graph for this function:

void Proxy::updateStatus (  )  [inline]

00040                                   {
00041 
00042                 if (updateIds != ""){
00043                         try {
00044                                 //System.out.println("Updating " + updateIds);
00045                                 db.execute("UPDATE Proxies SET Used = 1 WHERE ProxyID IN (" + updateIds  + ")");
00046                         } catch (Exception e) {
00047                                 System.out.println(e);
00048                         }
00049                 } else {
00050                         System.out.println("Nothing to update");
00051                 }
00052         }

Here is the call graph for this function:


Member Data Documentation

ResultSet Proxy::crs = null

ResultSet Proxy::rs = null

String Proxy::updateIds = ""


The documentation for this class was generated from the following file:

Generated on Thu Oct 22 17:40:09 2009 for JAVAProxyClick by  doxygen 1.5.8