/*! @file Compile for Linux: @code g++ test.cxx -I. -lproxy -ldl @endcode On Linux: install http://code.google.com/p/libproxy/ @code ./configure --without-gnome --without-kde \ --without-webkit --without-mozjs \ --without-networkmanager --without-python make && sudo make install @endcode Cross-Compile for Windoze: @code i586-mingw32msvc-g++ test.cxx \ -I . -I ~/.wine/drive_c/MicrosoftSDK/include \ winhttp.a @endcode @id $Id$ */ // 1 2 3 4 5 6 7 8 // 45678901234567890123456789012345678901234567890123456789012345678901234567890 #include #include int main(int argc, char** argv) try { proxy::Face detect; while (++argv, --argc) { std::cout<<"detecting proxies for url: "<<*argv< found " <<(p.begin()->type==proxy::DIRECT?"DIRECT" :(p.begin()->type==proxy::DEFAULT?"DEFAULT" :(p.begin()->type==proxy::HTTP?"HTTP" :(p.begin()->type==proxy::SOCKS?"SOCKS":"**ERROR**")))) <<" proxy host: "<host <<" (Port: "<port<<")"<