8 #if defined(__CYGWIN__) || defined(_WIN32)    11 #include <semaphore.h>    14 #define STAT_EX_SIZE 175    15 #define PLAY_EX_SIZE 2+6*SIMUL_TRACKS    29       void down(
long long int bytes);
    31       void up(
long long int bytes);
    33       void host(std::string name);
    39       void crc(
unsigned int sum);
    63       semaphore(
const char * name, 
int oflag, mode_t mode, 
unsigned int value);
    65       operator bool() 
const;
    66       void open(
const char * name, 
int oflag, mode_t mode = 0, 
unsigned int value = 0);
    71       bool tryWaitOneSecond();
    75 #if defined(__CYGWIN__) || defined(_WIN32)    76       static SECURITY_ATTRIBUTES getSecurityAttributes();
    88       semGuard(semaphore * thisSemaphore);
    92       semaphore * mySemaphore;
    98       sharedFile(std::string name_ = 
"", 
unsigned int len_ = 0, 
bool master_ = 
false, 
bool autoBackoff = 
true);
    99       sharedFile(
const sharedFile & rhs);
   101       operator bool() 
const;
   102       void init(std::string name_, 
unsigned int len_, 
bool master_ =  
false, 
bool autoBackoff = 
true);
   103       void operator =(sharedFile & rhs);
   105         return name < rhs.name;
   121 #if defined(__CYGWIN__) || defined(_WIN32)   122   void preservePage(std::string);
   123   void releasePage(std::string);
   130     sharedPage(std::string name_ = 
"", 
unsigned int len_ = 0, 
bool master_ = 
false, 
bool autoBackoff = 
true);
   133     operator bool() 
const;
   134     void init(std::string name_, 
unsigned int len_, 
bool master_ =  
false, 
bool autoBackoff = 
true);
   136     bool operator < (
const sharedPage & rhs)
 const {
   137       return name < rhs.
name;
   141     #if defined(__CYGWIN__) || defined(_WIN32)   162       sharedPage(std::string name_ = 
"", 
unsigned int len_ = 0, 
bool master_ = 
false, 
bool autoBackoff = 
true);
   180       sharedServer(std::string name, 
int len, 
bool withCounter = 
false);
   181       void init(std::string name, 
int len, 
bool withCounter = 
false);
   183       void parseEach(
void (*callback)(
char * 
data, 
size_t len, 
unsigned int id));
   184       operator bool() 
const;
   188       bool isInUse(
unsigned int id);
   192       std::string baseName;
   196       std::set<sharedPage> myPages;
   216       sharedClient(std::string name, 
int len, 
bool withCounter = 
false);
   219       void write(
char * 
data, 
int len);
   225       std::string baseName;
   241       unsigned long getTrackId(
size_t offset) 
const;
   242       void setTrackId(
size_t offset, 
unsigned long trackId) 
const;
   243       unsigned long getKeynum(
size_t offset) 
const;
   244       void setKeynum(
size_t offset, 
unsigned long keynum);
 long time()
Gets time currently connected. 
Definition: shared_memory.cpp:618
A class used for the abstraction of semaphores. 
Definition: shared_memory.h:60
long long int up()
Gets the amount of bytes sent. 
Definition: shared_memory.cpp:654
long lastSecond()
Gets the last viewing second of this user. 
Definition: shared_memory.cpp:630
The server part of a server/client model for shared memory. 
Definition: shared_memory.h:177
void wait(int ms)
Sleeps for the indicated amount of milliseconds or longer. 
Definition: timing.cpp:32
statExchange(char *_data)
StatExchange constructor, sets the datapointer to the given value. 
Definition: shared_memory.cpp:598
A class for managing shared files. 
Definition: shared_memory.h:96
long long int now()
Gets timestamp of the current stats. 
Definition: shared_memory.cpp:606
unsigned int crc()
Gets checksum field. 
Definition: shared_memory.cpp:703
std::string host()
Gets the host of this connection. 
Definition: shared_memory.cpp:669
Definition: shared_memory.cpp:25
long long int down()
Gets the amount of bytes received. 
Definition: shared_memory.cpp:642
The client part of a server/client model for shared memory. 
Definition: shared_memory.h:212
char getSync()
Gets checksum field. 
Definition: shared_memory.cpp:715
function init(plot)
Definition: jquery.flot.time.min.js:1
char * data
The payload for the stat exchange. 
Definition: shared_memory.h:56
void setSync(char s)
Sets checksum field. 
Definition: shared_memory.cpp:710
std::string streamName()
Gets the name of the stream this user is viewing. 
Definition: shared_memory.cpp:683
A class for handling shared memory pages. 
Definition: shared_memory.h:160
std::string name
The name of the opened shared file. 
Definition: shared_memory.h:112
Definition: shared_memory.h:238
std::string connector()
Gets the name of the connector through which this user is viewing. 
Definition: shared_memory.cpp:693