public final class SecurePreferencesFactory extends Object
This class is not intended to be instantiated or extended by clients.
Constructor and Description |
---|
SecurePreferencesFactory() |
Modifier and Type | Method and Description |
---|---|
static ISecurePreferences |
getDefault()
Returns default secure preferences.
|
static ISecurePreferences |
open(URL location,
Map options)
Returns a secure properties corresponding to the URL locations supplied.
|
public static ISecurePreferences getDefault()
The framework will attempt to open secure preferences in a user-specific location. As a result, the information stored can be shared among all programs run by the user. The location is determined as follows:
null
if application
was unable to create secure preferences using default locationpublic static ISecurePreferences open(URL location, Map options) throws IOException
null
, a default location is used.
Note that while this method accepts URLs to account for future expandability of this API,
at present the method only accepts "file" URLs that point to a directory.
An IOException
might be thrown if unsupported URL is passed to this method.
Similarly to the rest of the Equinox, URLs passed as an argument must not be encoded, meaning that spaces should stay as spaces, not as "%x20".
location
- URL pointing to the location of secure storage. At present only file URLs
are supported. Pass null
to use default locationoptions
- use to pass hints to the secure preferences implementation. Pass null
if no options are needed. See IProviderHints
IOException
- if unsupported URLs types are passed in, or if location is not accessible
Copyright (c) 2000, 2015 Eclipse Contributors and others. All rights reserved.Guidelines for using Eclipse APIs.