Examples of addDocument()


Examples of org.exist.util.ValueOccurrences.addDocument()

                            if( ( lastParentId == null ) || !lastParentId.equals( parentNode.getNodeId() ) ) {
                                oc.addOccurrences( 1 );
                            }

                            if( !docAdded ) {
                                oc.addDocument( storedDocument );
                                docAdded = true;
                            }
                            lastParentId = parentNode.getNodeId();
                        }
                        //TODO : what if contextSet == null ? -pb
View Full Code Here

Examples of org.fenixedu.academic.domain.phd.thesis.PhdThesisProcessBean.addDocument()

        final PhdThesisProcessBean bean = new PhdThesisProcessBean(getProcess(request));

        final PhdIndividualProgramProcess individualProcess = getProcess(request);

        if (individualProcess.isMigratedProcess()) {
            bean.addDocument(new PhdProgramDocumentUploadBean(PhdIndividualProgramDocumentType.PROVISIONAL_THESIS));
            bean.addDocument(new PhdProgramDocumentUploadBean(PhdIndividualProgramDocumentType.THESIS_ABSTRACT));
        } else {
            bean.addDocument(new PhdProgramDocumentUploadBean(PhdIndividualProgramDocumentType.PROVISIONAL_THESIS).required());
            bean.addDocument(new PhdProgramDocumentUploadBean(PhdIndividualProgramDocumentType.THESIS_ABSTRACT).required());
        }
View Full Code Here

Examples of org.fenixedu.academic.domain.phd.thesis.meeting.PhdMeeting.addDocument()

        final PhdMeetingBean bean = (PhdMeetingBean) object;
        final PhdMeeting meeting = bean.getMeeting();

        final PhdProgramDocumentUploadBean document = bean.getDocument();
        if (document.hasAnyInformation()) {
            meeting.addDocument(document, userView.getPerson());
        }

        if (bean.isToNotify()) {
            /*
             * TODO: (check subject and body) AlertService.alertStudent(process,
View Full Code Here

Examples of org.hibernate.cfg.Configuration.addDocument()

        sessionFactoryElement.addElement("property").addAttribute("name", "hibernate.hbm2ddl.auto").setText(hbm2ddlMode);
        // setup config
        Configuration cfg = new Configuration().configure(new DOMWriter().write(document));
        // add object mappings
        Logger.log(mappingDocument.asXML());
        cfg.addDocument(new DOMWriter().write(mappingDocument));
        sessionFactory = cfg.buildSessionFactory();
      } catch (Exception e) {
        Logger.log(e);
      }
    }
View Full Code Here

Examples of org.hibernate.cfg.annotations.reflection.XMLContext.addDocument()

  }

  protected XMLContext getContext(InputStream is) throws Exception {
    XMLContext xmlContext = new XMLContext();
    Document doc = new SAXReader().read( is );
    xmlContext.addDocument( doc );
    return xmlContext;
  }
}
View Full Code Here

Examples of org.hibernate.reflection.java.xml.XMLContext.addDocument()

      catch (IOException ioe) {
        //log.warn( "Could not close input stream", ioe );
      }
    }
    assertEquals( 0, errors.size() );
    context.addDocument( doc );
  }
}
View Full Code Here

Examples of org.infinispan.schematic.document.EditableArray.addDocument()

        if (jaasPolicyName != null) {
            // Add the JAAS provider ...
            EditableArray providers = security.getOrCreateArray("providers");
            EditableDocument jaas = Schematic.newDocument(FieldName.CLASSNAME, "JAAS", "policyName", "modeshape-jcr");
            providers.addDocument(jaas);
        }

        return doc;
    }
View Full Code Here

Examples of org.internna.iwebmvc.model.MultiDocument.addDocument()

        doc5.setCreation(new Date());
        doc5.setMimeType("image/gif");
        doc5.setAuthor((UserImpl) securityDAO.findUser("adminuser"));
        doc5.setContents(contents);
        SimpleEntity entity = new SimpleEntity("john");
        entity.setPhotos(md.addDocument(doc).addDocument(doc3).addDocument(doc4).addDocument(doc5));
        baseDao.create(entity);
        assertNotNull(baseDao.first(SimpleEntity.class));
        assertNotNull(baseDao.first(MultiDocument.class));
    }
View Full Code Here

Examples of org.internna.iwebmvc.model.MultiDocument.addDocument()

    @Test
    public void testParseNulls() throws Exception {
        assertNull(multiDocumentParser.parse(null));
        MultiDocument md = new MultiDocument();
        assertNull(multiDocumentParser.parse(md));
        md.addDocument(new Document());
        md.addDocument(new Document());
        assertNull(multiDocumentParser.parse(md));
        SimpleEntity entity = baseDao.first(SimpleEntity.class);
        md = baseDao.first(MultiDocument.class);
        md.removeAll();
View Full Code Here

Examples of org.internna.iwebmvc.model.MultiDocument.addDocument()

    public void testParseNulls() throws Exception {
        assertNull(multiDocumentParser.parse(null));
        MultiDocument md = new MultiDocument();
        assertNull(multiDocumentParser.parse(md));
        md.addDocument(new Document());
        md.addDocument(new Document());
        assertNull(multiDocumentParser.parse(md));
        SimpleEntity entity = baseDao.first(SimpleEntity.class);
        md = baseDao.first(MultiDocument.class);
        md.removeAll();
        MultiDocument parsed = multiDocumentParser.parse(md);
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.