2016-05-26 17:22:19 -04:00
|
|
|
#if 0
|
2016-05-19 10:41:06 -04:00
|
|
|
#ifndef _SERVICES_STORE_HPP_
|
|
|
|
#define _SERVICES_STORE_HPP_
|
2016-05-30 23:58:58 -04:00
|
|
|
=======
|
|
|
|
#pragma once
|
|
|
|
>>>>>>> task(core): Cleanup
|
2016-05-19 10:41:06 -04:00
|
|
|
|
|
|
|
#include <string>
|
|
|
|
#include <memory>
|
|
|
|
|
|
|
|
#include <boost/interprocess/anonymous_shared_memory.hpp>
|
|
|
|
#include <boost/interprocess/mapped_region.hpp>
|
|
|
|
|
|
|
|
#define PIPE_READ 0
|
|
|
|
#define PIPE_WRITE 1
|
|
|
|
|
|
|
|
struct Store
|
|
|
|
{
|
|
|
|
const char FLAG_NO_DATA = '1';
|
|
|
|
const char FLAG_DATA = '2';
|
|
|
|
|
|
|
|
boost::interprocess::mapped_region region;
|
|
|
|
boost::interprocess::mapped_region state_region;
|
|
|
|
|
|
|
|
void flag();
|
|
|
|
void unflag();
|
|
|
|
bool check();
|
|
|
|
|
|
|
|
char &get(char &d);
|
|
|
|
void set(char val);
|
|
|
|
|
|
|
|
std::string get_string();
|
|
|
|
std::string &get_string(std::string& s);
|
2016-06-20 21:59:43 -04:00
|
|
|
void set_string(std::string s);
|
2016-05-19 10:41:06 -04:00
|
|
|
|
|
|
|
Store(int size);
|
|
|
|
~Store() {}
|
|
|
|
};
|
2016-05-30 23:58:58 -04:00
|
|
|
<<<<<<< 78384e08923e669c65c68a8cdf81dba37a633d6c
|
2016-05-19 10:41:06 -04:00
|
|
|
|
|
|
|
#endif
|
2016-05-26 17:22:19 -04:00
|
|
|
#endif
|