Package eu.scape_project.planning.bean

Examples of eu.scape_project.planning.bean.PrepareChangesForPersist


    }
    /**
     * Method responsible for persisting the changes.
     */
    public void save(Plan plan, User user) {
        PrepareChangesForPersist prepChanges = new PrepareChangesForPersist(user.getUsername());
        prepChanges.prepare(plan);

        planManager.saveForPlanSettings(plan.getPlanProperties(), plan.getAlternativesDefinition());
    }
View Full Code Here


        step.requiredPlanState = PlanState.CREATED;
        Plan p = new Plan();
        p.getPlanProperties().setState(PlanState.PLAN_VALIDATED);
        step.plan = p;

        PrepareChangesForPersist prepareChangesForPersist = mock(PrepareChangesForPersist.class);
        step.prepareChangesForPersist = prepareChangesForPersist;

        EntityManager em = mock(EntityManager.class);
        when(em.merge(p)).thenReturn(p);
        step.em = em;
View Full Code Here

                            + " (originally created by " + prop.getOwner() + ")");
                        prop.setOwner(newOwner);
                        // mark this plan as a playground copy
                        prop.setPlayground(true);
                        prop.touch();
                        PrepareChangesForPersist prep = new PrepareChangesForPersist(newOwner);
                        prep.prepare(prop);

                        String message = "A copy has been created: <em>"
                            + prop.getName()
                            + " - "
                            + prop.getDescription()
View Full Code Here

TOP

Related Classes of eu.scape_project.planning.bean.PrepareChangesForPersist

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.