Package org.apache.syncope.common.to

Examples of org.apache.syncope.common.to.ConfTO


        WebMarkupContainer parameters = new WebMarkupContainer("parameters");
        add(parameters);
        MetaDataRoleAuthorizationStrategy.authorize(parameters, ENABLE, xmlRolesReader.getAllAllowedRoles(
                "Configuration", "list"));

        final ConfTO conf = confRestClient.list();

        final Form<?> form = new Form<Void>("confForm");
        form.setModel(new CompoundPropertyModel(conf));
        parameters.add(form);

        form.add(new AttributesPanel("parameters", conf, form, false));

        IndicatingAjaxLink<Void> save = new IndicatingAjaxLink<Void>("saveParameters") {

            private static final long serialVersionUID = -7978723352517770644L;

            @Override
            public void onClick(final AjaxRequestTarget target) {
                final ConfTO updatedConf = (ConfTO) form.getModelObject();

                try {
                    for (AttributeTO attr : updatedConf.getAttrs()) {
                        if (attr.getValues().isEmpty()
                                || attr.getValues().equals(Collections.singletonList(StringUtils.EMPTY))) {

                            confRestClient.delete(attr.getSchema());
                        } else {
View Full Code Here


        assertEquals(actual, tokenLength);
    }

    @Test
    public void list() {
        ConfTO wholeConf = configurationService.list();
        assertNotNull(wholeConf);
        for (AttributeTO conf : wholeConf.getAttrs()) {
            assertNotNull(conf);
        }
    }
View Full Code Here

@Component
public class ConfigurationDataBinder extends AbstractAttributableDataBinder {

    public ConfTO getConfTO(final SyncopeConf conf) {
        final ConfTO confTO = new ConfTO();
        confTO.setId(conf.getId());

        fillTO(confTO, conf.getAttrs(),
                conf.getDerAttrs(), conf.getVirAttrs(), Collections.<ExternalResource>emptySet());

        return confTO;
View Full Code Here

                break;
            case MEMBERSHIP:
                result = (T) new MembershipTO();
                break;
            case CONFIGURATION:
                result = (T) new ConfTO();
                break;
            default:
        }

        return result;
View Full Code Here

TOP

Related Classes of org.apache.syncope.common.to.ConfTO

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.