Package org.apache.cayenne.testdo.testmap

Examples of org.apache.cayenne.testdo.testmap.ArraysEntity


        test.setCharArray(null);
        context.commitChanges();
    }

    public void testCharacterArray() {
        ArraysEntity test = context.newObject(ArraysEntity.class);

        Character[] a = new Character[] {
                new Character('x'), new Character('y'), new Character('z')
        };
        test.setCharWrapperArray(a);
        context.commitChanges();

        SelectQuery q = new SelectQuery(ArraysEntity.class);
        ArraysEntity testRead = (ArraysEntity) context.performQuery(q).get(0);
        assertNotNull(testRead.getCharWrapperArray());
        assertArraysEqual(a, testRead.getCharWrapperArray());

        test.setCharWrapperArray(null);
        context.commitChanges();
    }
View Full Code Here


        test.setCharacterField(null);
        context.commitChanges();
    }

    public void testByteWrapperArray() {
        ArraysEntity test = context.newObject(ArraysEntity.class);

        Byte[] a = new Byte[] {
                new Byte((byte) 1), new Byte((byte) 2), new Byte((byte) 3)
        };
        test.setByteWrapperArray(a);
        context.commitChanges();

        SelectQuery q = new SelectQuery(ArraysEntity.class);
        ArraysEntity testRead = (ArraysEntity) context.performQuery(q).get(0);
        assertNotNull(testRead.getByteWrapperArray());
        assertArraysEqual(a, testRead.getByteWrapperArray());

        test.setByteWrapperArray(null);
        context.commitChanges();
    }
View Full Code Here

TOP

Related Classes of org.apache.cayenne.testdo.testmap.ArraysEntity

Copyright © 2018 www.massapicom. 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.