CFileNamingComp.h
Go to the documentation of this file.
1 #ifndef ifileproc_CFileNamingComp_included
2 #define ifileproc_CFileNamingComp_included
3 
4 
5 // ACF includes
7 #include <ilog/TLoggerCompWrap.h>
8 #include <ifile/IFileNameParam.h>
9 
10 // ACF-Solutions includes
11 #include <ifileproc/IFileNaming.h>
13 
14 
15 namespace ifileproc
16 {
17 
18 
25  virtual public ifileproc::IFileNaming
26 {
27 public:
29 
30  I_BEGIN_COMPONENT(CFileNamingComp);
31  I_REGISTER_INTERFACE(ifileproc::IFileNaming);
32  I_ASSIGN(m_fileTypeInfoCompPtr, "OutputFileInfo", "Output file info, which will be used for file name calculation", false, "OutputFileInfo");
33  I_ASSIGN(m_directoryPathCompPtr, "DirectoryPath", "Default path of the output directory", false, "DirectoryPath");
34  I_ASSIGN(m_fileNamingParamsCompPtr, "FileNamingParams", "Rules for the file naming", false, "FileNamingParams");
35  I_END_COMPONENT;
36 
37  // reimplemented (ifileproc::IFileNaming)
38  virtual QString CalculateFileName(
39  const QString& inputFileName,
40  const QString& outputDirectoryPath,
41  const ifileproc::IFileNamingParams* fileNamingParamsPtr) const;
42 
43 private:
44  I_REF(ifile::IFileTypeInfo, m_fileTypeInfoCompPtr);
45  I_REF(ifile::IFileNameParam, m_directoryPathCompPtr);
46  I_REF(ifileproc::IFileNamingParams, m_fileNamingParamsCompPtr);
47 };
48 
49 
50 } // namespace ifileproc
51 
52 
53 #endif // !ifileproc_CFileNamingComp_included
54 
ilog::CLoggerComponentBase BaseClass
Interface for calculation of the new file path for an existing file.
Definition: IFileNaming.h:19
Component for calculating of the new file name.
Interface for calculation parameters of the new file name for any file item.
virtual QString CalculateFileName(const QString &inputFileName, const QString &outputDirectoryPath, const ifileproc::IFileNamingParams *fileNamingParamsPtr) const
Calculate the new file path for a given input file name.

© 2007-2017 Witold Gantzke and Kirill Lepskiy