MessageQueuePermissionEntry.PermissionAccess 属性
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
获取在权限请求中使用的权限访问级别。
public:
property System::Messaging::MessageQueuePermissionAccess PermissionAccess { System::Messaging::MessageQueuePermissionAccess get(); };
public System.Messaging.MessageQueuePermissionAccess PermissionAccess { get; }
member this.PermissionAccess : System.Messaging.MessageQueuePermissionAccess
Public ReadOnly Property PermissionAccess As MessageQueuePermissionAccess
属性值
MessageQueuePermissionAccess 值的按位组合。
示例
下面的代码示例显示消息队列权限条目的 PermissionAccess 属性的值。
// Connect to a queue on the local computer.
MessageQueue^ queue = gcnew MessageQueue(".\\exampleQueue");
// Create a new instance of MessageQueuePermissionEntry.
MessageQueuePermissionEntry^ entry = gcnew MessageQueuePermissionEntry(
MessageQueuePermissionAccess::Receive,
queue->MachineName,
queue->Label,
queue->Category.ToString());
// Display the value of the entry's PermissionAccess property.
Console::WriteLine("PermissionAccess: {0}", entry->PermissionAccess);
queue->Close();
// Connect to a queue on the local computer.
MessageQueue queue = new MessageQueue(".\\exampleQueue");
// Create a new instance of MessageQueuePermissionEntry.
MessageQueuePermissionEntry entry = new MessageQueuePermissionEntry(
MessageQueuePermissionAccess.Receive,
queue.MachineName,
queue.Label,
queue.Category.ToString());
// Display the value of the entry's PermissionAccess property.
Console.WriteLine("PermissionAccess: {0}", entry.PermissionAccess);