libzypp  10.5.0
ProxyInfo.h
Go to the documentation of this file.
00001 /*---------------------------------------------------------------------\
00002 |                          ____ _   __ __ ___                          |
00003 |                         |__  / \ / / . \ . \                         |
00004 |                           / / \ V /|  _/  _/                         |
00005 |                          / /__ | | | | | |                           |
00006 |                         /_____||_| |_| |_|                           |
00007 |                                                                      |
00008 \---------------------------------------------------------------------*/
00012 #ifndef ZYPP_MEDIA_PROXYINFO_H
00013 #define ZYPP_MEDIA_PROXYINFO_H
00014 
00015 #include <string>
00016 #include <list>
00017 
00018 #include "zypp/base/PtrTypes.h"
00019 
00020 namespace zypp {
00021 
00022   class Url;
00023 
00024   namespace media {
00025 
00027     //
00028     //  CLASS NAME : ProxyInfo
00029     class ProxyInfo
00030     {
00031     public:
00032       typedef intrusive_ptr<ProxyInfo> Ptr;
00033       typedef intrusive_ptr<ProxyInfo> constPtr;
00034       typedef std::list<std::string> NoProxyList;
00035       typedef std::list<std::string>::const_iterator NoProxyIterator;
00036 
00038       struct Impl;
00039       typedef shared_ptr<Impl> ImplPtr;
00040 
00042       ProxyInfo();
00044       ProxyInfo( ProxyInfo::ImplPtr pimpl_r );
00045 
00046       bool enabled() const;
00047       std::string proxy(const Url & url) const;
00048       NoProxyList noProxy() const;
00049       NoProxyIterator noProxyBegin() const;
00050       NoProxyIterator noProxyEnd() const;
00051 
00053       bool useProxyFor( const Url & url_r ) const;
00054 
00055     private:
00057       RW_pointer<Impl> _pimpl;
00058     };
00059 
00060 
00062 
00063   } // namespace media
00064 } // namespace zypp
00065 
00066 #endif // ZYPP_MEDIA_PROXYINFO_H