Package org.dddlib.organisation.domain

Examples of org.dddlib.organisation.domain.OrgLineMgmt


    @Override
    public void createOrganization(Organization orgToCreate,
                                   Organization parent, Date date) {
        orgToCreate.setCreateDate(date);
        orgToCreate.save();
        new OrgLineMgmt(parent, orgToCreate, date).save();
    }
View Full Code Here


    @Override
    public void changeParentOfOrganization(Organization organization,
                                           Organization newParent, Date date) {
        OrgLineMgmt.getByResponsible(organization, date).terminate(date);
        new OrgLineMgmt(newParent, organization, date).save();
    }
View Full Code Here

        Organization parent = new Company("headquarter");
        Date date = DateUtils.date(2012, 1, 1);
        instance.createOrganization(orgToCreate, parent, date);
        assertThat(orgToCreate.getCreateDate(), is(date));
        verify(repository).save(orgToCreate);
        verify(repository).save(new OrgLineMgmt(parent, orgToCreate, date));
    }
View Full Code Here

TOP

Related Classes of org.dddlib.organisation.domain.OrgLineMgmt

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.