apt
1.5
|
00001 // -*- mode: cpp; mode: fold -*- 00002 // Description /*{{{*/ 00010 /*}}}*/ 00011 #ifndef APT_CONFIGURATION_H 00012 #define APT_CONFIGURATION_H 00013 // Include Files /*{{{*/ 00014 #include <string> 00015 #include <vector> 00016 #include <limits> 00017 /*}}}*/ 00018 namespace APT { 00019 class Configuration { /*{{{*/ 00020 public: /*{{{*/ 00042 std::vector<std::string> static const getCompressionTypes(bool const &Cached = true); 00043 00067 std::vector<std::string> static const getLanguages(bool const &All = false, 00068 bool const &Cached = true, char const ** const Locale = 0); 00069 00077 std::vector<std::string> static const getArchitectures(bool const &Cached = true); 00078 00084 bool static const checkArchitecture(std::string const &Arch); 00085 00087 struct Compressor { 00088 std::string Name; 00089 std::string Extension; 00090 std::string Binary; 00091 std::vector<std::string> CompressArgs; 00092 std::vector<std::string> UncompressArgs; 00093 unsigned short Cost; 00094 00095 Compressor(char const *name, char const *extension, char const *binary, 00096 char const *compressArg, char const *uncompressArg, 00097 unsigned short const cost); 00098 Compressor() : Cost(std::numeric_limits<unsigned short>::max()) {}; 00099 }; 00100 00108 std::vector<Compressor> static const getCompressors(bool const Cached = true); 00109 00111 std::vector<std::string> static const getCompressorExtensions(); 00112 /*}}}*/ 00113 private: /*{{{*/ 00114 void static setDefaultConfigurationForCompressors(); 00115 /*}}}*/ 00116 }; 00117 /*}}}*/ 00118 } 00119 #endif