pkg.h

来自「About: Paco (pacKAGE oRGANIZER) is a si」· C头文件 代码 · 共 104 行

H
104
字号
//=======================================================================// Pkg.h//-----------------------------------------------------------------------// This file is part of the package paco// Copyright (C) 2004-2007 David Rosal <david.3r@gmail.com>// For more information visit http://paco.sourceforge.net//=======================================================================#ifndef PACO_PKG_H#define PACO_PKG_H#include "paco/BasePkg.h"#include "PkgSet.h"namespace Paco {class Options;class Pkg : public BasePkg{	public:	Pkg(std::string const&);	virtual ~Pkg();	void unlog() const;	void printInfo() const;	bool update() const;	long countShared(PkgSet& all);	void printConfOpts(bool printPkgName) const;	void remove(Options&);	void upgradeLog() const;	static std::string getBase(std::string const&);	static std::string getVersion(std::string const&);	class Lister	{		public:			Lister(Options&, PkgSet&);		~Lister();				Pkg* operator()(Pkg*);		private:			Options&	mOpt;		PkgSet& 	mSet;		PkgSet 		mAllPkgs;		int 		mSizeInstWidth;		int 		mSizeMissWidth;		int 		mFilesInstWidth;		int 		mFilesMissWidth;		int 		mFilesSharedWidth;		void printFilesInst(long n) const;		void printFilesMiss(long n) const;		void printFilesShared(long n) const;		void printDate(int time) const;		int getSizeInstWidth();		int getSizeMissWidth();		int getFilesInstWidth();		int getFilesMissWidth();		template <typename T> void printSizeInst(T size) const;		template <typename T> void printSizeMiss(T size) const;	}; 	// class Pkg::Lister	class FileLister	{		public:		FileLister(Options&, PkgSet&);		~FileLister();		Pkg* operator()(Pkg*);		private:		Options& 		mOpt;		PkgSet& 		mSet;		int 			mSizeWidth;		bool			mPrintTotal;		float 			mTotalSize;		PkgSet	 		mAllPkgs;		unsigned 		mPkgCnt;		unsigned long 	mFileCnt;		void listFiles(Pkg*);		void printFile(File*);		void listSharedFiles(Pkg*);		void listNonSharedFiles(Pkg*);		int getSizeWidth();	}; 	// class Pkg::FileLister};		// class Pkg}		// namespace Paco#endif  // PACO_PKG_H

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?