Package org.apache.xml.security.transforms

Examples of org.apache.xml.security.transforms.Transform


         XMLSignatureInput nodes = this.getNodesetBeforeFirstCanonicalization();
         Set inclusiveNamespaces = new HashSet();

         {
            Transforms transforms = this.getTransforms();
            Transform c14nTransform = null;

            if (transforms != null) {
               doTransforms: for (int i = 0; i < transforms.getLength(); i++) {
                  Transform t = transforms.item(i);
                  String URI = t.getURI();

                  if (URI.equals(Transforms.TRANSFORM_C14N_EXCL_OMIT_COMMENTS)
                          || URI.equals(
                             Transforms.TRANSFORM_C14N_EXCL_WITH_COMMENTS)) {
                     c14nTransform = t;
View Full Code Here


        }
        if (enveloped) {
            boolean isEnveloped = false;
            for (int i = 0; i < transforms.getLength(); i++) {
                try {
                    Transform tr = transforms.item(i);
                    if (Transforms.TRANSFORM_ENVELOPED_SIGNATURE.equals(tr.getURI())) {
                        isEnveloped = true;
                        break;
                    }
                } catch (Exception ex) {
                    throwFault("Problem accessing Transform instance", ex);   
View Full Code Here

         XMLSignatureInput output = input;
         Transforms transforms = this.getTransforms();

         if (transforms != null) {
            doTransforms: for (int i = 0; i < transforms.getLength(); i++) {
               Transform t = transforms.item(i);
               String URI = t.getURI();

               if (URI.equals(Transforms
                       .TRANSFORM_C14N_EXCL_OMIT_COMMENTS) || URI
                          .equals(Transforms
                             .TRANSFORM_C14N_EXCL_WITH_COMMENTS) || URI
                                .equals(Transforms
                                   .TRANSFORM_C14N_OMIT_COMMENTS) || URI
                                      .equals(Transforms
                                         .TRANSFORM_C14N_WITH_COMMENTS)) {

                  break doTransforms;
               }

               output = t.performTransform(output, null);
            }

            output.setSourceURI(input.getSourceURI());
         }
         return output;
View Full Code Here

         XMLSignatureInput nodes = this.getNodesetBeforeFirstCanonicalization();
         Set inclusiveNamespaces = new HashSet();

         {
            Transforms transforms = this.getTransforms();
            Transform c14nTransform = null;

            if (transforms != null) {
               doTransforms: for (int i = 0; i < transforms.getLength(); i++) {
                  Transform t = transforms.item(i);
                  String URI = t.getURI();

                  if (URI.equals(Transforms.TRANSFORM_C14N_EXCL_OMIT_COMMENTS)
                          || URI.equals(
                             Transforms.TRANSFORM_C14N_EXCL_WITH_COMMENTS)) {
                     c14nTransform = t;
View Full Code Here

  public void testOldTransformSpiApi() throws Exception {
    Init.init();
    Document doc=DocumentBuilderFactory.newInstance().newDocumentBuilder().newDocument();
    Transform.register("old", OldTransform.class.getName());

    Transform a=new Transform(doc,"old",null);
    OldTransform.compare=a;
    a.performTransform(null);
  };
View Full Code Here

        Element nscontext = TestUtils.createDSctx
      (doc1, "dsig", Constants.SignatureSpecNS);
        Node transformEl = XPathAPI.selectSingleNode
      (doc1, "//dsig:Transform[1]", nscontext);
  Transform transform = Transform.getInstance
      (doc1, Transforms.TRANSFORM_XSLT, transformEl.getChildNodes());

  transform.performTransform(new XMLSignatureInput(doc2));
    }
View Full Code Here

        Element nscontext = XMLUtils.createDSctx
      (doc1, "dsig", Constants.SignatureSpecNS);
        Node transformEl = XPathAPI.selectSingleNode
      (doc1, "//dsig:Transform[1]", nscontext);
  Transform transform = Transform.getInstance
      (doc1, Transforms.TRANSFORM_XSLT, transformEl.getChildNodes());

  XMLSignatureInput output =
      transform.performTransform(new XMLSignatureInput(doc2));
    }
View Full Code Here

  public void testOldTransformSpiApi() throws Exception {
    Init.init();
    Document doc=DocumentBuilderFactory.newInstance().newDocumentBuilder().newDocument();
    Transform.register("old", OldTransform.class.getName());

    Transform a=new Transform(doc,"old",null);
    OldTransform.compare=a;
    a.performTransform(null);
  };
View Full Code Here

        Element nscontext = TestUtils.createDSctx
      (doc1, "dsig", Constants.SignatureSpecNS);
        Node transformEl = XPathAPI.selectSingleNode
      (doc1, "//dsig:Transform[1]", nscontext);
  Transform transform = Transform.getInstance
      (doc1, Transforms.TRANSFORM_XSLT, transformEl.getChildNodes());

  XMLSignatureInput output =
      transform.performTransform(new XMLSignatureInput(doc2));
    }
View Full Code Here

        Element nscontext = TestUtils.createDSctx
      (doc1, "dsig", Constants.SignatureSpecNS);
        Node transformEl = XPathAPI.selectSingleNode
      (doc1, "//dsig:Transform[1]", nscontext);
  Transform transform = Transform.getInstance
      (doc1, Transforms.TRANSFORM_XSLT, transformEl.getChildNodes());

  transform.performTransform(new XMLSignatureInput(doc2));
    }
View Full Code Here

TOP

Related Classes of org.apache.xml.security.transforms.Transform

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.