Package org.jdom

Examples of org.jdom.DefaultJDOMFactory.element()


     */
    @Test
    public void testEditingParameter() {
        JDOMFactory factory = new DefaultJDOMFactory();
        Element request = factory.element("request");
        Element editing = factory.element("_operation2").addContent("1 or 2 or 3");
        request.addContent(editing);
        LuceneQueryInput lQI = new LuceneQueryInput(request);
        Query query = new LuceneQueryBuilder(_tokenizedFieldSet, _numericFieldSet, _analyzer, null).build(lQI);
        assertTrue(query.toString().contains("+(_op2:1 _op2:2 _op2:3)"));
    }   
View Full Code Here


     * No operation parameter.
     */
    @Test
    public void testWithoutOperationParameter() {
        JDOMFactory factory = new DefaultJDOMFactory();
        Element request = factory.element("request");
        LuceneQueryInput lQI = new LuceneQueryInput(request);
        Query query = new LuceneQueryBuilder(_tokenizedFieldSet, _numericFieldSet, _analyzer, null).build(lQI);
        assertTrue(query.toString().equals("+_isTemplate:n"));
    }
}
View Full Code Here

     */
    @Test
    public void testDateToFrom() {
        // create request object
        JDOMFactory factory = new DefaultJDOMFactory();
        Element request = factory.element("request");
        Element any = factory.element("dateTo");
        any.addContent("12-05-1989");
        request.addContent(any);
        Element any2 = factory.element("dateFrom");
        any2.addContent("11-05-1989");
View Full Code Here

    @Test
    public void testDateToFrom() {
        // create request object
        JDOMFactory factory = new DefaultJDOMFactory();
        Element request = factory.element("request");
        Element any = factory.element("dateTo");
        any.addContent("12-05-1989");
        request.addContent(any);
        Element any2 = factory.element("dateFrom");
        any2.addContent("11-05-1989");
        request.addContent(any2);
View Full Code Here

        JDOMFactory factory = new DefaultJDOMFactory();
        Element request = factory.element("request");
        Element any = factory.element("dateTo");
        any.addContent("12-05-1989");
        request.addContent(any);
        Element any2 = factory.element("dateFrom");
        any2.addContent("11-05-1989");
        request.addContent(any2);
        // build lucene query input
        LuceneQueryInput lQI = new LuceneQueryInput(request);
        // build lucene query
View Full Code Here

     */
    @Test
    public void testSource() {
        // create request object
        JDOMFactory factory = new DefaultJDOMFactory();
        Element request = factory.element("request");
        Element any = factory.element("siteId");
        any.addContent("f74e4ccf-755a-48ef-bedf-990f9872298b");
        request.addContent(any);
        // build lucene query input
        LuceneQueryInput lQI = new LuceneQueryInput(request);
View Full Code Here

    @Test
    public void testSource() {
        // create request object
        JDOMFactory factory = new DefaultJDOMFactory();
        Element request = factory.element("request");
        Element any = factory.element("siteId");
        any.addContent("f74e4ccf-755a-48ef-bedf-990f9872298b");
        request.addContent(any);
        // build lucene query input
        LuceneQueryInput lQI = new LuceneQueryInput(request);
        // build lucene query
View Full Code Here

     */
    @Test
    public void testTitle() {
        // create request object
        JDOMFactory factory = new DefaultJDOMFactory();
        Element request = factory.element("request");
        Element any = factory.element("title");
        any.addContent("humph");
        request.addContent(any);
        // build lucene query input
        LuceneQueryInput lQI = new LuceneQueryInput(request);
View Full Code Here

    @Test
    public void testTitle() {
        // create request object
        JDOMFactory factory = new DefaultJDOMFactory();
        Element request = factory.element("request");
        Element any = factory.element("title");
        any.addContent("humph");
        request.addContent(any);
        // build lucene query input
        LuceneQueryInput lQI = new LuceneQueryInput(request);
        // build lucene query
View Full Code Here

     */ 
    @Test
    public void testAltTitle() { 
        // create request object 
        JDOMFactory factory = new DefaultJDOMFactory()
        Element request = factory.element("request")
        Element altTitle = factory.element("altTitle")
        altTitle.addContent("humph")
        request.addContent(altTitle)
        // build lucene query input 
        LuceneQueryInput lQI = new LuceneQueryInput(request)
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.