Merge pull request #2216 from jwillemsen/jwi-cxxversionchecks
[ACE_TAO.git] / TAO / tao / Compression / zlib / ZlibCompressor_Factory.h
blob2ae221ecba2c107b0dab79ecd4b674e9c945b3a8
1 // -*- C++ -*-
3 // ===================================================================
4 /**
5 * @file ZlibCompressor_Factory.h
7 * @author Johnny Willemsen <jwillemsen@remedy.nl>
8 */
9 // ===================================================================
11 #ifndef TAO_ZLIBCOMPRESSOR_FACTORY_H
12 #define TAO_ZLIBCOMPRESSOR_FACTORY_H
14 #include /**/ "ace/pre.h"
16 #include "tao/Compression/zlib/ZlibCompressor_export.h"
18 #if !defined (ACE_LACKS_PRAGMA_ONCE)
19 # pragma once
20 #endif /* ACE_LACKS_PRAGMA_ONCE */
22 #include "tao/Compression/Compression.h"
23 #include "tao/Compression/Compressor_Factory.h"
24 #include <map>
26 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
28 namespace TAO
30 class TAO_ZLIBCOMPRESSOR_Export Zlib_CompressorFactory :
31 public ::TAO::CompressorFactory
33 typedef std::map< ::Compression::CompressionLevel,
34 const ::Compression::Compressor_var> ZlibCompressorMap;
36 public:
37 Zlib_CompressorFactory ();
39 virtual ::Compression::Compressor_ptr get_compressor (
40 ::Compression::CompressionLevel compression_level);
42 private:
43 Zlib_CompressorFactory (const Zlib_CompressorFactory &) = delete;
44 Zlib_CompressorFactory &operator= (const Zlib_CompressorFactory &) = delete;
46 // Ensure we can lock with imutability (i.e. const)
47 mutable TAO_SYNCH_MUTEX mutex_;
48 ZlibCompressorMap compressors_;
52 TAO_END_VERSIONED_NAMESPACE_DECL
54 #include /**/ "ace/post.h"
56 #endif /* TAO_ZLIBCOMPRESSOR_FACTORY_H */