Package model.entities

Examples of model.entities.CCouple


    @Before
    public void setUp() throws Exception {
        p1 = new CPerson("zach", 22, ESex.Male);
        p2 = new CPerson("katie", 20, ESex.Female);
        couple = new CCouple(p1, p2);
    }
View Full Code Here


    @Before
    public void setUp() throws Exception {
        registry = new MarriageRegistry();
        p1 = new CPerson("zach", 22, ESex.Male);
        p2 = new CPerson("katie", 20, ESex.Female);
        couple1 = new CCouple(p1, p2);
    }
View Full Code Here

     * @TODO - complicated logic, consider cleaning up or extracting functions
     */
    public boolean addCouple(CPerson p1, CPerson p2) {
        // If neither person is married to someone else, or each other, AND they are over 18
        if(isCoupleMarriageEligible(p1, p2)) {
            CCouple coupleToAdd = new CCouple(p1, p2);
            registry.add(coupleToAdd);
            System.out.println("Couple added to registry.");
            return true;
        }
        // Else one of them were married
View Full Code Here

TOP

Related Classes of model.entities.CCouple

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.