📄 mqueue.h.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"><html><head><!-- Copyright 1997 The Open Group, All Rights Reserved --><title><mqueue.h></title></head><body bgcolor=white><center><font size=2>The Single UNIX ® Specification, Version 2<br>Copyright © 1997 The Open Group</font></center><hr size=2 noshade><h4><a name = "tag_000_007_790"> </a>NAME</h4><blockquote>mqueue.h - message queues(<b>REALTIME</b>)</blockquote><h4><a name = "tag_000_007_791"> </a>SYNOPSIS</h4><blockquote><pre><code>#include <mqueue.h></code></pre></blockquote><h4><a name = "tag_000_007_792"> </a>DESCRIPTION</h4><blockquote>The<i><mqueue.h></i>header defines the<b>mqd_t</b>type, which is used for message queue descriptors. This will not bean array type. A message queue descriptor may be implemented using afile descriptor, in which case applications can open up to at least{OPEN_MAX} file and message queues.<p>The<i><mqueue.h></i>header defines the<b>sigevent</b>structure (as described in<i><a href="signal.h.html"><signal.h></a></i>)and the <b>mq_attr</b>structure, which is used in getting and setting the attributes of amessage queue. Attributes are initially set when the message queue iscreated. A<b>mq_attr</b>structure will have at least the following fields:<pre><code>long mq_flags message queue flagslong mq_maxmsg maximum number of messageslong mq_msgsize maximum message sizelong mq_curmsgs number of messages currently queued</code></pre><p>The following are declared as functions and may also be declared asmacros.Function prototypes must be provided for use with an ISO Ccompiler.<pre><code>int <a href="mq_close.html">mq_close</a>(mqd_t);int <a href="mq_getattr.html">mq_getattr</a>(mqd_t, struct mq_attr *);int <a href="mq_notify.html">mq_notify</a>(mqd_t, const struct sigevent *);mqd_t <a href="mq_open.html">mq_open</a>(const char *, int, ...);ssize_t <a href="mq_receive.html">mq_receive</a>(mqd_t, char *, size_t, unsigned int *);int <a href="mq_send.html">mq_send</a>(mqd_t, const char *, size_t, unsigned int);int <a href="mq_setattr.html">mq_setattr</a>(mqd_t, const struct mq_attr *, struct mq_attr *);int <a href="mq_unlink.html">mq_unlink</a>(const char *);</code></pre><p>Inclusion of the<i><mqueue.h></i>header may make visible symbols defined in the headers<i><a href="fcntl.h.html"><fcntl.h></a></i>,<i><a href="signal.h.html"><signal.h></a></i>,<i><a href="systypes.h.html"><sys/types.h></a></i>and<i><a href="time.h.html"><time.h></a></i>.</blockquote><h4><a name = "tag_000_007_793"> </a>APPLICATION USAGE</h4><blockquote>None.</blockquote><h4><a name = "tag_000_007_794"> </a>FUTURE DIRECTIONS</h4><blockquote>None.</blockquote><h4><a name = "tag_000_007_795"> </a>SEE ALSO</h4><blockquote><i><a href="fcntl.h.html"><fcntl.h></a></i>,<i><a href="signal.h.html"><signal.h></a></i>,<i><a href="systypes.h.html"><sys/types.h></a></i>,<i><a href="time.h.html"><time.h></a></i>.</blockquote><hr size=2 noshade><center><font size=2>UNIX ® is a registered Trademark of The Open Group.<br>Copyright © 1997 The Open Group<br> [ <a href="../index.html">Main Index</a> | <a href="../xshix.html">XSH</a> | <a href="../xcuix.html">XCU</a> | <a href="../xbdix.html">XBD</a> | <a href="../cursesix.html">XCURSES</a> | <a href="../xnsix.html">XNS</a> ]</font></center><hr size=2 noshade></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -