Package com.sun.util

Examples of com.sun.util.PrintfFormat


    private static List<StringIdEntity> createTestEntitiesString(int count) {
        List<StringIdEntity> entities = new ArrayList<StringIdEntity>();

        for (int i = 1; i <= count; i++) {
            String id = "entity" + i;
            String milliseconds = new PrintfFormat("%03d").sprintf(i);
            Date timestamp = DateUtils.createDate("2011-06-01T14:00:00." + milliseconds);
            StringIdEntity testEntity = new StringIdEntity(id, timestamp);
            entities.add(testEntity);
        }
View Full Code Here


    private static List<IntegerIdEntity> createTestEntitiesInteger(int count) {
        List<IntegerIdEntity> entities = new ArrayList<IntegerIdEntity>();

        for (int i = 1; i <= count; i++) {
            long id = i;
            String milliseconds = new PrintfFormat("%03d").sprintf(i);
            Date timestamp = DateUtils.createDate("2011-06-01T14:00:00." + milliseconds);
            IntegerIdEntity testEntity = new IntegerIdEntity(id, timestamp);
            entities.add(testEntity);
        }
View Full Code Here

TOP

Related Classes of com.sun.util.PrintfFormat

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.