Package org.jboss.as.controller.descriptions

Examples of org.jboss.as.controller.descriptions.DefaultOperationDescriptionProvider


    @Override
    public ModelNode getModelDescription(Locale locale) {

        final ResourceDescriptionResolver resolver = ServerDescriptions.getResourceDescriptionResolver("interface");
        final DescriptionProvider delegate = new DefaultOperationDescriptionProvider(OPERATION_NAME, resolver, ModelType.STRING);
        final ModelNode result = delegate.getModelDescription(locale);
        // Hack. Re-use some existing description. TODO check if adding ATTRIBUTES to delegate will do the job
        final ModelNode toMerge = SpecifiedInterfaceAddHandler.INSTANCE.getModelDescription(locale);
        result.get(ModelDescriptionConstants.REQUEST_PROPERTIES).set(toMerge.get(ModelDescriptionConstants.REQUEST_PROPERTIES));
        return  result;
    }
View Full Code Here


    }

    @Override
    public void registerOperations(ManagementResourceRegistration resourceRegistration) {
        super.registerOperations(resourceRegistration);
        DefaultOperationDescriptionProvider deleteDesc = new DefaultOperationDescriptionProvider(LogStoreConstants.DELETE, getResourceDescriptionResolver());
        resourceRegistration.registerOperationHandler(LogStoreConstants.DELETE, new LogStoreTransactionDeleteHandler(resource), deleteDesc);
    }
View Full Code Here

    }

    @Override
    public void registerOperations(ManagementResourceRegistration resourceRegistration) {
        super.registerOperations(resourceRegistration);
        DefaultOperationDescriptionProvider probeDesc = new DefaultOperationDescriptionProvider(LogStoreConstants.PROBE, getResourceDescriptionResolver());
        resourceRegistration.registerOperationHandler(LogStoreConstants.PROBE, LogStoreProbeHandler.INSTANCE, probeDesc);
    }
View Full Code Here

    public void registerOperations(ManagementResourceRegistration resourceRegistration) {
        super.registerOperations(resourceRegistration);

        final LogStoreParticipantRefreshHandler refreshHandler = LogStoreParticipantRefreshHandler.INSTANCE;

        DefaultOperationDescriptionProvider refreshDesc = new DefaultOperationDescriptionProvider(LogStoreConstants.REFRESH, getResourceDescriptionResolver());
        resourceRegistration.registerOperationHandler(LogStoreConstants.REFRESH, refreshHandler, refreshDesc);
        DefaultOperationDescriptionProvider recoverDesc = new DefaultOperationDescriptionProvider(LogStoreConstants.RECOVER, getResourceDescriptionResolver());
        resourceRegistration.registerOperationHandler(LogStoreConstants.RECOVER, new LogStoreParticipantRecoveryHandler(refreshHandler), recoverDesc);
    }
View Full Code Here

    @Override
    public ModelNode getModelDescription(Locale locale) {

        final ResourceDescriptionResolver resolver = ServerDescriptions.getResourceDescriptionResolver("interface");
        final DescriptionProvider delegate = new DefaultOperationDescriptionProvider(OPERATION_NAME, resolver, ModelType.STRING);
        final ModelNode result = delegate.getModelDescription(locale);
        // Hack. Re-use some existing description. TODO check if adding ATTRIBUTES to delegate will do the job
        final ModelNode toMerge = SpecifiedInterfaceAddHandler.INSTANCE.getModelDescription(locale);
        result.get(ModelDescriptionConstants.REQUEST_PROPERTIES).set(toMerge.get(ModelDescriptionConstants.REQUEST_PROPERTIES));
        return  result;
    }
View Full Code Here

    }

    @Override
    public void registerOperations(ManagementResourceRegistration resourceRegistration) {
        super.registerOperations(resourceRegistration);
        DefaultOperationDescriptionProvider deleteDesc = new DefaultOperationDescriptionProvider(LogStoreConstants.DELETE, getResourceDescriptionResolver());
        resourceRegistration.registerOperationHandler(LogStoreConstants.DELETE, new LogStoreTransactionDeleteHandler(resource), deleteDesc);
    }
View Full Code Here

    }

    @Override
    public void registerOperations(ManagementResourceRegistration resourceRegistration) {
        super.registerOperations(resourceRegistration);
        DefaultOperationDescriptionProvider probeDesc = new DefaultOperationDescriptionProvider(LogStoreConstants.PROBE, getResourceDescriptionResolver());
        resourceRegistration.registerOperationHandler(LogStoreConstants.PROBE, LogStoreProbeHandler.INSTANCE, probeDesc);
    }
View Full Code Here

    public void registerOperations(ManagementResourceRegistration resourceRegistration) {
        super.registerOperations(resourceRegistration);

        final LogStoreParticipantRefreshHandler refreshHandler = LogStoreParticipantRefreshHandler.INSTANCE;

        DefaultOperationDescriptionProvider refreshDesc = new DefaultOperationDescriptionProvider(LogStoreConstants.REFRESH, getResourceDescriptionResolver());
        resourceRegistration.registerOperationHandler(LogStoreConstants.REFRESH, refreshHandler, refreshDesc);
        DefaultOperationDescriptionProvider recoverDesc = new DefaultOperationDescriptionProvider(LogStoreConstants.RECOVER, getResourceDescriptionResolver());
        resourceRegistration.registerOperationHandler(LogStoreConstants.RECOVER, new LogStoreParticipantRecoveryHandler(refreshHandler), recoverDesc);
    }
View Full Code Here

        context.completeStep(OperationContext.RollbackHandler.NOOP_ROLLBACK_HANDLER);
    }

    @Override
    public ModelNode getModelDescription(Locale locale) {
        DescriptionProvider delegate = new DefaultOperationDescriptionProvider(OPERATION_NAME, descriptionResolver, ManagedDMRContentResourceDefinition.HASH, contentAttribute);
        return delegate.getModelDescription(locale);
    }
View Full Code Here

        context.completeStep(OperationContext.RollbackHandler.NOOP_ROLLBACK_HANDLER);
    }

    @Override
    public ModelNode getModelDescription(Locale locale) {
        DescriptionProvider delegate = new DefaultOperationDescriptionProvider(ModelDescriptionConstants.ADD, descriptionResolver, contentAttribute);
        return delegate.getModelDescription(locale);
    }
View Full Code Here

TOP

Related Classes of org.jboss.as.controller.descriptions.DefaultOperationDescriptionProvider

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.