Edit

Share via


MessageQueueAccessControlEntry Constructors

Definition

Initializes a new instance of the MessageQueueAccessControlEntry class with the specified trustee and Message Queuing access rights.

Overloads

MessageQueueAccessControlEntry(Trustee, MessageQueueAccessRights)

Initializes a new instance of the MessageQueueAccessControlEntry class, granting the specified Message Queuing access rights to the specified trustee.

MessageQueueAccessControlEntry(Trustee, MessageQueueAccessRights, AccessControlEntryType)

Initializes a new instance of the MessageQueueAccessControlEntry class, with the specified trustee and Message Queuing access rights. The type of access (such as Allow or Deny) is defined by the entry type you pass in.

MessageQueueAccessControlEntry(Trustee, MessageQueueAccessRights)

Initializes a new instance of the MessageQueueAccessControlEntry class, granting the specified Message Queuing access rights to the specified trustee.

public:
 MessageQueueAccessControlEntry(System::Messaging::Trustee ^ trustee, System::Messaging::MessageQueueAccessRights rights);
public MessageQueueAccessControlEntry (System.Messaging.Trustee trustee, System.Messaging.MessageQueueAccessRights rights);
new System.Messaging.MessageQueueAccessControlEntry : System.Messaging.Trustee * System.Messaging.MessageQueueAccessRights -> System.Messaging.MessageQueueAccessControlEntry
Public Sub New (trustee As Trustee, rights As MessageQueueAccessRights)

Parameters

trustee
Trustee

A Trustee that specifies a user, group, computer, domain, or alias.

rights
MessageQueueAccessRights

A bitwise combination of the MessageQueueAccessRights values which defines the combination of rights to grant to the trustee.

Remarks

Use this overload of the constructor to grant rights to the specified trustee. The rights you specify in the rights parameter are a bitwise combination of members of the MessageQueueAccessRights bitflag, which includes such rights as receiving messages, deleting queues, and setting queue properties. The constructor uses the rights you pass in to set this instance's MessageQueueAccessRights property.

Pass this instance of MessageQueueAccessControlEntry directly into an overload of the SetPermissions method to grant rights only to this trustee, or add this instance to a AccessControlList before calling SetPermissions to grant or deny rights to multiple trustees at once.

See also

Applies to

MessageQueueAccessControlEntry(Trustee, MessageQueueAccessRights, AccessControlEntryType)

Initializes a new instance of the MessageQueueAccessControlEntry class, with the specified trustee and Message Queuing access rights. The type of access (such as Allow or Deny) is defined by the entry type you pass in.

public:
 MessageQueueAccessControlEntry(System::Messaging::Trustee ^ trustee, System::Messaging::MessageQueueAccessRights rights, System::Messaging::AccessControlEntryType entryType);
public MessageQueueAccessControlEntry (System.Messaging.Trustee trustee, System.Messaging.MessageQueueAccessRights rights, System.Messaging.AccessControlEntryType entryType);
new System.Messaging.MessageQueueAccessControlEntry : System.Messaging.Trustee * System.Messaging.MessageQueueAccessRights * System.Messaging.AccessControlEntryType -> System.Messaging.MessageQueueAccessControlEntry
Public Sub New (trustee As Trustee, rights As MessageQueueAccessRights, entryType As AccessControlEntryType)

Parameters

trustee
Trustee

A Trustee that specifies a user, group, computer, domain, or alias.

rights
MessageQueueAccessRights

A bitwise combination of the MessageQueueAccessRights values which defines the combination of rights to grant to the trustee.

entryType
AccessControlEntryType

One of the AccessControlEntryType values, which specifies whether to allow, deny, set or revoke the specified rights.

Remarks

Use this overload of the constructor to grant or deny rights to the specified trustee. The rights you specify in the rights parameter are a bitwise combination of members of the MessageQueueAccessRights bitflag, which includes such rights as receiving messages, deleting queues, and setting queue properties. The constructor uses the rights you pass in to set this instance's MessageQueueAccessRights property.

For more information about granting or denying rights, see the AccessControlEntryType topic. For two members, Allow and Deny, there may be preexisting and possibly contradictory access rights, so the order in which the rights appear in the queue's discretionary access control list (DACL) affects whether the right is ultimately granted. Two other members, Set and Revoke, overwrite any existing rights. Use the member whose behavior is applicable to your application.

Pass this instance of MessageQueueAccessControlEntry directly into an overload of the SetPermissions method to grant or deny rights only to this trustee, or add this instance to a AccessControlList before calling SetPermissions to grant or deny rights to multiple trustees at once.

See also

Applies to