Examples of asPropertyList()


Examples of org.jboss.dmr.ModelNode.asPropertyList()

            final ModelNode endBindingGroups = endRoot.get(SOCKET_BINDING_GROUP);
            final Map<String, ModelNode> existingBindingGroups = new HashMap<String, ModelNode>();
            if (startBindingGroups.isDefined()) for (Property bindingGroup : startBindingGroups.asPropertyList()) {
                existingBindingGroups.put(bindingGroup.getName(), bindingGroup.getValue());
            }
            if (endBindingGroups.isDefined()) for (Property bindingGroup : endBindingGroups.asPropertyList()) {
                if (existingBindingGroups.containsKey(bindingGroup.getName())) {
                    if (!bindingGroup.getValue().equals(existingBindingGroups.get(bindingGroup.getName()))) {
                        affectedServers.addAll(getServersAffectedBySocketBindingGroup(bindingGroup.getName(), endRoot, hostModel, serverProxies));
                    }
                    existingBindingGroups.remove(bindingGroup.getName());
View Full Code Here

Examples of org.jboss.dmr.ModelNode.asPropertyList()

            final ModelNode endServerGroups = endRoot.get(SERVER_GROUP);
            final Map<String, ModelNode> existingServerGroups = new HashMap<String, ModelNode>();
            if (startServerGroups.isDefined()) for (Property serverGroup : startServerGroups.asPropertyList()) {
                existingServerGroups.put(serverGroup.getName(), serverGroup.getValue());
            }
            if (endServerGroups.isDefined()) for (Property serverGroup : endServerGroups.asPropertyList()) {
                if (existingServerGroups.containsKey(serverGroup.getName())) {
                    if (!serverGroup.getValue().equals(existingServerGroups.get(serverGroup.getName()))) {
                        affectedServers.addAll(getServersForGroup(serverGroup.getName(), hostModel, localHostInfo.getLocalHostName(), serverProxies));
                    }
                    existingServerGroups.remove(serverGroup.getName());
View Full Code Here

Examples of org.jboss.dmr.ModelNode.asPropertyList()

            }
        }

        if(subModel.hasDefined(CommonAttributes.SECURITY_SETTING)) {
            final ModelNode securitySettings = subModel.get(CommonAttributes.SECURITY_SETTING);
            for(final Property setting : securitySettings.asPropertyList()) {
                final ModelNode settingAddress = rootAddress.toModelNode();
                settingAddress.add(CommonAttributes.SECURITY_SETTING, setting.getName());
                result.add(SecuritySettingAdd.createAddOperation(settingAddress, setting.getValue()));
                final ModelNode securitySetting = setting.getValue();
                if(securitySetting.hasDefined(CommonAttributes.ROLE)) {
View Full Code Here

Examples of org.jboss.dmr.ModelNode.asPropertyList()

        InputStream is = null;
        try {
            is = vf.openStream();
            ModelNode node = ModelNode.fromStream(is);
            if (node.isDefined()) {
                for (Property prop : node.asPropertyList()) {
                    ModelNode value = prop.getValue();
                    byte[] hash = hashContent(value);
                    synchronized (content) {
                        content.put(prop.getName(), new ManagedContent(value, hash));
                    }
View Full Code Here

Examples of org.jboss.dmr.ModelNode.asPropertyList()

        context.startSubsystemElement(Namespace.CURRENT.getUriString(), false);
        final ModelNode node = context.getModelNode();

        final ModelNode servers = node.require(HORNETQ_SERVER);
        boolean first = true;
        for (Property prop : servers.asPropertyList()) {
            writeHornetQServer(writer, prop.getName(), prop.getValue());
            if (!first) {
                writeNewLine(writer);
            } else {
                first = false;
View Full Code Here

Examples of org.jboss.dmr.ModelNode.asPropertyList()

        final ModelNode fullModel = Resource.Tools.readModel(context.readResource(PathAddress.EMPTY_ADDRESS));
        final ModelNode channelCreationOptions = fullModel.get(EJB3SubsystemModel.CHANNEL_CREATION_OPTIONS);
        if (channelCreationOptions.isDefined() && channelCreationOptions.asInt() > 0) {
            final ClassLoader loader = this.getClass().getClassLoader();
            final OptionMap.Builder builder = OptionMap.builder();
            for (final Property optionProperty : channelCreationOptions.asPropertyList()) {
                final String name = optionProperty.getName();
                final ModelNode propValueModel = optionProperty.getValue();
                final String type = ChannelCreationOptionResource.CHANNEL_CREATION_OPTION_TYPE.resolveModelAttribute(context,propValueModel).asString();
                final String optionClassName = this.getClassNameForChannelOptionType(type);
                final String fullyQualifiedOptionName = optionClassName + "." + name;
View Full Code Here

Examples of org.jboss.dmr.ModelNode.asPropertyList()

        String[] cacheTypes = {ModelKeys.LOCAL_CACHE, ModelKeys.INVALIDATION_CACHE, ModelKeys.REPLICATED_CACHE, ModelKeys.DISTRIBUTED_CACHE} ;
        for (String cacheType : cacheTypes) {
            // get the caches of a type
            ModelNode caches = model.get(cacheType) ;
            if (caches.isDefined() && caches.getType() == ModelType.OBJECT) {
                List<Property> cacheList = caches.asPropertyList() ;
                // add a clone of each cache to the list
                for (Property cache : cacheList) {
                    String cacheName = cache.getName() ;
                    ModelNode cacheValue = cache.getValue().clone();
                    remainingCaches.add(new Property(cacheName, cacheValue));
View Full Code Here

Examples of org.jboss.dmr.ModelNode.asPropertyList()

                if (resultNode.hasDefined(Util.STEP_2)) {
                    ModelNode resourceOutcome = resultNode.get(Util.STEP_2);
                    if (Util.isSuccess(resourceOutcome)) {
                        if (resourceOutcome.hasDefined(Util.RESULT)) {
                            final ModelNode resourceResult = resourceOutcome.get(Util.RESULT);
                            final List<Property> props = resourceResult.asPropertyList();
                            if (!props.isEmpty()) {
                                final SimpleTable attrTable;
                                if (attrDescriptions == null) {
                                    attrTable = null;
                                } else {
View Full Code Here

Examples of org.jboss.dmr.ModelNode.asPropertyList()


        ModelNode node = operations.get(1);
        assertNotNull(node);
        ModelNode address = node.get(OP_ADDR);
        List<Property> properties = address.asPropertyList();
        assertEquals(2, properties.size());
        for (Property prop : properties) {
            String propName = prop.getName();
            if (!(propName.equals(SUBSYSTEM) || propName.equals(SECURITY_DOMAIN)))
                fail("either subsystem or security-domain expected");
View Full Code Here

Examples of org.jboss.dmr.client.ModelNode.asPropertyList()

                else if ("java.util.List".equals(propBinding.getJavaTypeName()))
                {
                    ModelNode list = actualPayload.get(splitDetypedName);
                    if (list.isDefined() && propValue.isDefined() && !list.asList().isEmpty()) {
                        if (list.asList().get(0).getType().equals(ModelType.PROPERTY)) {
                            value = propBinding.getEntityAdapterForList().fromDMRPropertyList(list.asPropertyList());
                        } else {
                            value = propBinding.getEntityAdapterForList().fromDMRList(list.asList());
                        }
                    }
                    else
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.