| 
 | JavaTM Platform Standard Ed. 6 | |||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
public interface RetrievalMethod
      W3C Recommendation for XML-Signature Syntax and Processing 中定义的 XML RetrievalMethod 元素的表示形式。RetrievalMethod 对象用于传送对存储在另一个位置上的 KeyInfo 信息的引用。XML Schema Definition 的定义如下: 
   <element name="RetrievalMethod" type="ds:RetrievalMethodType"/>
   <complexType name="RetrievalMethodType">
     <sequence>
       <element name="Transforms" type="ds:TransformsType" minOccurs="0"/> 
     </sequence>  
     <attribute name="URI" type="anyURI"/>
     <attribute name="Type" type="anyURI" use="optional"/>
   </complexType>
  通过调用 
  KeyInfoFactory 类的一个 
  newRetrievalMethod 方法,并向其传递标识 KeyInfo 位置的 URI、可选的标识 KeyInfo 类型的类型 URI 和可选的 
  Transform 列表,可以创建 
  RetrievalMethod 实例,例如: 
  
KeyInfoFactory factory = KeyInfoFactory.getInstance("DOM");
RetrievalMethod rm = factory.newRetrievalMethod
("#KeyValue-1", KeyValue.DSA_TYPE, Collections.singletonList(Transform.BASE64));
  
  
KeyInfoFactory.newRetrievalMethod(String), 
    KeyInfoFactory.newRetrievalMethod(String, String, List)
   | 方法摘要 | |
|---|---|
|  Data | dereference(XMLCryptoContext context)取消引用此 RetrievalMethod引用的KeyInfo信息,并应用指定的Transform。 | 
|  List | getTransforms()返回一个 不可修改的列表,由此RetrievalMethod的Transform组成。 | 
|  String | getURI()返回已引用的 KeyInfo信息的 URI。 | 
| 从接口 javax.xml.crypto.URIReference 继承的方法 | 
|---|
| getType | 
| 从接口 javax.xml.crypto.XMLStructure 继承的方法 | 
|---|
| isFeatureSupported | 
| 方法详细信息 | 
|---|
List getTransforms()
不可修改的列表,由此 
    RetrievalMethod 的 
    Transform 组成。 
    
Transform 对象列表(可以为空,但不能为 
      null)。
     String getURI()
KeyInfo 信息的 URI。 
    
URIReference 中的 
      getURI
     KeyInfo 信息(RFC 2396 格式)的 URI(不能为 
      null)
     
Data dereference(XMLCryptoContext context)
                 throws URIReferenceException 
  RetrievalMethod 引用的 
    KeyInfo 信息,并应用指定的 
    Transform。 
    
context - 
      XMLCryptoContext,包含用来取消引用 URI 的其他有用信息。上下文的 
      baseURI 和 
      dereferencer 参数(如果已指定)用于解析和取消引用此 
      RetrievalMethod 
     RetrievalMethod 引用的 
      KeyInfo 信息的原始内容的 
      Data 对象。调用者负责将返回的数据转换成适当的 
      KeyInfo 对象。 
     NullPointerException - 如果 
      context 为 
      null 
     URIReferenceException - 如果在取消引用时发生错误
     | 
 | JavaTM Platform Standard Ed. 6 | |||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
版权所有 2007 Sun Microsystems, Inc. 保留所有权利。 请遵守许可证条款。另请参阅文档重新分发政策。