Package org.jboss.dmr

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


            final ServiceController<?> fileController = registry.getService(serviceName);
            if (fileController == null) {
                throw new OperationFailedException(new ModelNode().set(MESSAGES.serviceNotFound(serviceName)));
            }
            final HandlerFileService fileService = (HandlerFileService) fileController.getService();
            fileService.setPath(path.asString());

            // Find the handler and set the new file
            @SuppressWarnings("unchecked")
            final ServiceController<?> handlerController = registry.getService(LogServices.handlerName(name));
            final AbstractFileHandlerService handlerService = (AbstractFileHandlerService) handlerController.getService();
View Full Code Here


        }
        if (newValue.getType() != ModelType.OBJECT || currentValue.getType() != ModelType.OBJECT) {
            return newValue;
        }
        final ModelNode newPath = newValue.get(PATH.getName());
        if (newPath.isDefined() && !AbstractPathService.isAbsoluteUnixOrWindowsPath(newPath.asString())) {
            if (currentValue.hasDefined(RELATIVE_TO.getName()) && !newValue.hasDefined(RELATIVE_TO.getName())) {
                newValue.get(RELATIVE_TO.getName()).set(currentValue.get(RELATIVE_TO.getName()));
            }
        }
        return newValue;
View Full Code Here

        final String name = address.getLastElement().getValue();

        // pick up the attribute values from the model
        ModelNode resolvedValue = null ;
        // make default cache non required (AS7-3488)
        final String defaultCache = ((resolvedValue = CommonAttributes.DEFAULT_CACHE.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String startMode = ((resolvedValue = CommonAttributes.START.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String jndiNameString = ((resolvedValue = CommonAttributes.JNDI_NAME.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String listenerExecutor = ((resolvedValue = CommonAttributes.LISTENER_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String evictionExecutor = ((resolvedValue = CommonAttributes.EVICTION_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String replicationQueueExecutor = ((resolvedValue = CommonAttributes.REPLICATION_QUEUE_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
View Full Code Here

        // pick up the attribute values from the model
        ModelNode resolvedValue = null ;
        // make default cache non required (AS7-3488)
        final String defaultCache = ((resolvedValue = CommonAttributes.DEFAULT_CACHE.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String startMode = ((resolvedValue = CommonAttributes.START.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String jndiNameString = ((resolvedValue = CommonAttributes.JNDI_NAME.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String listenerExecutor = ((resolvedValue = CommonAttributes.LISTENER_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String evictionExecutor = ((resolvedValue = CommonAttributes.EVICTION_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String replicationQueueExecutor = ((resolvedValue = CommonAttributes.REPLICATION_QUEUE_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
View Full Code Here

        // pick up the attribute values from the model
        ModelNode resolvedValue = null ;
        // make default cache non required (AS7-3488)
        final String defaultCache = ((resolvedValue = CommonAttributes.DEFAULT_CACHE.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String startMode = ((resolvedValue = CommonAttributes.START.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String jndiNameString = ((resolvedValue = CommonAttributes.JNDI_NAME.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String listenerExecutor = ((resolvedValue = CommonAttributes.LISTENER_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String evictionExecutor = ((resolvedValue = CommonAttributes.EVICTION_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String replicationQueueExecutor = ((resolvedValue = CommonAttributes.REPLICATION_QUEUE_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;

        boolean hasTransport = model.hasDefined(ModelKeys.TRANSPORT) && model.get(ModelKeys.TRANSPORT).hasDefined(ModelKeys.TRANSPORT_NAME);
View Full Code Here

        ModelNode resolvedValue = null ;
        // make default cache non required (AS7-3488)
        final String defaultCache = ((resolvedValue = CommonAttributes.DEFAULT_CACHE.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String startMode = ((resolvedValue = CommonAttributes.START.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String jndiNameString = ((resolvedValue = CommonAttributes.JNDI_NAME.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String listenerExecutor = ((resolvedValue = CommonAttributes.LISTENER_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String evictionExecutor = ((resolvedValue = CommonAttributes.EVICTION_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String replicationQueueExecutor = ((resolvedValue = CommonAttributes.REPLICATION_QUEUE_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;

        boolean hasTransport = model.hasDefined(ModelKeys.TRANSPORT) && model.get(ModelKeys.TRANSPORT).hasDefined(ModelKeys.TRANSPORT_NAME);
        Transport transportConfig = hasTransport ? new Transport() : null;
View Full Code Here

        // make default cache non required (AS7-3488)
        final String defaultCache = ((resolvedValue = CommonAttributes.DEFAULT_CACHE.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String startMode = ((resolvedValue = CommonAttributes.START.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String jndiNameString = ((resolvedValue = CommonAttributes.JNDI_NAME.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String listenerExecutor = ((resolvedValue = CommonAttributes.LISTENER_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String evictionExecutor = ((resolvedValue = CommonAttributes.EVICTION_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String replicationQueueExecutor = ((resolvedValue = CommonAttributes.REPLICATION_QUEUE_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;

        boolean hasTransport = model.hasDefined(ModelKeys.TRANSPORT) && model.get(ModelKeys.TRANSPORT).hasDefined(ModelKeys.TRANSPORT_NAME);
        Transport transportConfig = hasTransport ? new Transport() : null;
        EmbeddedCacheManagerDependencies dependencies = new EmbeddedCacheManagerDependencies(transportConfig);
View Full Code Here

        final String defaultCache = ((resolvedValue = CommonAttributes.DEFAULT_CACHE.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String startMode = ((resolvedValue = CommonAttributes.START.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String jndiNameString = ((resolvedValue = CommonAttributes.JNDI_NAME.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String listenerExecutor = ((resolvedValue = CommonAttributes.LISTENER_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String evictionExecutor = ((resolvedValue = CommonAttributes.EVICTION_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;
        final String replicationQueueExecutor = ((resolvedValue = CommonAttributes.REPLICATION_QUEUE_EXECUTOR.resolveModelAttribute(context, model)).isDefined()) ? resolvedValue.asString() : null ;

        boolean hasTransport = model.hasDefined(ModelKeys.TRANSPORT) && model.get(ModelKeys.TRANSPORT).hasDefined(ModelKeys.TRANSPORT_NAME);
        Transport transportConfig = hasTransport ? new Transport() : null;
        EmbeddedCacheManagerDependencies dependencies = new EmbeddedCacheManagerDependencies(transportConfig);
View Full Code Here

                        .addDependency(SocketBinding.JBOSS_BINDING_NAME.append(model.get(SOCKET_BINDING).asString()), SocketBinding.class, bindingService.getBindingRef())
                        .install();
            } else {

                final ModelNode localAddrNode = CommonAttributes.LOCAL_BIND_ADDRESS.resolveModelAttribute(context, model);
                final String localAddress = localAddrNode.isDefined() ? localAddrNode.asString() : null;
                final String groupAddress = CommonAttributes.GROUP_ADDRESS.resolveModelAttribute(context, model).asString();
                final int groupPort = CommonAttributes.GROUP_PORT.resolveModelAttribute(context, model).asInt();
                final int localBindPort = CommonAttributes.LOCAL_BIND_PORT.resolveModelAttribute(context, model).asInt();

                try {
View Full Code Here

    private static ServerConfigImpl createServerConfig(ModelNode configuration, boolean appclient) {
        final ServerConfigImpl config = ServerConfigImpl.newInstance();
        try {
            ModelNode wsdlHost = configuration.require(WSDL_HOST).resolve();
            config.setWebServiceHost(wsdlHost.asString());
        } catch (UnknownHostException e) {
            throw new RuntimeException(e);
        }
        if (!appclient) {
            config.setModifySOAPAddress(configuration.require(MODIFY_WSDL_ADDRESS).asBoolean());
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.