Examples of Aaa


Examples of org.slim3.datastore.model.Aaa

    /**
     * @throws Exception
     */
    @Test
    public void nextForPolyModel() throws Exception {
        DatastoreUtil.put(ds, null, aaaMeta.modelToEntity(new Aaa()));
        DatastoreUtil.put(ds, null, bbbMeta.modelToEntity(new Bbb()));

        EntityQuery query = new EntityQuery(ds, "Aaa");
        Iterator<Entity> entityIterator = query.asIterator();
        ModelIterator<Aaa> modelIterator =
View Full Code Here

Examples of org.slim3.datastore.model.Aaa

    /**
     * @throws Exception
     */
    @Test
    public void asListForPolyModel() throws Exception {
        DatastoreUtil.put(ds, null, AaaMeta.get().modelToEntity(new Aaa()));
        DatastoreUtil.put(ds, null, BbbMeta.get().modelToEntity(new Bbb()));
        DatastoreUtil.put(ds, null, CccMeta.get().modelToEntity(new Ccc()));

        ModelQuery<Aaa> query = new ModelQuery<Aaa>(ds, aaaMeta);
        List<Aaa> list = query.asList();
View Full Code Here

Examples of org.slim3.datastore.model.Aaa

    /**
     * @throws Exception
     */
    @Test
    public void asKeyListForPolyModel() throws Exception {
        DatastoreUtil.put(ds, null, AaaMeta.get().modelToEntity(new Aaa()));
        DatastoreUtil.put(ds, null, BbbMeta.get().modelToEntity(new Bbb()));

        ModelQuery<Aaa> query = new ModelQuery<Aaa>(ds, aaaMeta);
        List<Key> list = query.asKeyList();
        assertThat(list.size(), is(2));
View Full Code Here

Examples of org.slim3.datastore.model.Aaa

    /**
     * @throws Exception
     */
    @Test
    public void asIteratorForPolyModel() throws Exception {
        DatastoreUtil.put(ds, null, AaaMeta.get().modelToEntity(new Aaa()));
        DatastoreUtil.put(ds, null, BbbMeta.get().modelToEntity(new Bbb()));
        DatastoreUtil.put(ds, null, CccMeta.get().modelToEntity(new Ccc()));

        ModelQuery<Aaa> query = new ModelQuery<Aaa>(ds, aaaMeta);
        Iterator<Aaa> iterator = query.asIterator();
View Full Code Here

Examples of org.slim3.datastore.model.Aaa

    /**
     * @throws Exception
     */
    @Test
    public void minForPolyModel() throws Exception {
        Aaa aaa = new Aaa();
        aaa.setVersion(1L);
        Bbb bbb = new Bbb();
        bbb.setVersion(2L);
        DatastoreUtil.put(ds, null, DatastoreUtil.modelToEntity(ds, aaa));
        DatastoreUtil.put(ds, null, DatastoreUtil.modelToEntity(ds, bbb));

View Full Code Here

Examples of org.slim3.datastore.model.Aaa

    /**
     * @throws Exception
     */
    @Test
    public void maxForPolyModel() throws Exception {
        Aaa aaa = new Aaa();
        aaa.setVersion(2L);
        Bbb bbb = new Bbb();
        bbb.setVersion(1L);
        DatastoreUtil.put(ds, null, DatastoreUtil.modelToEntity(ds, aaa));
        DatastoreUtil.put(ds, null, DatastoreUtil.modelToEntity(ds, bbb));

View Full Code Here

Examples of org.slim3.datastore.model.Aaa

    /**
     * @throws Exception
     */
    @Test
    public void countForPolyModel() throws Exception {
        DatastoreUtil.put(ds, null, DatastoreUtil.modelToEntity(ds, new Aaa()));
        DatastoreUtil.put(ds, null, DatastoreUtil.modelToEntity(ds, new Bbb()));

        ModelQuery<Aaa> query = new ModelQuery<Aaa>(ds, aaaMeta);
        assertThat(query.count(), is(2));

View Full Code Here

Examples of org.slim3.util.aaa.Aaa

     *
     * @throws Exception
     */
    @Test
    public void getValueForNonPublicClass() throws Exception {
        Aaa aaa = AaaFactory.newInstance();
        aaa.setAaa("111");
        PropertyDesc pd = new PropertyDesc("aaa", String.class, aaa.getClass());
        Method m = aaa.getClass().getMethod("getAaa");
        pd.setReadMethod(m);
        assertThat((String) pd.getValue(aaa), is("111"));
    }
View Full Code Here

Examples of org.slim3.util.aaa.Aaa

     *
     * @throws Exception
     */
    @Test
    public void setValueForNonPublicClass() throws Exception {
        Aaa aaa = AaaFactory.newInstance();
        PropertyDesc pd = new PropertyDesc("aaa", String.class, aaa.getClass());
        Method m = aaa.getClass().getMethod("setAaa", String.class);
        pd.setWriteMethod(m);
        pd.setValue(aaa, "111");
        assertThat(aaa.getAaa(), is("111"));
    }
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.