1
0
mirror of https://github.com/codership/wsrep-lib.git synced 2025-07-28 20:02:00 +03:00

Provider abstraction code compiles.

This commit is contained in:
Teemu Ollakka
2018-06-10 12:46:42 +03:00
parent e74b214c9c
commit ca615fcbd8
11 changed files with 324 additions and 83 deletions

View File

@ -37,6 +37,20 @@ namespace wsrep
++key_parts_len_;
}
enum type type() const
{
return type_;
}
size_t size() const
{
return key_parts_len_;
}
const wsrep::buffer* key_parts() const
{
return key_parts_;
}
private:
enum type type_;

View File

@ -115,6 +115,9 @@ namespace wsrep
{
return (std::memcmp(data_, other.data_, sizeof(data_)) == 0);
}
const unsigned char* data() const { return data_; }
size_t data_size() const { return 16; }
private:
enum type type_;
unsigned char data_[16];
@ -210,15 +213,34 @@ namespace wsrep
, flags_(flags)
{ }
wsrep::transaction_id transaction_id() const
const wsrep::id& group_id() const
{
return stid_.transaction_id();
return gtid_.id();
}
wsrep::seqno seqno() const
{
return gtid_.seqno();
}
const wsrep::id& server_id() const
{
return stid_.server_id();
}
wsrep::client_id client_id() const
{
return stid_.client_id();
}
wsrep::transaction_id transaction_id() const
{
return stid_.transaction_id();
}
wsrep::seqno depends_on() const { return depends_on_; }
int flags() const { return flags_; }
private:
wsrep::gtid gtid_;
wsrep::stid stid_;
@ -249,6 +271,8 @@ namespace wsrep
/*!
* Return value enumeration
*
* \todo Convert this to struct ec, get rid of prefixes.
*/
enum status
{

View File

@ -122,7 +122,7 @@ namespace wsrep
wsrep::mutex& mutex();
// wsrep_ws_handle_t& ws_handle() { return ws_handle_; }
wsrep::ws_handle& ws_handle() { return ws_handle_; }
private:
transaction_context(const transaction_context&);
transaction_context operator=(const transaction_context&);