KDevelop API Documentation

vcs/cvsservice/cvsoptions.h

Go to the documentation of this file.
00001 /*************************************************************************** 00002 * Copyright (C) 2003 by Mario Scalas * 00003 * mario.scalas@libero.it * 00004 * * 00005 * This program is free software; you can redistribute it and/or modify * 00006 * it under the terms of the GNU General Public License as published by * 00007 * the Free Software Foundation; either version 2 of the License, or * 00008 * (at your option) any later version. * 00009 * * 00010 ***************************************************************************/ 00011 00012 #ifndef CVSOPTIONS_H 00013 #define CVSOPTIONS_H 00014 00015 #include <qstring.h> 00016 #include <qdom.h> 00017 00018 class CvsServicePart; 00019 class KConfig; 00020 class KDevProject; 00021 00022 /* This class represents the command line options for the used cvs commands. 00023 * It uses the singleton pattern. 00024 * @author Mario Scalas <mario.scalas@libero.it> 00025 */ 00026 class CvsOptions 00027 { 00028 public: 00029 static CvsOptions *instance(); 00030 00031 static QString invalidLocation; 00032 00033 virtual ~CvsOptions(); 00034 00035 void save( KDevProject *project ); 00037 void load( KDevProject *project ); 00038 00039 void setRecursiveWhenCommitRemove( bool b ); 00040 bool recursiveWhenCommitRemove() const; 00041 00042 void setPruneEmptyDirsWhenUpdate( bool b ); 00043 bool pruneEmptyDirsWhenUpdate() const; 00044 00045 void setRecursiveWhenUpdate( bool b ); 00046 bool recursiveWhenUpdate() const; 00047 00048 void setCreateDirsWhenUpdate( bool b ); 00049 bool createDirsWhenUpdate() const; 00050 00051 void setDiffOptions( const QString &p ); 00052 QString diffOptions(); 00053 00054 void setRevertOptions( const QString &p ); 00055 QString revertOptions(); 00056 00057 void setCvsRshEnvVar( const QString &p ); 00058 QString cvsRshEnvVar(); 00059 00063 QString guessLocation( const QString &projectDir ) const; 00064 00070 void setLocation( const QString &p ); 00074 QString location(); 00075 00076 void setContextLines( unsigned int contextLines ); 00077 unsigned int contextLines() const; 00078 00079 void setCompressionLevel( unsigned int compressionLevel = 0 ); 00080 unsigned int compressionLevel() const; 00081 00082 private: 00083 // Cache 00084 bool m_recursiveWhenCommitRemove; 00085 bool m_pruneEmptyDirsWhenUpdate; 00086 bool m_recursiveWhenUpdate; 00087 bool m_createDirsWhenUpdate; 00088 QString m_revertOptions; 00089 QString m_diffOptions; 00090 QString m_cvsRshEnvVar; 00091 QString m_location; 00092 unsigned int m_compressionLevel; 00093 unsigned int m_contextLines; 00095 KConfig *m_serviceConfig; 00096 00097 static CvsOptions *m_instance; 00098 CvsOptions(); 00099 }; 00100 00101 #endif // CVSOPTIONS_H 00102
KDE Logo
This file is part of the documentation for KDevelop Version 3.0.4.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Wed Oct 6 17:39:14 2004 by doxygen 1.3.7 written by Dimitri van Heesch, © 1997-2003