Examples of writeTo()


Examples of org.pdfclown.objects.PdfDictionary.writeTo()

      if(parser == null)
      {trailer.remove(PdfName.Prev);} // [FIX:0.0.4:5] It (wrongly) kept the 'Prev' entry of multiple-section xref tables.
      else
      {trailer.put(PdfName.Prev,new PdfInteger((int)parser.retrieveXRefOffset()));}
      // Serialize its contents!
      trailer.writeTo(stream); stream.write(Chunk.LineFeed);

      // 3. Tail.
      writeTail(startxref);
    }
    catch(Exception e)
View Full Code Here

Examples of org.pdfclown.objects.PdfIndirectObject.writeTo()

            xrefInUseBlockBuilder,
            indirectObject.getReference(),
            stream.getLength()
            );
          // Add in-use entry content!
          indirectObject.writeTo(stream);
        }
        else // Free entry.
        {
          // Add free entry!
          appendXRefEntry(
View Full Code Here

Examples of org.restlet.ext.jaxrs.internal.provider.JaxbElementProvider.writeTo()

                return null;
            }
        };
        JAXBElement<Person> jaxbElement = new JAXBElement<Person>(new QName(
                "xyz"), Person.class, person);
        jaxbElementProvider.writeTo(jaxbElement, Person.class, Person.class,
                null, null, null, System.out);

        String xml = "<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?><person><firstname>vn</firstname><lastname>nn</lastname></person>";

        Type type = new ParameterizedType() {
View Full Code Here

Examples of org.springframework.ws.WebServiceMessage.writeTo()

            WebServiceMessage webServiceResponse = messageFactory.createWebServiceMessage();
            marshaller.marshal(response, webServiceResponse.getPayloadResult());

            ByteArrayOutputStream bos = new ByteArrayOutputStream();
            webServiceResponse.writeTo(bos);

            return MessageBuilder.withPayload(new String(bos.toByteArray())).build();
        } catch (XmlMappingException e) {
            throw new CitrusRuntimeException("Failed to marshal/unmarshal XML", e);
        } catch (IOException e) {
View Full Code Here

Examples of org.springframework.ws.soap.SoapMessage.writeTo()

    public void properties() throws IOException {
        Map<String, ?> properties = Collections.singletonMap(SOAPMessage.WRITE_XML_DECLARATION, "true");
        ((SaajSoapMessageFactory)messageFactory).setMessageProperties(properties);
        SoapMessage soapMessage = (SoapMessage) messageFactory.createWebServiceMessage();
        ByteArrayOutputStream os = new ByteArrayOutputStream();
        soapMessage.writeTo(os);
        String result = os.toString("UTF-8");
        assertTrue("XML declaration not written", result.startsWith("<?xml version=\"1.0\""));
    }

View Full Code Here

Examples of org.springframework.ws.soap.axiom.AxiomSoapMessage.writeTo()

        assertXMLEqual("<root xmlns='http://springframework.org'><string>Foo</string></root>",
                payloadResult.toString());

        ByteArrayOutputStream bos = new ByteArrayOutputStream();
        response.writeTo(bos);
        String messageResult = bos.toString("UTF-8");
       
        assertXMLEqual("<soapenv:Envelope xmlns:soapenv='http://schemas.xmlsoap.org/soap/envelope/'><soapenv:Body>" +
                "<root xmlns='http://springframework.org'><string>Foo</string></root>" +
                "</soapenv:Body></soapenv:Envelope>", messageResult);
View Full Code Here

Examples of org.springframework.ws.soap.saaj.SaajSoapMessage.writeTo()

        SOAPHeaderElement securityHeader = (SOAPHeaderElement) iterator.next();
        iterator = securityHeader.getChildElements(new QName("http://www.w3.org/2000/09/xmldsig#", "Signature"));
        assertTrue("No signature header", iterator.hasNext());

        ByteArrayOutputStream bos = new ByteArrayOutputStream();
        message.writeTo(bos);

        MimeHeaders mimeHeaders = new MimeHeaders();
        mimeHeaders.addHeader("Content-Type", "text/xml");
        ByteArrayInputStream bis = new ByteArrayInputStream(bos.toByteArray());
View Full Code Here

Examples of org.strecks.holidaybooking.web.struts.form.HolidayBookingForm.writeTo()

      HolidayBookingService holidayBookingService = (HolidayBookingService) getWebApplicationContext().getBean(
          "holidayBookingService");

      HolidayBooking holidayBooking = new HolidayBooking();
      holidayBookingForm.writeTo(holidayBooking);

      holidayBookingService.addHolidayBooking(holidayBooking);

      request.setAttribute("displayMessage", "Successfully added entry: " + holidayBooking.getTitle());
    }
View Full Code Here

Examples of org.tmatesoft.svn.core.internal.server.dav.DAVResource.writeTo()

                SVNErrorManager.error(SVNErrorMessage.create(SVNErrorCode.RA_DAV_REQUEST_FAILED, e), e, SVNLogType.NETWORK);
            }
        } else if (resource.getDeltaBase() != null) {
            //Here we should send SVN delta (for old clients)
        } else {
            resource.writeTo(getResponseOutputStream());
        }
    }

    protected DAVRequest getDAVRequest() {
        return null;
View Full Code Here

Examples of org.tmatesoft.svn.core.io.diff.SVNDiffInstruction.writeTo()

   
        for(Iterator instructions = myWindow.instructions(true); instructions.hasNext();) {
            SVNDiffInstruction instruction = (SVNDiffInstruction) instructions.next();
            if (instruction.type != SVNDiffInstruction.COPY_FROM_SOURCE) {
                myNextWindowInstructions = ensureBufferSize(myNextWindowInstructions, 10);
                instruction.writeTo(myNextWindowInstructions);
                if (instruction.type == SVNDiffInstruction.COPY_FROM_NEW_DATA) {
                    myNextWindowData = ensureBufferSize(myNextWindowData, instruction.length);
                    myWindow.writeNewData(myNextWindowData, instruction.offset, instruction.length);
                }
            } else {
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.