Last change
on this file since 36 was 31, checked in by sgosseli, 12 years ago |
Huge commit: use the new includes style in all the files, add the license header in all the headers, and in some cpp.
|
File size:
984 bytes
|
Line | |
---|
1 | /**
|
---|
2 | *
|
---|
3 | * Distributed under the UTC Heudiascy Pacpus License, Version 1.0.
|
---|
4 | * Copyright (c) UTC Heudiasyc 2010 - 2013. All rights reserved.
|
---|
5 | *
|
---|
6 | * See the LICENSE file for more information or a copy at:
|
---|
7 | * http://www.hds.utc.fr/~kurdejma/LICENSE_1_0.txt
|
---|
8 | *
|
---|
9 | */
|
---|
10 |
|
---|
11 | #ifndef DEF_PACPUS_WIN32SHMEM_H
|
---|
12 | #define DEF_PACPUS_WIN32SHMEM_H
|
---|
13 |
|
---|
14 | #include <Pacpus/PacpusTools/ShMemBase.h>
|
---|
15 |
|
---|
16 | typedef void * HANDLE;
|
---|
17 |
|
---|
18 | class Win32ShMem
|
---|
19 | : public ShMemBase
|
---|
20 | {
|
---|
21 | public:
|
---|
22 | Win32ShMem(const char * name, int size);
|
---|
23 | ~Win32ShMem();
|
---|
24 |
|
---|
25 | virtual bool wait(unsigned long timeout = 0);
|
---|
26 | virtual void * read();
|
---|
27 | virtual void read(void * mem, int size);
|
---|
28 | virtual void write(void * data, int size, unsigned long offset = 0);
|
---|
29 | virtual void lockMemory();
|
---|
30 | virtual void unlockMemory();
|
---|
31 | virtual void * getEventIdentifier();
|
---|
32 |
|
---|
33 | protected:
|
---|
34 |
|
---|
35 | private:
|
---|
36 | HANDLE semaphore_;
|
---|
37 | HANDLE shMemHandle_;
|
---|
38 | HANDLE event_;
|
---|
39 | };
|
---|
40 |
|
---|
41 | #endif // DEF_PACPUS_WIN32SHMEM_H
|
---|
Note:
See
TracBrowser
for help on using the repository browser.