This documentation differs from the official API. Jadeite adds extra features to the API including: variable font sizes, constructions examples, placeholders for classes and methods, and auto-generated “See Also” links. Additionally it is missing some items found in standard Javadoc documentation, including: generics type information, “Deprecated” tags and comments, “See Also” links, along with other minor differences. Please send any questions or feedback to bam@cs.cmu.edu.


javax.xml.crypto.dsig
interface Transform

All Superinterfaces:
AlgorithmMethod
All Known Subinterfaces:
CanonicalizationMethod
All Known Implementing Classes:
TransformService

public interface Transform
extends AlgorithmMethod

A representation of the XML Transform element as defined in the W3C Recommendation for XML-Signature Syntax and Processing. The XML Schema Definition is defined as:

 <element name="Transform" type="ds:TransformType"/>
   <complexType name="TransformType" mixed="true">
     <choice minOccurs="0" maxOccurs="unbounded">
       <any namespace="##other" processContents="lax"/>
       <!-- (1,1) elements from (0,unbounded) namespaces -->
       <element name="XPath" type="string"/>
     </choice>
     <attribute name="Algorithm" type="anyURI" use="required"/>
   </complexType>
 
A Transform instance may be created by invoking the {@link XMLSignatureFactory#newTransform newTransform} method of the {@link XMLSignatureFactory} class.


Field Summary
static String BASE64
          The Base64 transform algorithm URI.
static String ENVELOPED
          The Enveloped Signature transform algorithm URI.
static String XPATH
          The XPath transform algorithm URI.
static String XPATH2
          The XPath Filter 2 transform algorithm URI.
static String XSLT
          The XSLT transform algorithm URI.
 
Method Summary
 AlgorithmParameterSpec

          Returns the algorithm-specific input parameters associated with this Transform.
 Data

          Transforms the specified data using the underlying transform algorithm.
 Data

          Transforms the specified data using the underlying transform algorithm.
 
Methods inherited from class javax.xml.crypto.AlgorithmMethod
getAlgorithm, getParameterSpec
 

Field Detail

BASE64

public static final String BASE64
The Base64 transform algorithm URI.

ENVELOPED

public static final String ENVELOPED
The Enveloped Signature transform algorithm URI.

XPATH

public static final String XPATH
The XPath transform algorithm URI.

XPATH2

public static final String XPATH2
The XPath Filter 2 transform algorithm URI.

XSLT

public static final String XSLT
The XSLT transform algorithm URI.
Method Detail

getParameterSpec

public AlgorithmParameterSpec getParameterSpec()
Returns the algorithm-specific input parameters associated with this Transform.

The returned parameters can be typecast to a {@link TransformParameterSpec} object.

Returns:
the algorithm-specific input parameters (may be null if not specified)

transform

public Data transform(Data data,
                      XMLCryptoContext context)
               throws TransformException
Transforms the specified data using the underlying transform algorithm.

Parameters:
data - the data to be transformed
context - the XMLCryptoContext containing additional context (may be null if not applicable)
Returns:
the transformed data
Throws:
TransformException - if an error occurs while executing the transform

transform

public Data transform(Data data,
                      XMLCryptoContext context,
                      OutputStream os)
               throws TransformException
Transforms the specified data using the underlying transform algorithm. If the output of this transform is an OctetStreamData, then this method returns null and the bytes are written to the specified OutputStream. Otherwise, the OutputStream is ignored and the method behaves as if {@link #transform(Data, XMLCryptoContext)} were invoked.

Parameters:
data - the data to be transformed
context - the XMLCryptoContext containing additional context (may be null if not applicable)
os - the OutputStream that should be used to write the transformed data to
Returns:
the transformed data (or null if the data was written to the OutputStream parameter)
Throws:
TransformException - if an error occurs while executing the transform


This documentation differs from the official API. Jadeite adds extra features to the API including: variable font sizes, constructions examples, placeholders for classes and methods, and auto-generated “See Also” links. Additionally it is missing some items found in standard Javadoc documentation, including: generics type information, “Deprecated” tags and comments, “See Also” links, along with other minor differences. Please send any questions or feedback to bam@cs.cmu.edu.
This page displays the Jadeite version of the documention, which is derived from the offical documentation that contains this copyright notice:
Copyright 2008 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.
The official Sun™ documentation can be found here at http://java.sun.com/javase/6/docs/api/.