00001 #ifndef Impala_Core_ImageSet_ApplyConcepts_h 00002 #define Impala_Core_ImageSet_ApplyConcepts_h 00003 00004 #include "Core/ImageSet/Reporter.h" 00005 #include "Core/ImageSet/PathCreatorImageSet.h" 00006 #include "Core/Training/ApplyConcepts.h" 00007 00008 namespace Impala 00009 { 00010 namespace Core 00011 { 00012 namespace ImageSet 00013 { 00014 00015 class ApplyConcepts : public Listener 00016 { 00017 public: 00018 ApplyConcepts(Reporter* reporter, CmdOptions& options, ImageSet* is) 00019 { 00020 mReporter = reporter; 00021 mPathCreator = new PathCreatorImageSet(is); 00022 mApplier = new Training::ApplyConcepts(options, mPathCreator); 00023 } 00024 00025 virtual 00026 ~ApplyConcepts() 00027 { 00028 delete mApplier; 00029 delete mPathCreator; 00030 } 00031 00032 virtual void 00033 HandleNewWalk(ImageSet* is, String walkType) 00034 { 00035 mPathCreator->SetWalkType(walkType); 00036 } 00037 00038 virtual void 00039 HandleDoneDir(ImageSet* is, int dirId) 00040 { 00041 mPathCreator->SetFolderId(dirId); 00042 mApplier->NextPath(mPathCreator); 00043 } 00044 00045 private: 00046 00047 Reporter* mReporter; 00048 Training::ApplyConcepts* mApplier; 00049 PathCreatorImageSet* mPathCreator; 00050 00051 ILOG_VAR_DEC; 00052 }; 00053 00054 ILOG_VAR_INIT(ApplyConcepts, Impala.Core.ImageSet); 00055 00056 } // namespace ImageSet 00057 } // namespace Core 00058 } // namespace Impala 00059 00060 #endif