Examples of transform()


Examples of org.mule.transformer.simple.ByteArrayToSerializable.transform()

        MuleMessage message = client.send("http://localhost:18081/RemoteService", payload, null);
        assertNotNull(message);
        ByteArrayToSerializable bas = new ByteArrayToSerializable();
        bas.setMuleContext(muleContext);
        assertNotNull(message.getPayload());
        Object result = bas.transform(message.getPayload());
        assertEquals(payload, result);
    }

    public void testBinaryWithBridge() throws Exception
    {

Examples of org.mule.transformer.simple.MessagePropertiesTransformer.transform()

        MuleMessage msg = new DefaultMuleMessage("message", muleContext);
        msg.setOutboundProperty("addedProperty", "originalValue");
        MuleEventContext ctx = getTestEventContext(msg);
        // context clones message
        msg = ctx.getMessage();
        DefaultMuleMessage transformed = (DefaultMuleMessage) t.transform(msg, (String)null);
        assertSame(msg, transformed);
        assertEquals(msg.getUniqueId(), transformed.getUniqueId());
        assertEquals(msg.getPayload(), transformed.getPayload());
        compareProperties(msg, transformed);

Examples of org.mule.transport.jms.transformers.AbstractJmsTransformer.transform()

        ObjectMessage oMsg = session.createObjectMessage();
        File f = FileUtils.newFile("/some/random/path");
        oMsg.setObject(f);
        AbstractJmsTransformer trans = createObject(JMSMessageToObject.class);
        Object result = trans.transform(oMsg);
        assertTrue("Transformed object should be a File", result.getClass().equals(File.class));

        AbstractJmsTransformer trans2 = new SessionEnabledObjectToJMSMessage(session);
        trans2.setReturnDataType(DataTypeFactory.create(ObjectMessage.class));
        initialiseObject(trans2);

Examples of org.mule.transport.jms.transformers.ObjectToJMSMessage.transform()

        // The transformer we are going to use is ObjectToJMSMessage, which will
        // return the same (but mockingly modified!) JMS message that is used as
        // input.
        ObjectToJMSMessage transformer = createObject(ObjectToJMSMessage.class);
        Message transformed = (Message)transformer.transform(msg.getPayload());

        // Finally we can assert that the setProperty done to the MuleMessage actually
        // made it through to the wrapped JMS Message. Yay!
        assertEquals("customValue", transformed.getObjectProperty("JMS_CUSTOM_PROPERTY"));

Examples of org.mule.umo.transformer.UMOTransformer.transform()

        if (configuration.endsWith(".jar")) {
            trans = new JarToSystemDeploymentBundle();
        } else {
            trans = new DirectoryToSystemDeploymentBundle();
        }
        SystemDeploymentBundle sdb = (SystemDeploymentBundle) trans.transform(configuration);
        try {
            handleDeploymentBundle(sdb);
        } catch (Exception e) {
            throw new LifecycleException(new org.mule.config.i18n.Message(Messages.FAILED_TO_START_X, descriptor.getName()), e, this);
        }

Examples of org.newdawn.slick.geom.Ellipse.transform()

    float y = Util.getFloatAttribute(element,"cy");
    float rx = Util.getFloatAttribute(element,"rx");
    float ry = Util.getFloatAttribute(element,"ry");
   
    Ellipse ellipse = new Ellipse(x,y,rx,ry);
    Shape shape = ellipse.transform(transform);

    NonGeometricData data = Util.getNonGeometricData(element);
    data.addAttribute("cx", ""+x);
    data.addAttribute("cy", ""+y);
    data.addAttribute("rx", ""+rx);

Examples of org.newdawn.slick.geom.Path.transform()

   
    StringTokenizer tokens = new StringTokenizer(points, ", ");
    Path path = processPoly(element, tokens);
    NonGeometricData data = Util.getNonGeometricData(element);
    if (path != null) {
      Shape shape = path.transform(transform);
     
      diagram.addFigure(new Figure(Figure.PATH, shape, data, transform));
    }
  }

Examples of org.newdawn.slick.geom.Polygon.transform()

    Polygon poly = new Polygon();
    int count = processPoly(poly, element, tokens);
   
    NonGeometricData data = Util.getNonGeometricData(element);
    if (count > 3) {
      Shape shape = poly.transform(transform);
     
      diagram.addFigure(new Figure(Figure.POLYGON, shape, data, transform));
    }
  }

Examples of org.newdawn.slick.geom.Rectangle.transform()

    float height = Float.parseFloat(element.getAttribute("height"));
    float x = Float.parseFloat(element.getAttribute("x"));
    float y = Float.parseFloat(element.getAttribute("y"));
   
    Rectangle rect = new Rectangle(x,y,width,height);
    Shape shape = rect.transform(transform);
   
    NonGeometricData data = Util.getNonGeometricData(element);
    data.addAttribute("width", ""+width);
    data.addAttribute("height", ""+height);
    data.addAttribute("x", ""+x);

Examples of org.newdawn.slick.geom.Transform.transform()

    }
   
    float[] in = new float[] {x1,y1,x2,y2};
    float[] out = new float[4];
   
    transform.transform(in,0,out,0,2);
    Line line = new Line(out[0],out[1],out[2],out[3]);
   
    NonGeometricData data = Util.getNonGeometricData(element);
    data.addAttribute("x1",""+x1);
    data.addAttribute("x2",""+x2);
TOP
Copyright © 2018 www.massapi.com. 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.