Octane v1.01.20 - The Open Compression Toolkit for C++ | http://octane.sourceforge.net/ |
00001 00002 00003 00004 00005 00006 00007 00008 00009 //--------------------------------------------------------------------------- 00010 00018 00019 //--------------------------------------------------------------------------- 00020 // forward declarations 00021 class OctaneModeler; 00022 //--------------------------------------------------------------------------- 00023 00024 //--------------------------------------------------------------------------- 00025 // recursive header protection 00026 #ifndef ModelerH 00027 #define ModelerH 00028 //--------------------------------------------------------------------------- 00029 00030 //--------------------------------------------------------------------------- 00031 // application includes 00032 #include "symbolweightvector.hpp" 00033 #include "../core/octaneclass.hpp" 00034 #include "../parsers/parser.hpp" 00035 #include "../coders/coder.hpp" 00036 #include "../bitio/bitio.hpp" 00037 // system includes 00038 //--------------------------------------------------------------------------- 00039 00040 00041 00042 00043 //--------------------------------------------------------------------------- 00051 class OctaneModeler : public OctaneClass 00052 { 00053 public: 00055 OctaneModeler() {;} 00057 virtual ~OctaneModeler() {;} 00058 public: 00059 //--------------------------------------------------------------------------- 00060 // OCTANE PUBLIC API - RTTI FUNCTIONS - these are supported by all derived classes 00061 virtual std::string GetName() {return "OctaneModeler";} 00062 virtual std::string GetDescription() {return "Base Modeler";} 00063 virtual std::string GetHelpInformation() {return "";} 00064 //--------------------------------------------------------------------------- 00065 public: 00066 //--------------------------------------------------------------------------- 00067 // MODELLER PUBLIC API - STATE MAINTENANCE 00068 virtual void ResetState() {;}; 00071 virtual bool IsReadyToModel() {return true;}; 00072 virtual void SynchronizeStateForNewStream() {;}; 00075 virtual bool CreateModelUsingStream(OctaneParser *parserp, bitreader &from) {return true;}; 00080 virtual bool CreateModelUsingParser(OctaneParser *parserp) {return false;}; 00083 virtual bool PrepareForModeling(OctaneParser *parserp) {return true;}; 00090 virtual bool UpdateModelAfterReceivingSymbol(int symbolnumber, OctaneCoder *coderp) {return true;}; 00091 //--------------------------------------------------------------------------- 00092 public: 00093 //--------------------------------------------------------------------------- 00094 // MODELLER PUBLIC API - ACCESSOR FOR CODING 00096 virtual int GetSymbolCount() {return 0;}; 00103 virtual SymbolWeightVector* GetWeightVectorp() {return NULL;}; 00105 virtual TSymbolWeightVectorWeight GetWeightVectorItem(int symbolnum) {return 0;}; 00106 //--------------------------------------------------------------------------- 00107 }; 00108 //--------------------------------------------------------------------------- 00109 00110 00111 00112 //--------------------------------------------------------------------------- 00113 #endif 00114 //--------------------------------------------------------------------------- 00115