org.osgi.service.cm
Class ConfigurationPermissionCollection

java.lang.Object
  extended by java.security.PermissionCollection
      extended by org.osgi.service.cm.ConfigurationPermissionCollection
All Implemented Interfaces:
java.io.Serializable

final class ConfigurationPermissionCollection
extends java.security.PermissionCollection

Stores a set of ConfigurationPermission permissions.

See Also:
Permission, Permissions, PermissionCollection

Field Summary
private  boolean hasElement
          True if collection is non-empty.
(package private) static long serialVersionUID
           
 
Constructor Summary
ConfigurationPermissionCollection()
          Creates an empty ConfigurationPermissionCollection object.
 
Method Summary
 void add(java.security.Permission permission)
          Adds the specified permission to the ConfigurationPermissionCollection.
 java.util.Enumeration elements()
          Returns an enumeration of an ConfigurationPermission object.
 boolean implies(java.security.Permission p)
          Determines if the specified set of permissions implies the permissions expressed in the parameter permission.
 
Methods inherited from class java.security.PermissionCollection
isReadOnly, setReadOnly, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

serialVersionUID

static final long serialVersionUID
See Also:
Constant Field Values

hasElement

private volatile boolean hasElement
True if collection is non-empty.

Constructor Detail

ConfigurationPermissionCollection

public ConfigurationPermissionCollection()
Creates an empty ConfigurationPermissionCollection object.

Method Detail

add

public void add(java.security.Permission permission)
Adds the specified permission to the ConfigurationPermissionCollection. The key for the hash is the interface name of the service.

Specified by:
add in class java.security.PermissionCollection
Parameters:
permission - The Permission object to add.
Throws:
java.lang.IllegalArgumentException - If the permission is not an ConfigurationPermission.
java.lang.SecurityException - If this ConfigurationPermissionCollection object has been marked read-only.

implies

public boolean implies(java.security.Permission p)
Determines if the specified set of permissions implies the permissions expressed in the parameter permission.

Specified by:
implies in class java.security.PermissionCollection
Parameters:
p - The Permission object to compare.
Returns:
true if permission is a proper subset of a permission in the set; false otherwise.

elements

public java.util.Enumeration elements()
Returns an enumeration of an ConfigurationPermission object.

Specified by:
elements in class java.security.PermissionCollection
Returns:
Enumeration of an ConfigurationPermission object.


Copyright © 2001-2010 Eclipse Foundation. All Rights Reserved.