• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdepimlibs-4.10.5 API Reference
  • KDE Home
  • Contact Us
 

kabc

  • kabc
ldif_p.h
1 /*
2  A temporary copy to break dependency to KLDAP
3 
4  This file is part of libkldap.
5  Copyright (c) 2004-2006 Szombathelyi György <gyurco@freemail.hu>
6 
7  This library is free software; you can redistribute it and/or
8  modify it under the terms of the GNU Library General Public
9  License as published by the Free Software Foundation; either
10  version 2 of the License, or (at your option) any later version.
11 
12  This library is distributed in the hope that it will be useful,
13  but WITHOUT ANY WARRANTY; without even the implied warranty of
14  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15  Library General Public License for more details.
16 
17  You should have received a copy of the GNU Library General Public License
18  along with this library; see the file COPYING.LIB. If not, write to
19  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20  Boston, MA 02110-1301, USA.
21 */
22 
23 #ifndef LDIF_P_H
24 #define LDIF_P_H
25 
26 #include <QtCore/QString>
27 #include <QtCore/QByteArray>
28 
29 #include "ldapdn_p.h"
30 
38 class Ldif
39 {
40  public:
41 
42  typedef enum {
43  None, NewEntry, EndEntry, Item, Control, Err, MoreData
44  } ParseValue;
45 
46  typedef enum {
47  Entry_None, Entry_Add, Entry_Del, Entry_Mod, Entry_Modrdn
48  } EntryType;
49 
50  typedef enum {
51  Mod_None, Mod_Add, Mod_Replace, Mod_Del
52  } ModType;
53 
54  Ldif();
55 
56  Ldif( const Ldif &that );
57  Ldif &operator=( const Ldif &that );
58 
59  virtual ~Ldif();
60 
69  static QByteArray assembleLine( const QString &fieldname,
70  const QByteArray &value, uint linelen=0,
71  bool url=false );
76  static QByteArray assembleLine( const QString &fieldname,
77  const QString &value, uint linelen=0,
78  bool url=false );
79 
84  static bool splitLine( const QByteArray &line, QString &fieldname,
85  QByteArray &value );
86 
94  static bool splitControl( const QByteArray &line, QString &oid,
95  bool &critical, QByteArray &value );
96 
100  void startParsing();
101 
105  ParseValue processLine();
106 
117  ParseValue nextItem();
118 
123  void setLdif( const QByteArray &ldif );
124 
129  void endLdif();
130 
134  EntryType entryType() const;
135 
139  int modType() const;
140 
144  LdapDN dn() const;
145 
150  QString newRdn() const;
151 
155  QString newSuperior() const;
156 
160  bool delOldRdn() const;
161 
165  QString attr() const;
166 
170  QByteArray value() const;
171 
175  bool isUrl() const;
176 
180  bool isCritical() const;
181 
185  QString oid() const;
186 
190  uint lineNumber() const;
191 
192  private:
193  class LdifPrivate;
194  LdifPrivate *const d;
195 };
196 
197 #endif
This file is part of the KDE documentation.
Documentation copyright © 1996-2013 The KDE developers.
Generated on Sat Jul 13 2013 01:29:41 by doxygen 1.8.3.1 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kabc

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

kdepimlibs-4.10.5 API Reference

Skip menu "kdepimlibs-4.10.5 API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kioslave
  •   imap4
  •   mbox
  •   nntp
  • kldap
  • kmbox
  • kmime
  • kontactinterface
  • kpimidentities
  • kpimtextedit
  • kpimutils
  • kresources
  • ktnef
  • kxmlrpcclient
  • mailtransport
  • microblog
  • qgpgme
  • syndication
  •   atom
  •   rdf
  •   rss2
Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal