Package org.apache.syncope.core.persistence.beans.conf

Examples of org.apache.syncope.core.persistence.beans.conf.CAttr.addValue()


        userController.create(userTO, true);

        // 3. Set number of retries
        CAttr maxRetries = confDAO.find("notification.maxRetries", "5");
        maxRetries.getValues().clear();
        maxRetries.addValue("5", AttributableUtil.getInstance(AttributableType.CONFIGURATION));
        confDAO.save(maxRetries);
        confDAO.flush();

        // 4. Stop mail server to force error sending mail
        stopGreenMail();
View Full Code Here


        startGreenMail();

        // 8. reset number of retries
        maxRetries = confDAO.find("notification.maxRetries", "5");
        maxRetries.getValues().clear();
        maxRetries.addValue("0", AttributableUtil.getInstance(AttributableType.CONFIGURATION));
        confDAO.save(maxRetries);
        confDAO.flush();
    }

    @Test
View Full Code Here

        useless = schemaDAO.save(useless);

        // 2. create conf
        CAttr newConf = new CAttr();
        newConf.setSchema(useless);
        newConf.addValue("2014-06-20", AttributableUtil.getInstance(AttributableType.CONFIGURATION));
        confDAO.save(newConf);

        CAttr actual = confDAO.find("useless");
        assertEquals(actual.getValuesAsStrings(), newConf.getValuesAsStrings());
View Full Code Here

        CAttr result = find(key);
        if (result == null) {
            result = new CAttr();
            result.setSchema(schemaDAO.find(key, CSchema.class));

            result.addValue(defaultValue, AttributableUtil.getInstance(AttributableType.CONFIGURATION));
        }

        return result;
    }
View Full Code Here

            final CAttr confAttr = new CAttr();
            confAttr.setSchema(confSchema);
            confAttr.setOwner(confDAO.get());
            if (confSchema.isMultivalue()) {
                for (String singleValue : value.split("|")) {
                    confAttr.addValue(singleValue, AttributableUtil.getInstance(AttributableType.CONFIGURATION));
                }
            } else {
                confAttr.addValue(value, AttributableUtil.getInstance(AttributableType.CONFIGURATION));
            }
            confDAO.save(confAttr);
View Full Code Here

            if (confSchema.isMultivalue()) {
                for (String singleValue : value.split("|")) {
                    confAttr.addValue(singleValue, AttributableUtil.getInstance(AttributableType.CONFIGURATION));
                }
            } else {
                confAttr.addValue(value, AttributableUtil.getInstance(AttributableType.CONFIGURATION));
            }
            confDAO.save(confAttr);
        }
    }
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.