• Skip to content
  • Skip to link menu
KDE 3.5 API Reference
  • KDE API Reference
  • API Reference
  • Sitemap
  • Contact Us
 

kio

authinfo.h

Go to the documentation of this file.
00001 /*
00002  *  This file is part of the KDE libraries
00003  *  Copyright (C) 2000-2001 Dawit Alemayehu <adawit@kde.org>
00004  *
00005  *  This library is free software; you can redistribute it and/or
00006  *  modify it under the terms of the GNU Library General Public
00007  *  License as published by the Free Software Foundation; either
00008  *  version 2 of the License, or (at your option) any later version.
00009  *
00010  *  This library is distributed in the hope that it will be useful,
00011  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00013  *  Library General Public License for more details.
00014  *
00015  *  You should have received a copy of the GNU Library General Public License
00016  *  along with this library; see the file COPYING.LIB.  If not, write to
00017  *  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00018  *  Boston, MA 02110-1301, USA.
00019  */
00020 
00021 #ifndef __KIO_AUTHINFO_H
00022 #define __KIO_AUTHINFO_H
00023 
00024 #include <qmap.h>
00025 #include <qvaluelist.h>
00026 #include <kurl.h>
00027 
00028 
00029 namespace KIO {
00030 
00051 class KIO_EXPORT AuthInfo
00052 {
00053     KIO_EXPORT friend QDataStream& operator<< (QDataStream& s, const AuthInfo& a);
00054     KIO_EXPORT friend QDataStream& operator>> (QDataStream& s, AuthInfo& a);
00055 
00056 public:
00060    AuthInfo();
00061 
00065    AuthInfo( const AuthInfo& info );
00066 
00070    AuthInfo& operator=( const AuthInfo& info );
00071 
00076    bool isModified() const { return modified; }
00077 
00082    void setModified( bool flag ) { modified = flag; }
00083 
00094    KURL url;
00095 
00099    QString username;
00100 
00104    QString password;
00105 
00115    QString prompt;
00116 
00126    QString caption;
00127 
00150    QString comment;
00151 
00159    QString commentLabel;
00160 
00177    QString realmValue;
00178 
00187    QString digestInfo;
00188 
00200    bool verifyPath;
00201 
00207    bool readOnly;
00208 
00220     bool keepPassword;
00221 
00222 protected:
00223     bool modified;
00224 private:
00225     class AuthInfoPrivate* d;
00226 };
00227 
00228 KIO_EXPORT QDataStream& operator<< (QDataStream& s, const AuthInfo& a);
00229 KIO_EXPORT QDataStream& operator>> (QDataStream& s, AuthInfo& a);
00230 
00240 class KIO_EXPORT NetRC
00241 {
00242 public:
00243 
00254   enum LookUpMode
00255   {
00256       exactOnly = 0x0002,
00257       defaultOnly = 0x0004,
00258       presetOnly = 0x0008
00259   };
00260 
00265   struct AutoLogin
00266   {
00267     QString type;
00268     QString machine;
00269     QString login;
00270     QString password;
00271     QMap<QString, QStringList> macdef;
00272   };
00273 
00278   static NetRC* self();
00279 
00290   bool lookup( const KURL& url, AutoLogin& login,
00291                bool userealnetrc = false,
00292                QString type = QString::null,
00293                int mode = (exactOnly|defaultOnly) );
00297   void reload() { isDirty = true; }
00298 
00299 protected:
00300   QString extract( const char*, const char*, int& );
00301   int openf( const QString& );
00302   bool parse( int );
00303 
00304 private:
00305   NetRC();
00306   ~NetRC();
00307 
00308 private:
00309   bool isDirty;
00310 
00311   typedef QValueList<AutoLogin> LoginList;
00312   typedef QMap<QString, LoginList> LoginMap;
00313   LoginMap loginMap;
00314 
00315   static NetRC* instance;
00316   class NetRCPrivate;
00317   NetRCPrivate* d;
00318 };
00319 }
00320 #endif

kio

Skip menu "kio"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

API Reference

Skip menu "API Reference"
  • dcop
  • DNSSD
  • interfaces
  • Kate
  • kconf_update
  • KDECore
  • KDED
  • kdefx
  • KDEsu
  • kdeui
  • KDocTools
  • KHTML
  • KImgIO
  • KInit
  • kio
  • kioslave
  • KJS
  • KNewStuff
  • KParts
  • KUtils
Generated for API Reference by doxygen 1.5.9
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal