Package org.jabusuite.core.utils

Examples of org.jabusuite.core.utils.UserNumber


    public void init() {
        // Nothing to do for now
    }

    public String getNextNumber(String name, JbsCompany company) {
        UserNumber number = this.getUserNumber(name, company);
        if (number == null) {
            number = createNumber(name, company);
        }
        return number.getValue();
    }
View Full Code Here


    public UserNumber createNumber(String name, JbsCompany company) {
        if (logger.isDebugEnabled()) {
            logger.debug("Creating new user-number: " + name);
        }
        UserNumber number = new UserNumber();
        number.setName(name);
        number.setValue("1");
        number.setCreated(new Date());
        number.setCompany(company);
        this.createDataset(number, company);
        return number;
    }
View Full Code Here

        }
    }
   

    public void setNumber(String name, String value, JbsCompany company) {
        UserNumber number = this.getUserNumber(name, company);
        if (number == null) {
            number = createNumber(name, company);
        }
        number.setValue(value);
        this.updateDataset(number, company);
    }
View Full Code Here

TOP

Related Classes of org.jabusuite.core.utils.UserNumber

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.