From: <die...@us...> - 2010-05-13 10:01:03
|
Revision: 2440 http://openutils.svn.sourceforge.net/openutils/?rev=2440&view=rev Author: diego_schivo Date: 2010-05-13 10:00:56 +0000 (Thu, 13 May 2010) Log Message: ----------- CRIT-11 CriteriaTest Modified Paths: -------------- trunk/openutils-mgnlcriteria/src/test/java/net/sourceforge/openutils/mgnlcriteria/jcr/query/CriteriaTest.java Added Paths: ----------- trunk/openutils-mgnlcriteria/src/test/resources/crit-bootstrap/website.pets.xml Modified: trunk/openutils-mgnlcriteria/src/test/java/net/sourceforge/openutils/mgnlcriteria/jcr/query/CriteriaTest.java =================================================================== --- trunk/openutils-mgnlcriteria/src/test/java/net/sourceforge/openutils/mgnlcriteria/jcr/query/CriteriaTest.java 2010-05-13 08:57:25 UTC (rev 2439) +++ trunk/openutils-mgnlcriteria/src/test/java/net/sourceforge/openutils/mgnlcriteria/jcr/query/CriteriaTest.java 2010-05-13 10:00:56 UTC (rev 2440) @@ -1,14 +1,36 @@ +/** + * + * Magnolia Criteria API (http://www.openmindlab.com/lab/products/mgnlcriteria.html) + * Copyright(C) 2009-2010, Openmind S.r.l. http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + */ + package net.sourceforge.openutils.mgnlcriteria.jcr.query; import info.magnolia.cms.beans.config.ContentRepository; +import info.magnolia.context.MgnlContext; import java.util.Calendar; import net.sourceforge.openutils.mgnlcriteria.jcr.query.criterion.Order; import net.sourceforge.openutils.mgnlcriteria.jcr.query.criterion.Restrictions; +import net.sourceforge.openutils.mgnlcriteria.tests.RepositoryTestNgTestcase; import org.apache.commons.lang.StringUtils; import org.testng.Assert; +import org.testng.annotations.BeforeClass; import org.testng.annotations.Test; @@ -16,34 +38,135 @@ * @author dschivo * @version $Id$ */ -public class CriteriaTest +public class CriteriaTest extends RepositoryTestNgTestcase { + /** + * {@inheritDoc} + */ + @Override + @BeforeClass + protected void setUp() throws Exception + { + setRepositoryConfigFileName("/crit-repository/test-repositories.xml"); + setJackrabbitRepositoryConfigFileName("/crit-repository/jackrabbit-test-configuration.xml"); + + super.setUp(); + + // Nodes in this workspace: + // - pets (title=Pets) + // --- 1 (title=Leo, petType=cat, birthDate=2000-09-07) + // --- 2 (title=Basil, petType=hamster, birthDate=2002-08-06) + // --- 3 (title=Rosy, petType=dog, birthDate=2001-04-17) + // --- 4 (title=Jewel, petType=dog, birthDate=2000-03-07) + // --- 5 (title=Iggy, petType=lizard, birthDate=2000-11-30) + // --- 6 (title=George, petType=snake, birthDate=2000-01-20) + // --- 7 (title=Samantha, petType=cat, birthDate=1995-09-04) + // --- 8 (title=Max, petType=cat, birthDate=1995-09-04) + // --- 9 (title=Lucky, petType=bird, birthDate=1999-08-06) + // --- 10 (title=Mulligan, petType=dog, birthDate=1997-02-24) + // --- 11 (title=Freddy, petType=bird, birthDate=2000-03-09) + // --- 12 (title=Lucky, petType=dog, birthDate=2000-06-24) + // --- 13 (title=Sly, petType=cat, birthDate=2002-06-08) + bootstrapSingleResource("/crit-bootstrap/website.pets.xml"); + MgnlContext.getHierarchyManager(ContentRepository.WEBSITE).save(); + } + + /** + * Tests the xpath query statement produced by a Criteria instance. + * @throws Exception + */ @Test public void testToXpathExpression() throws Exception { + Criteria criteria = javadocXpathExampleCriteria(); + + String expectedStmt = "//pets//*" + + "[((jcr:contains(@title, 'Lucky')) and (@petType='dog')" + + " and (@birthDate >=xs:dateTime('1999-01-01T00:00:00.000+00:00')" + + " and @birthDate <=xs:dateTime('2001-12-31T23:59:59.000+00:00')))]" + + " order by @title descending"; + String actualStmt = criteria.toXpathExpression(); + Assert.assertEquals(StringUtils.remove(expectedStmt, ' '), StringUtils.remove(actualStmt, ' ')); + } + + /** + * Tests the query execution of a Criteria instance. + * @throws Exception + */ + @Test + public void testExecute() throws Exception + { + Criteria criteria = javadocXpathExampleCriteria(); + + AdvancedResult result = criteria.execute(); + Assert.assertEquals(1, result.getTotalSize()); + + ResultIterator<AdvancedResultItem> iterator = result.getItems(); + Assert.assertEquals(1, iterator.getSize()); + Assert.assertEquals("12", iterator.next().getName()); + } + + /** + * Tests pagination of results. + * @throws Exception + */ + @Test + public void testSetPaging() throws Exception + { + Criteria criteria = javadocPaginationExampleCriteria(); + + AdvancedResult result = criteria.execute(); + // first page: + // --- 9 (title=Lucky, petType=bird, birthDate=1999-08-06) + // --- 6 (title=George, petType=snake, birthDate=2000-01-20) + // --- 4 (title=Jewel, petType=dog, birthDate=2000-03-07) + // --- 11 (title=Freddy, petType=bird, birthDate=2000-03-09) + // --- 12 (title=Lucky, petType=dog, birthDate=2000-06-24) + // second page: + // --- 1 (title=Leo, petType=cat, birthDate=2000-09-07) + // --- 5 (title=Iggy, petType=lizard, birthDate=2000-11-30) + // --- 3 (title=Rosy, petType=dog, birthDate=2001-04-17) + Assert.assertEquals(8, result.getTotalSize()); + + ResultIterator<AdvancedResultItem> iterator = result.getItems(); + Assert.assertEquals(3, iterator.getSize()); + Assert.assertEquals("1", iterator.next().getName()); + Assert.assertEquals("5", iterator.next().getName()); + Assert.assertEquals("3", iterator.next().getName()); + } + + /** + * @return + */ + private Criteria javadocXpathExampleCriteria() + { Calendar begin = Calendar.getInstance(); - begin.set(2004, Calendar.JANUARY, 1); + begin.set(1999, Calendar.JANUARY, 1); Calendar end = Calendar.getInstance(); - end.set(2008, Calendar.DECEMBER, 1); + end.set(2001, Calendar.DECEMBER, 31); - Criteria criteria = JCRCriteriaFactory - .createCriteria() - .setWorkspace(ContentRepository.WEBSITE) - .setBasePath("/dogs") - .add(Restrictions.contains("@name", "Nana")) - .add(Restrictions.gt("@weight", Float.valueOf(10))) - .add(Restrictions.between("@birthDate", begin, end)) - .addOrder(Order.desc("@name")); + Criteria criteria = JCRCriteriaFactory.createCriteria().setWorkspace(ContentRepository.WEBSITE).setBasePath( + "/pets").add(Restrictions.contains("@title", "Lucky")).add(Restrictions.eq("@petType", "dog")).add( + Restrictions.between("@birthDate", begin, end)).addOrder(Order.desc("@title")); + return criteria; + } - String expectedStmt = "//dogs//*" - + "[((jcr:contains(@name, 'Nana')) and (@weight>10.0)" - + " and (@birthDate >=xs:dateTime('2004-01-01T00:00:00.000+00:00')" - + " and @birthDate <=xs:dateTime('2008-12-01T23:59:59.000+00:00')))]" - + " order by @name descending"; - String actualStmt = criteria.toXpathExpression(); + /** + * @return + */ + private Criteria javadocPaginationExampleCriteria() + { + Calendar begin = Calendar.getInstance(); + begin.set(1999, Calendar.JANUARY, 1); + Calendar end = Calendar.getInstance(); + end.set(2001, Calendar.DECEMBER, 31); - Assert.assertEquals(StringUtils.remove(expectedStmt, ' '), StringUtils.remove(actualStmt, ' ')); + Criteria criteria = JCRCriteriaFactory.createCriteria().setWorkspace(ContentRepository.WEBSITE).setBasePath( + "/pets").add(Restrictions.between("@birthDate", begin, end)).addOrder(Order.asc("@birthDate")).setPaging( + 5, + 2); + return criteria; } } Added: trunk/openutils-mgnlcriteria/src/test/resources/crit-bootstrap/website.pets.xml =================================================================== --- trunk/openutils-mgnlcriteria/src/test/resources/crit-bootstrap/website.pets.xml (rev 0) +++ trunk/openutils-mgnlcriteria/src/test/resources/crit-bootstrap/website.pets.xml 2010-05-13 10:00:56 UTC (rev 2440) @@ -0,0 +1,597 @@ +<?xml version="1.0" encoding="UTF-8"?> +<sv:node sv:name="pets" xmlns:sv="http://www.jcp.org/jcr/sv/1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>e05cd53d-ed9e-4a99-b41c-c305cea9a8e9</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Pets</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:04:10.640+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:04:22.468+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + <sv:node sv:name="1"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>0c915103-28a5-4002-b9a2-8b5fdbc0c7e4</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>2000-09-07T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>cat</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Leo</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:05:09.609+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:10:52.031+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="2"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>355b0eb3-a393-48b1-9fb7-6319f49a0fcb</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>2002-08-06T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>hamster</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Basil</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:05:32.390+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:11:10.218+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="3"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>55aaaba2-7835-42e1-8369-ef26e7c33914</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>2001-04-17T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>dog</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Rosy</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:05:40.234+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:11:26.234+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="4"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>a7614d0b-51d8-47c4-99ef-7d52444c74de</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>2000-03-07T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>dog</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Jewel</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:05:50.156+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:11:39.921+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="5"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>26da71db-352b-4e30-8032-d9f727511fdd</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>2000-11-30T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>lizard</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Iggy</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:06:00.406+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:11:55.828+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="6"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>f4066b54-df95-47b1-8fe2-40995c853934</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>2000-01-20T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>snake</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>George</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:06:09.531+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:12:11.015+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="7"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>9635dc78-b4b0-49d1-ae65-c937b34f2430</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>1995-09-04T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>cat</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Samantha</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:06:18.515+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:12:35.937+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="8"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>a7d2bf68-7a72-4843-9bd0-b851d92d250e</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>1995-09-04T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>cat</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Max</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:06:27.000+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:12:49.000+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="9"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>2cd9a5a2-3a82-484c-b361-e972b90e9c61</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>1999-08-06T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>bird</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Lucky</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:06:35.437+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:13:03.250+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="10"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>c3f7f93c-26e0-4207-a3ec-6c809c904406</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>1997-02-24T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>dog</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Mulligan</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:06:46.156+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:13:16.859+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="11"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>a8dfc666-08d1-4fa6-9325-ac26b45fd13a</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>2000-03-09T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>bird</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Freddy</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:06:56.718+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:13:32.812+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="12"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>e5507eef-bb85-46ee-a89e-c32daff74c8e</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>2000-06-24T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>dog</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Lucky</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:07:06.703+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:13:49.703+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="13"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>d45699bc-f4c9-4b36-98dc-513eb28c82b8</sv:value> + </sv:property> + <sv:property sv:name="birthDate" sv:type="Date"> + <sv:value>2002-06-08T00:00:00.000+00:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="petType" sv:type="String"> + <sv:value>cat</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Sly</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-05-13T11:07:21.421+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2010-05-13T11:14:13.578+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>plaintext</sv:value> + </sv:property> + </sv:node> + </sv:node> +</sv:node> Property changes on: trunk/openutils-mgnlcriteria/src/test/resources/crit-bootstrap/website.pets.xml ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |