Package org.wso2.carbon.registry.core

Examples of org.wso2.carbon.registry.core.CollectionImpl.removeProperty()


        r1.setProperty("p2", "v2");
        registry.put("/props/t1/r1", r1);

        Resource r1e1 = registry.get("/props/t1/r1");
        r1e1.setContent("r1 content");
        r1e1.removeProperty("p1");
        registry.put("/props/t1/r1", r1e1);

        Resource r1e2 = registry.get("/props/t1/r1");

        assertEquals("Property is not removed.", r1e2.getProperty("p1"), null);
View Full Code Here


        r1.setProperty("p2", "v2");
        registry.put("/props/t1/r1", r1);

        Resource r1e1 = registry.get("/props/t1/r1");
        r1e1.setContent("r1 content");
        r1e1.removeProperty("p1");
        registry.put("/props/t1/r1", r1e1);

        Resource r1e2 = registry.get("/props/t1/r1");

        assertEquals("Property is not removed.", r1e2.getProperty("p1"), null);
View Full Code Here

                Collections.sort(checkListItems);

                int index = 0;
                for (CheckListItem checkListItem : checkListItems) {
                    if ((lifeCycleState).equalsIgnoreCase(checkListItem.getLifeCycleStatus())) {
                        resource.removeProperty(checkListItem.getPropertyName());
                        List<String> listItem = new ArrayList<String>();
                        listItem.add("status:" + checkListItem.getLifeCycleStatus());
                        listItem.add("name:" + checkListItem.getName());
                        listItem.add("value:" + items[index]);
                        if (checkListItem.getOrder() != null)
View Full Code Here

            }
            String path = resource.getProperty(artifactId);
            if (registry.resourceExists(path)) {
                registry.delete(path);
            }
            resource.removeProperty(artifactId);
            governanceSystemRegistry.put(
                    GovernanceConstants.GOVERNANCE_ARTIFACT_INDEX_PATH, resource);
        } catch (RegistryException e) {
            String msg = "Error in deleting the the artifact id:" + artifactId + ".";
            log.error(msg, e);
View Full Code Here

                    propertiesToRemove.add(propKey);
                }
            }

            for(String propertyName : propertiesToRemove) {
                resource.removeProperty(propertyName);
            }

            registry.put(path, resource);

        } catch (RegistryException e) {
View Full Code Here

            path = IdentityRegistryResources.OAUTH_APP_PATH + app.getUserName() + "/"
                    + app.getApplicationName();

            if (registry.resourceExists(path)) {
                resource = registry.get(path);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CALLBACK);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CONSUMER_KEY);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CONSUMER_SECRET);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_NAME);
            } else {
                resource = registry.newCollection();
View Full Code Here

                    + app.getApplicationName();

            if (registry.resourceExists(path)) {
                resource = registry.get(path);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CALLBACK);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CONSUMER_KEY);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CONSUMER_SECRET);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_NAME);
            } else {
                resource = registry.newCollection();
            }
View Full Code Here

            if (registry.resourceExists(path)) {
                resource = registry.get(path);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CALLBACK);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CONSUMER_KEY);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CONSUMER_SECRET);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_NAME);
            } else {
                resource = registry.newCollection();
            }
View Full Code Here

            if (registry.resourceExists(path)) {
                resource = registry.get(path);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CALLBACK);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CONSUMER_KEY);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_CONSUMER_SECRET);
                resource.removeProperty(IdentityRegistryResources.OAUTH_APP_NAME);
            } else {
                resource = registry.newCollection();
            }

            resource
View Full Code Here

            } else {
                if (log.isDebugEnabled()) {
                    log.debug("Updating openid admin");
                }
                resource = registry.get(path);
                resource.removeProperty(IdentityRegistryResources.SUB_DOMAIN);
                resource.removeProperty(IdentityRegistryResources.OPENID_PATTERN);
            }
            resource.addProperty(IdentityRegistryResources.SUB_DOMAIN, opAdmin.getSubDomain());
            resource.addProperty(IdentityRegistryResources.OPENID_PATTERN, opAdmin
                    .getTenantOpenIDPattern());
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.