Examples of translate()


Examples of org.apache.openjpa.util.RuntimeExceptionTranslator.translate()

     * on an instance, and therefore will not be caught and translated by the
     * broker.
     */
    protected RuntimeException translate(RuntimeException re) {
        RuntimeExceptionTranslator trans = _broker.getInstanceExceptionTranslator();
        return (trans == null) ? re : trans.translate(re);
    }

    /**
     * Lock the state manager if the multithreaded option is set.
     */
 
View Full Code Here

Examples of org.apache.pdfbox.util.Matrix.translate()

            {
                // position vector, in text space
                Vector v = font.getPositionVector(code);

                // apply the position vector to the horizontal origin to get the vertical origin
                textRenderingMatrix.translate(v);
            }

            // get glyph's horizontal and vertical displacements, in text space
            Vector w = font.getDisplacement(code);
View Full Code Here

Examples of org.apache.pivot.wtk.Bounds.translate()

                if (offset >= nodeViewOffset
                    && offset < nodeViewOffset + characterCount) {
                    characterBounds = nodeView.getCharacterBounds(offset - nodeViewOffset);

                    if (characterBounds != null) {
                        characterBounds = characterBounds.translate(nodeView.getX(), nodeView.getY());
                    }

                    break;
                }
            }
View Full Code Here

Examples of org.apache.pivot.wtkx.Translator.translate()

       Translator translator = new Translator();

       InputStream inputStream = JavaTranslatorTest.class.getResourceAsStream
           ("java_translator_test.wtkx");

       JavaFileObject javaFileObject = translator.translate(inputStream,
           "org.apache.pivot.wtkx.test.java_translator_test_WTKX");

       System.out.println(javaFileObject.getCharContent(true));

       ArrayList<JavaFileObject> javaFileObjects = new ArrayList<JavaFileObject>(1);
View Full Code Here

Examples of org.apache.tika.language.translate.MicrosoftTranslator.translate()

        MicrosoftTranslator translator = new MicrosoftTranslator();
        // Change the id and secret! See http://msdn.microsoft.com/en-us/library/hh454950.aspx.
        translator.setId("dummy-id");
        translator.setSecret("dummy-secret");
        try {
            return translator.translate(text, "fr");
        } catch (Exception e) {
            return "Error while translating.";
        }
    }
}
View Full Code Here

Examples of org.apache.xalan.xsltc.compiler.Stylesheet.translate()

      if (!errorsFound() && stylesheet != null) {
    stylesheet.setMultiDocument(xsltc.isMultiDocument());

                // Class synchronization is needed for BCEL
                synchronized (xsltc.getClass()) {
                    stylesheet.translate();
                }
      }

      if (!errorsFound()) {
    // Check that the transformation went well before returning
View Full Code Here

Examples of org.eclipse.draw2d.Graphics.translate()

    Graphics g = null;
    try {
      image = new Image(device, r.width, r.height);
      gc = new GC(image);
      g = new SWTGraphics(gc);
      g.translate(r.x * -1, r.y * -1);

      figure.paint(g);

      ImageLoader imageLoader = new ImageLoader();
      imageLoader.data = new ImageData[] { image.getImageData() };
View Full Code Here

Examples of org.eclipse.draw2d.SWTGraphics.translate()

        Rectangle r = figure.getBounds();
        try {
            image = new Image(Display.getDefault(), r.width, r.height);
            gc = new GC(image);
            g = new SWTGraphics(gc);
            g.translate(r.x * -1, r.y * -1);
            figure.paint(g);
            ImageLoader imageLoader = new ImageLoader();
            imageLoader.data = new ImageData[] { image.getImageData() };
            imageLoader.save(stream, format);
        } catch (Throwable t) {
View Full Code Here

Examples of org.eclipse.draw2d.geometry.Point.translate()

    Point location = this.constraint.getLocation();
    CompoundModel parent = this.getParentModel();

    if (parent != null && parent instanceof CompoundModel)
    {
      location.translate(parent.getLocationAbs());
    }

    return location;
  }
View Full Code Here

Examples of org.eclipse.draw2d.geometry.PointList.translate()

    // calculate difference
    Dimension delta = bounds.getLocation()
        .getDifference(layout.getLocation()).negate();

    // perform translate
    points.translate(delta.width, delta.height);

    // calculate scale
    double sx = ((double) layout.width) / ((double) bounds.width);
    double sy = ((double) layout.height) / ((double) bounds.height);
View Full Code Here
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.