java命名空间java.security.cert类certstore的类成员方法:
getinstance定义及介绍
本文导语:
getinstance
public static certstore getinstance(string type,
certstoreparameters params,
string provider)
throws invalidalgorithmparameterexception,
nosuchalg...
getinstance
public static certstore getinstance(string type,
certstoreparameters params,
string provider)
throws invalidalgorithmparameterexception,
nosuchalgorithmexception,
nosuchproviderexception
- 返回一个实现指定
certstore 类型的 certstore 对象。
返回一个封装 certstorespi 实现的新 certstore 对象,该实现取自指定提供者。指定提供者必须在安全提供者列表中注册。
注意,可以通过 security.getproviders() 方法获取已注册提供者列表。
使用指定的 certstoreparameters 初始化返回的 certstore。不同类型的 certstore 所需的参数类型有所不同。注意,指定的 certstoreparameters 对象将被复制。
- 参数:
type - 请求的 certstore 类型。有关标准类型的信息,请参阅
java certification path api programmer's guide 中的附录 a。params - 初始化参数(可以为 null)。provider - 提供者名称。
- 返回:
- 实现指定类型的
certstore 对象。
- 抛出:
nosuchalgorithmexception - 如果不能从指定的提供者获得指定类型的 certstorespi 实现。
invalidalgorithmparameterexception - 如果指定的初始化参数不适合此 certstore。
nosuchproviderexception - 如果指定的提供者未在安全提供者列表中注册。
illegalargumentexception - 如果 provider 为 null 或空。- 另请参见:
provider