blob: 471d36cde1944e567ceb3fad11a57a9c4783a31f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
#include "TestCompressor_Factory.h"
#include "TestCompressor.h"
TAO_BEGIN_VERSIONED_NAMESPACE_DECL
namespace TAO
{
Test_CompressorFactory::Test_CompressorFactory (void) :
::TAO::CompressorFactory (COMPRESSORID_FOR_TESTING),
compressor_ (::Compression::Compressor::_nil ())
{
}
::Compression::Compressor_ptr
Test_CompressorFactory::get_compressor (
::Compression::CompressionLevel compression_level)
{
// @todo, make a array based on compression level
if (CORBA::is_nil (compressor_.in ()))
{
compressor_ = new TestCompressor (this, compression_level);
}
return ::Compression::Compressor::_duplicate (compressor_.in ());
}
}
TAO_END_VERSIONED_NAMESPACE_DECL
|