Examples of toDocument()


Examples of com.github.rnewson.couchdb.lucene.rhino.RhinoDocument.toDocument()

            return NO_DOCUMENTS;
        }

        if (result instanceof RhinoDocument) {
            final RhinoDocument rhinoDocument = (RhinoDocument) result;
            final Document document = rhinoDocument.toDocument(doc.getId(), defaults, database);
            return Collections.singleton(document);
        }

        if (result instanceof NativeArray) {
            final NativeArray nativeArray = (NativeArray) result;
View Full Code Here

Examples of com.github.rnewson.couchdb.lucene.rhino.RhinoDocument.toDocument()

            final NativeArray nativeArray = (NativeArray) result;
            final Collection<Document> arrayResult = new ArrayList<Document>((int) nativeArray.getLength());
            for (int i = 0; i < (int) nativeArray.getLength(); i++) {
                if (nativeArray.get(i, null) instanceof RhinoDocument) {
                    final RhinoDocument rhinoDocument = (RhinoDocument) nativeArray.get(i, null);
                    final Document document = rhinoDocument.toDocument(
                            doc.getId(),
                            defaults,
                            database);
                    arrayResult.add(document);
                }
View Full Code Here

Examples of dk.brics.xact.XML.toDocument()

        response.setCharacterEncoding(CHARSET);
        ServletOutputStream servletOutputStream = response.getOutputStream();
        XML xml = getXML();
        ByteArrayOutputStream w = new ByteArrayOutputStream();
        boolean hack = status != HttpServletResponse.SC_OK; // hack to disable IE "friendly error messages" :-(
        xml.toDocument(w, CHARSET);
        int length = w.size();
        if (hack) {
            length += blank.length;
        }
        response.setContentLength(length);
View Full Code Here

Examples of org.apache.roller.weblogger.webservices.adminprotocol.sdk.MemberEntrySet.toDocument()

    }
   
    public void testDocumentMarshal() {
        try {
            MemberEntrySet wes1 = getSampleMemberEntrySet();
            Document d = wes1.toDocument();
           
            MemberEntrySet wes2 = new MemberEntrySet(d, getEndpointUrl());
           
            assertEquals(wes1, wes2);
        } catch (UnexpectedRootElementException uree) {
View Full Code Here

Examples of org.apache.roller.weblogger.webservices.adminprotocol.sdk.UserEntrySet.toDocument()

    }
   
    public void testDocumentMarshal() {
        try {
            UserEntrySet ues1 = getSampleUserEntrySet();
            Document d = ues1.toDocument();
           
            UserEntrySet ues2 = new UserEntrySet(d, getEndpointUrl());
           
            assertEquals(ues1, ues2);
        } catch (UnexpectedRootElementException uree) {
View Full Code Here

Examples of org.apache.roller.weblogger.webservices.adminprotocol.sdk.WeblogEntrySet.toDocument()

    }
   
    public void testDocumentMarshal() {
        try {
            WeblogEntrySet wes1 = getSampleWeblogEntrySet();
            Document d = wes1.toDocument();
           
            WeblogEntrySet wes2 = new WeblogEntrySet(d, getEndpointUrl());
           
            assertEquals(wes1, wes2);
        } catch (UnexpectedRootElementException uree) {
View Full Code Here

Examples of org.apache.xindice.xml.dom.DOMParser.toDocument()

       // Absolute path to the commands.xml file, relative to $XINDICE_HOME
       File xindiceHome =  new File( System.getProperty( Xindice.PROP_XINDICE_HOME ) );
       File commandsFile = new File( xindiceHome, "config/commands.xml" );

       DOMParser parser = new DOMParser();
       commandsDocument = parser.toDocument( new FileInputStream( commandsFile ) );
    }
    /**
     * Carries out the initialization of the Commands List.
     **/
    protected abstract void initCommandsList();
View Full Code Here

Examples of org.jamesii.core.model.symbolic.convert.IConverter.toDocument()

  @Override
  public IDocument<?> getAsDocument(Class<? extends IDocument<?>> targetFormat) {
    try {
      IConverter converter = getConverter(targetFormat);
      return converter.toDocument(this);
    } catch (Exception e) {
      SimSystem.report(e);
    }
    return null;
  }
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.