Package net.sf.pmr.keopsframework.domain.object

Examples of net.sf.pmr.keopsframework.domain.object.MockDomainObject


       
        // initialized calendar
        calendar = GregorianCalendar.getInstance();
       
        // mock domain object
        mockDomainObject = new MockDomainObject();
       
        // instanciate temporal map
        temporalDomainMap = new BasicTemporalDomainMapImpl(new HashMap(), mockDomainObject);
       
    }
View Full Code Here


        // date
        calendar.set(Calendar.MILLISECOND, calendar.get(Calendar.MILLISECOND) + 1);
        Date date = calendar.getTime();
       
        MockDomainObject mockDomainObject1 = new MockDomainObject();
        MockDomainObject mockDomainObject2 = new MockDomainObject();

        temporalDomainMap.putVersion(date, mockDomainObject1);
       
        temporalDomainMap.putVersion(date, mockDomainObject2);
       
View Full Code Here

        //date
        calendar.set(Calendar.MILLISECOND, calendar.get(Calendar.MILLISECOND) + 1);
        Date date = calendar.getTime();
       
        // domainOject
        MockDomainObject mockDomainObject = new MockDomainObject();
       
        temporalDomainMap.putVersion(date,mockDomainObject);
       
        assertEquals("putVersion", 2, temporalDomainMap.getMap().size());
       
View Full Code Here

        calendar.set(Calendar.MILLISECOND, calendar.get(Calendar.MILLISECOND) + 1);
       
        Date date = calendar.getTime();
       
        MockDomainObject mockDomainObject = new MockDomainObject();
       
        temporalDomainMap.putVersion(date, mockDomainObject);
       
        assertEquals("getLatest", mockDomainObject, temporalDomainMap.getLatest());
        assertEquals("getMapSize", 2, temporalDomainMap.getMap().size());
View Full Code Here

        Date date1 = calendar.getTime();
       
        calendar.set(Calendar.MILLISECOND, calendar.get(Calendar.MILLISECOND) + 1);
        Date date2 = calendar.getTime();
       
        MockDomainObject mockDomainObject1 = new MockDomainObject();
        MockDomainObject mockDomainObject2 = new MockDomainObject();
       
        temporalDomainMap.putVersion(date1, mockDomainObject1);
        temporalDomainMap.putVersion(date2, mockDomainObject2);
       
        assertEquals("getLatest", mockDomainObject2, temporalDomainMap.getLatest());
View Full Code Here

        Date date2 = calendar.getTime();

        calendar.set(Calendar.MILLISECOND, calendar.get(Calendar.MILLISECOND) + 1);
        Date date3 = calendar.getTime();
       
        MockDomainObject mockDomainObject1 = new MockDomainObject();
        MockDomainObject mockDomainObject2 = new MockDomainObject();
        MockDomainObject mockDomainObject3 = new MockDomainObject();
       
       
        temporalDomainMap.putVersion(date1, mockDomainObject1);
        temporalDomainMap.putVersion(date2, mockDomainObject2);
        temporalDomainMap.putVersion(date3, mockDomainObject3);
View Full Code Here

    public final void testGetMapAndModifyMap() {
       
        Map map = temporalDomainMap.getMap();
       
        try {
            map.put(new Date(), new MockDomainObject());
            fail("should throw a UnsupportedOperationException");
        } catch (UnsupportedOperationException e) {
        }
       
    }
View Full Code Here

TOP

Related Classes of net.sf.pmr.keopsframework.domain.object.MockDomainObject

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.