javax.management
Class MBeanTrustPermission

java.lang.Object
  extended by java.security.Permission
      extended by java.security.BasicPermission
          extended by javax.management.MBeanTrustPermission
All Implemented Interfaces:
Serializable, Guard

public class MBeanTrustPermission
extends BasicPermission

Represents the permission held by a trusted source of management beans. For a bean to be added to a management server, the source of that bean must hold this permission. It has a target, but no actions. Valid values for the target are "register" and "*", the latter representing both the existing "register" target and any future targets.

Since:
1.5
See Also:
Serialized Form

Constructor Summary
MBeanTrustPermission(String target)
          Constructs a MBeanTrustPermission with the given target.
MBeanTrustPermission(String target, String actions)
          Constructs a MBeanTrustPermission with the given target and actions.
 
Method Summary
 
Methods inherited from class java.security.BasicPermission
equals, getActions, hashCode, implies, newPermissionCollection
 
Methods inherited from class java.security.Permission
checkGuard, getName, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MBeanTrustPermission

public MBeanTrustPermission(String target)
Constructs a MBeanTrustPermission with the given target. The target must be either "register" or "*". The actions of the permission default to null, so this is equivalent to calling MBeanTrustPermission(target, null).

Parameters:
target - the target of this permission.
Throws:
NullPointerException - if target is null.
IllegalArgumentException - if the target is other than "register" or "*".
See Also:
MBeanTrustPermission(String, String)

MBeanTrustPermission

public MBeanTrustPermission(String target,
                            String actions)
Constructs a MBeanTrustPermission with the given target and actions. The target must be either "register" or "*". The actions must be either null or the empty string, "".

Parameters:
target - the target of this permission.
actions - the actions for this permission.
Throws:
NullPointerException - if target is null.
IllegalArgumentException - if the target is other than "register" or "*" or actions is other than null or "".