Examples of makeAndPersist()


Examples of com.github.huangp.entityunit.entity.EntityMaker.makeAndPersist()

                        .addFieldOrPropertyMaker(HAccount.class,
                                "passwordHash",
                                FixedValueMaker.fix(passwordHash))
                        .addFieldOrPropertyMaker(HAccount.class, "apiKey",
                                FixedValueMaker.fix(apiKey)).build();
        return maker.makeAndPersist(entityManager, HAccount.class,
                new FixIdCallback(HAccount.class, accountId));
    }

    public void makeSampleProject() {
        EntityMaker maker =
View Full Code Here

Examples of com.github.huangp.entityunit.entity.EntityMaker.makeAndPersist()

                                FixedValueMaker.EMPTY_STRING_MAKER)
                        .addConstructorParameterMaker(HDocument.class, 3,
                                FixedValueMaker.fix(ContentType.PO))
                        .reuseEntity(enUSLocale).build();

        maker.makeAndPersist(entityManager, HTextFlowTarget.class,
                Callbacks.wireManyToMany(HProject.class, admin));

    }

}
View Full Code Here

Examples of com.github.huangp.entityunit.entity.EntityMaker.makeAndPersist()

    @PerformanceProfiling
    public void pushTranslation() {
        EntityMaker entityMaker = EntityMakerBuilder.builder()
                .addFieldOrPropertyMaker(HProject.class, "sourceViewURL",
                        FixedValueMaker.EMPTY_STRING_MAKER).build();
        HProjectIteration iteration = entityMaker
                .makeAndPersist(getEm(), HProjectIteration.class);
        HLocale srcLocale = createAndPersistLocale(LocaleId.EN_US, getEm());
        HLocale transLocale = createAndPersistLocale(LocaleId.DE, getEm());

        String versionSlug = iteration.getSlug();
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.