• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeedu API Reference
  • KDE Home
  • Contact Us
 

marble

  • sources
  • kde-4.12
  • kdeedu
  • marble
  • src
  • lib
  • marble
FileStoragePolicy.h
Go to the documentation of this file.
1 //
2 // This file is part of the Marble Virtual Globe.
3 //
4 // This program is free software licensed under the GNU LGPL. You can
5 // find a copy of this license in LICENSE.txt in the top directory of
6 // the source code.
7 //
8 // Copyright 2007 Tobias Koenig <tokoe@kde.org>
9 //
10 
11 #ifndef MARBLE_FILESTORAGEPOLICY_H
12 #define MARBLE_FILESTORAGEPOLICY_H
13 
14 #include "StoragePolicy.h"
15 
16 namespace Marble
17 {
18 
19 class FileStoragePolicy : public StoragePolicy
20 {
21  Q_OBJECT
22 
23  public:
29  explicit FileStoragePolicy( const QString &dataDirectory = QString(), QObject *parent = 0 );
30 
34  ~FileStoragePolicy();
35 
39  bool fileExists( const QString &fileName ) const;
40 
44  bool updateFile( const QString &fileName, const QByteArray &data );
45 
49  void clearCache();
50 
54  QString lastErrorMessage() const;
55 
56  private:
57  Q_DISABLE_COPY( FileStoragePolicy )
58 
59  QString m_dataDirectory;
60  QString m_errorMsg;
61 };
62 
63 }
64 
65 #endif
Marble::FileStoragePolicy::fileExists
bool fileExists(const QString &fileName) const
Returns whether the fileName exists already.
Definition: FileStoragePolicy.cpp:43
Marble::StoragePolicy
Definition: StoragePolicy.h:25
QObject
Marble::FileStoragePolicy::lastErrorMessage
QString lastErrorMessage() const
Returns the last error message.
Definition: FileStoragePolicy.cpp:140
Marble::FileStoragePolicy
Definition: FileStoragePolicy.h:19
StoragePolicy.h
Marble::FileStoragePolicy::clearCache
void clearCache()
Clears the cache.
Definition: FileStoragePolicy.cpp:86
Marble::FileStoragePolicy::FileStoragePolicy
FileStoragePolicy(const QString &dataDirectory=QString(), QObject *parent=0)
Creates a new file storage policy.
Definition: FileStoragePolicy.cpp:28
Marble::FileStoragePolicy::updateFile
bool updateFile(const QString &fileName, const QByteArray &data)
Updates the fileName with the given data.
Definition: FileStoragePolicy.cpp:49
Marble::FileStoragePolicy::~FileStoragePolicy
~FileStoragePolicy()
Destroys the cache storage policy.
Definition: FileStoragePolicy.cpp:39
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:38:49 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

marble

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

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • kstars
  • libkdeedu
  •   keduvocdocument
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



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