~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/transaction_log/write_buffer.h

  • Committer: Olaf van der Spek
  • Date: 2011-08-14 17:13:26 UTC
  • mto: This revision was merged to the branch mainline in revision 2407.
  • Revision ID: olafvdspek@gmail.com-20110814171326-e6nnh3q5cp3o0tk3
Remove unnecessary constructors and destructors

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
 
31
31
#pragma once
32
32
 
 
33
#include <boost/noncopyable.hpp>
33
34
#include <stdint.h>
34
35
#include <vector>
35
36
#include <pthread.h>
36
37
 
37
 
class WriteBuffer
 
38
class WriteBuffer : boost::noncopyable
38
39
{
39
40
public:
40
41
  static const size_t DEFAULT_WRITE_BUFFER_SIZE= 1024; /* Many GPB messages are < 1 KB... */
78
79
    return buffer.size();
79
80
  }
80
81
private:
81
 
  /* Prohibit these */
82
 
  WriteBuffer(const WriteBuffer&);
83
 
  WriteBuffer &operator=(const WriteBuffer&);
84
 
 
85
82
  std::vector<uint8_t> buffer; ///< Raw memory buffer managed by the log
86
83
  pthread_mutex_t latch; ///< Lock around the synchronized parts of the log (the write buffer)
87
84
};