org.eclipse.osgi.internal.baseadaptor
Class BasePermissionStorage

java.lang.Object
  extended by org.eclipse.osgi.internal.baseadaptor.BasePermissionStorage
All Implemented Interfaces:
PermissionStorage

public class BasePermissionStorage
extends Object
implements PermissionStorage


Method Summary
 String[] getConditionalPermissionInfos()
          Returns the persistent array of encoded ConditionalPermissionInfo strings
 String[] getLocations()
          Returns the locations that have permission data assigned to them, that is, locations for which permission data exists in persistent storage.
 String[] getPermissionData(String location)
          Gets the permission data assigned to the specified location.
 boolean isDirty()
           
 void saveConditionalPermissionInfos(String[] infos)
          Persists the array of encoded ConditionalPermissionInfo strings
 void setDirty(boolean dirty)
           
 void setPermissionData(String location, String[] data)
          Assigns the specified permission data to the specified location.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getLocations

public String[] getLocations()
                      throws IOException
Description copied from interface: PermissionStorage
Returns the locations that have permission data assigned to them, that is, locations for which permission data exists in persistent storage.

Specified by:
getLocations in interface PermissionStorage
Returns:
The locations that have permission data in persistent storage, or null if there is no permission data in persistent storage.
Throws:
IOException

getPermissionData

public String[] getPermissionData(String location)
                           throws IOException
Description copied from interface: PermissionStorage
Gets the permission data assigned to the specified location.

Specified by:
getPermissionData in interface PermissionStorage
Parameters:
location - The location whose permission data is to be returned. The location can be null for the default permission data.
Returns:
The permission data assigned to the specified location, or null if that location has not been assigned any permission data.
Throws:
IOException

setPermissionData

public void setPermissionData(String location,
                              String[] data)
                       throws IOException
Description copied from interface: PermissionStorage
Assigns the specified permission data to the specified location.

Specified by:
setPermissionData in interface PermissionStorage
Parameters:
location - The location that will be assigned the permissions. The location can be null for the default permission data.
data - The permission data to be assigned, or null if the specified location is to be removed from persistent storaqe.
Throws:
IOException

saveConditionalPermissionInfos

public void saveConditionalPermissionInfos(String[] infos)
                                    throws IOException
Description copied from interface: PermissionStorage
Persists the array of encoded ConditionalPermissionInfo strings

Specified by:
saveConditionalPermissionInfos in interface PermissionStorage
Parameters:
infos - an array of encoded ConditionalPermissionInfo strings
Throws:
IOException

getConditionalPermissionInfos

public String[] getConditionalPermissionInfos()
                                       throws IOException
Description copied from interface: PermissionStorage
Returns the persistent array of encoded ConditionalPermissionInfo strings

Specified by:
getConditionalPermissionInfos in interface PermissionStorage
Returns:
an array of encoded ConditionalPermissionInfo strings or null if none exist in persistent storage.
Throws:
IOException

isDirty

public boolean isDirty()

setDirty

public void setDirty(boolean dirty)


Copyright © 2007–2014 The Apache Software Foundation. All rights reserved.