QueueAccessMode 枚举


在创建时为 MessageQueue 指定访问模式。Specifies the access mode for a MessageQueue at creation time.

public enum class QueueAccessMode
public enum QueueAccessMode
type QueueAccessMode = 
Public Enum QueueAccessMode


Peek 32

队列仅可以查看消息。The queue can only peek at messages.

PeekAndAdmin 160

队列可以查看消息。The queue can peek at messages. 消息也可以被清除。It can also be purged.

Receive 1

队列可以查看或接收消息。The queue can peek at or receive messages.

ReceiveAndAdmin 129

队列可以接收消息。The queue can receive messages. 消息也可以被清除。It can also be purged.

Send 2

队列仅可以发送消息。The queue can only send messages.

SendAndReceive 3

队列可以查看、接收或发送消息。The queue can peek at, receive, or send messages.


在创建MessageQueue时, 如果未指定访问模式, 访问模式将默认为QueueAccessMode.SendAndReceiveWhen creating a MessageQueue, if no access mode is specified, the access mode defaults to QueueAccessMode.SendAndReceive.

一旦创建, 就不能更改访问模式。 MessageQueueOnce the MessageQueue is created, the access mode cannot be changed.