]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - HLT/comp/AliHLTCompAgent.cxx
correcting memory leaks on error conditions
[u/mrichter/AliRoot.git] / HLT / comp / AliHLTCompAgent.cxx
index 2fc7a916beec3c172fbf889ada5a924c7fe39bc5..489fcd87c5ab26abc0abac2d6dd70938701f3881 100644 (file)
@@ -19,7 +19,7 @@
 /** @file   AliHLTCompAgent.cxx
     @author Matthias Richter
     @date   
-    @brief  Agent of the libHLTsim library
+    @brief  Agent of the libAliHLTComp library
 */
 
 // see header file for class documentation
 #include <cassert>
 #include <cerrno>
 #include "AliHLTCompAgent.h"
-#include "AliHLTConfiguration.h"
 
 // header files of library components
-// ....
+#include "AliHLTCOMPHuffmanAltroComponent.h"
+#include "AliHLTCOMPHuffmanAltroCalibComponent.h"
+
+// header file of the module preprocessor
+#include "AliHLTCompPreprocessor.h"
 
 /** global instance for agent registration */
 AliHLTCompAgent gAliHLTCompAgent;
@@ -43,6 +46,8 @@ AliHLTCompAgent gAliHLTCompAgent;
 ClassImp(AliHLTCompAgent)
 
 AliHLTCompAgent::AliHLTCompAgent()
+  :
+  AliHLTModuleAgent("Comp")
 {
   // see header file for class documentation
   // or
@@ -74,6 +79,9 @@ const char* AliHLTCompAgent::GetReconstructionChains(AliRawReader* /*rawReader*/
 const char* AliHLTCompAgent::GetRequiredComponentLibraries() const
 {
   // see header file for class documentation
+
+  // libAliHLTUtil.so for AliRawReaderPublisher
+  //return "libAliHLTUtil.so";
   return NULL;
 }
 
@@ -82,6 +90,17 @@ int AliHLTCompAgent::RegisterComponents(AliHLTComponentHandler* pHandler) const
   // see header file for class documentation
   assert(pHandler);
   if (!pHandler) return -EINVAL;
-  //pHandler->AddComponent(new ...);
+  // use fCompressionSwitch = true for decompressed inputtype (i.e. compressed output)
+  pHandler->AddComponent(new AliHLTCOMPHuffmanAltroComponent(true));
+  // use fCompressionSwitch = false for compressed inputtype (i.e. decompressed output)
+  pHandler->AddComponent(new AliHLTCOMPHuffmanAltroComponent(false));
+  pHandler->AddComponent(new AliHLTCOMPHuffmanAltroCalibComponent);
+
   return 0;
 }
+
+AliHLTModulePreprocessor* AliHLTCompAgent::GetPreprocessor()
+{
+  // see header file for class documentation
+  return new AliHLTCompPreprocessor;
+}