ML Reference
|
00001 // **InsertLicense** code 00002 //------------------------------------------------------------------------- 00007 00012 //------------------------------------------------------------------------- 00013 #ifndef __mlImagePropertyExtensionContainer_H 00014 #define __mlImagePropertyExtensionContainer_H 00015 00016 #ifndef __mlImagePropertyExtension_H 00017 #include "mlImagePropertyExtension.h" 00018 #endif 00019 00020 ML_UTILS_START_NAMESPACE 00021 00023 class RuntimeType; 00025 00026 //------------------------------------------------------------------------- 00032 //------------------------------------------------------------------------- 00033 class ML_UTILS_EXPORT ImagePropertyExtensionContainer { 00034 public: 00035 00036 //------------------------------------------------------------------- 00038 00039 //------------------------------------------------------------------- 00041 ImagePropertyExtensionContainer(); 00042 00044 virtual ~ImagePropertyExtensionContainer(); 00045 00047 ImagePropertyExtensionContainer(const ImagePropertyExtensionContainer& imagePropertyExtensionContainer); 00048 00050 ImagePropertyExtensionContainer &operator=(const ImagePropertyExtensionContainer& imagePropertyExtensionContainer); 00051 00055 bool operator==(const ImagePropertyExtensionContainer& imagePropertyExtensionContainer) const; 00056 00061 bool operator!=(const ImagePropertyExtensionContainer& imagePropertyExtensionContainer) const; 00062 00064 00065 00066 00067 //------------------------------------------------------------------- 00069 00070 //------------------------------------------------------------------- 00071 00073 size_t getNumEntries() const; 00074 00078 ImagePropertyExtension* getEntry(size_t position); 00079 00083 const ImagePropertyExtension* getEntry(size_t position) const; 00084 00086 00087 00088 //------------------------------------------------------------------- 00090 00091 //------------------------------------------------------------------- 00094 int findEntry(const ImagePropertyExtension* entry) const; 00095 00098 int findFirstEntryOfType(const RuntimeType* runtimeType) const; 00099 00103 ImagePropertyExtension* getFirstEntryOfType(const RuntimeType* runtimeType); 00104 00108 const ImagePropertyExtension* getFirstEntryOfType(const RuntimeType* runtimeType) const; 00109 00113 ImagePropertyExtensionVector getEntriesOfType(const RuntimeType* runtimeType); 00114 00117 ImagePropertyExtensionVector cloneEntriesOfType(const RuntimeType* runtimeType) const; 00118 00120 size_t getNumEntriesOfType(const RuntimeType* runtimeType) const; 00121 00123 00124 00125 //------------------------------------------------------------------- 00127 00128 //------------------------------------------------------------------- 00129 00131 void clear(); 00132 00137 bool removeEntry(size_t position); 00138 00142 bool removeEntry(const ImagePropertyExtension* propertyExtension); 00143 00145 void removeEntriesOfType(const RuntimeType* runtimeType); 00146 00148 00149 00150 //------------------------------------------------------------------- 00152 00153 //------------------------------------------------------------------- 00154 00157 void append(ImagePropertyExtension* propertyExtension); 00158 00162 ImagePropertyExtension* appendClone(const ImagePropertyExtension& propertyExtension); 00163 00165 00166 00167 protected: 00168 00170 void appendClones(const ImagePropertyExtensionContainer& container); 00171 00172 00173 private: 00174 00176 ImagePropertyExtensionVector _propExtensions; 00177 00178 00180 ML_CLASS_HEADER(ImagePropertyExtensionContainer); 00181 }; 00182 00183 ML_UTILS_END_NAMESPACE 00184 00185 00186 //----------------------------------------------------------------------------------- 00187 // Stream output for std::ostream 00188 //----------------------------------------------------------------------------------- 00189 namespace std { 00190 00192 ML_UTILS_EXPORT ostream& operator<<(ostream& s, const ML_NAMESPACE::ImagePropertyExtensionContainer &ipContainer); 00193 00194 } 00195 00196 #endif //of __mlImagePropertyExtensionContainer_H 00197 00198 00199