• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Java ResourceDescriptionResolver类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.jboss.as.controller.descriptions.ResourceDescriptionResolver的典型用法代码示例。如果您正苦于以下问题:Java ResourceDescriptionResolver类的具体用法?Java ResourceDescriptionResolver怎么用?Java ResourceDescriptionResolver使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



ResourceDescriptionResolver类属于org.jboss.as.controller.descriptions包,在下文中一共展示了ResourceDescriptionResolver类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: getOperationDefinition

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
@Override
 public OperationDefinition getOperationDefinition() {
 	final AttributeDefinition[] parameters = new AttributeDefinition[] {OperationsConstants.VDB_NAME, OperationsConstants.VDB_VERSION};
 	final ResourceDescriptionResolver resolver = new TeiidResourceDescriptionResolver(name());
     return new OperationDefinition(name(), OperationEntry.EntryType.PUBLIC, EnumSet.noneOf(OperationEntry.Flag.class), ModelType.OBJECT, null, true, null, null, parameters) {
@Override
public DescriptionProvider getDescriptionProvider() {
	return new DefaultOperationDescriptionProvider(name(), resolver, resolver,  ModelType.OBJECT, ModelType.OBJECT, null, null, this.parameters) {
		@Override
	    protected ModelNode getReplyValueTypeDescription(ResourceDescriptionResolver descriptionResolver, Locale locale, ResourceBundle bundle) {
			return VDBMetadataMapper.INSTANCE.describe( new ModelNode());
	    }
	};
}
     };
 }
 
开发者ID:kenweezy,项目名称:teiid,代码行数:17,代码来源:TeiidOperationHandler.java


示例2: TrivialResourceDefinition

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
private TrivialResourceDefinition(String pathKey, ResourceDescriptionResolver resourceDescriptionResolver, AbstractAddStepHandler add, AttributeDefinition[] attributes,
        Map<AttributeDefinition, OperationStepHandler> readOnlyAttributes, Map<OperationDefinition, OperationStepHandler> operations, List<ResourceDefinition> children,
        RuntimeCapability<?>[] runtimeCapabilities) {
    super(new Parameters(PathElement.pathElement(pathKey),
            resourceDescriptionResolver)
        .setAddHandler(add)
        .setRemoveHandler(new TrivialCapabilityServiceRemoveHandler(add, runtimeCapabilities))
        .setAddRestartLevel(OperationEntry.Flag.RESTART_RESOURCE_SERVICES)
        .setRemoveRestartLevel(OperationEntry.Flag.RESTART_RESOURCE_SERVICES)
        .setCapabilities(runtimeCapabilities));

    this.pathKey = pathKey;
    this.firstCapability = runtimeCapabilities[0];
    this.attributes = attributes;
    this.readOnlyAttributes = readOnlyAttributes;
    this.operations = operations;
    this.children = children;
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:19,代码来源:TrivialResourceDefinition.java


示例3: registerOperations

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
@Override
public void registerOperations(final ManagementResourceRegistration registration) {
    super.registerOperations(registration);
    final ResourceDescriptionResolver resourceDescriptionResolver = getResourceDescriptionResolver();
    registration.registerOperationHandler(new SimpleOperationDefinitionBuilder(ADD_SUBHANDLER_OPERATION_NAME, resourceDescriptionResolver)
            .setDeprecated(ModelVersion.create(1, 2, 0))
            .setParameters(CommonAttributes.HANDLER_NAME)
            .build(), HandlerOperations.ADD_SUBHANDLER);

    registration.registerOperationHandler(new SimpleOperationDefinitionBuilder(REMOVE_SUBHANDLER_OPERATION_NAME, resourceDescriptionResolver)
            .setDeprecated(ModelVersion.create(1, 2, 0))
            .setParameters(CommonAttributes.HANDLER_NAME)
            .build(), HandlerOperations.REMOVE_SUBHANDLER);

    registration.registerOperationHandler(new SimpleOperationDefinitionBuilder(ADD_HANDLER_OPERATION_NAME, resourceDescriptionResolver)
            .setParameters(CommonAttributes.HANDLER_NAME)
            .build(), HandlerOperations.ADD_SUBHANDLER);

    registration.registerOperationHandler(new SimpleOperationDefinitionBuilder(REMOVE_HANDLER_OPERATION_NAME, resourceDescriptionResolver)
            .setParameters(CommonAttributes.HANDLER_NAME)
            .build(), HandlerOperations.REMOVE_SUBHANDLER);
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:23,代码来源:AsyncHandlerResourceDefinition.java


示例4: SimpleOperationDefinition

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
/** @deprecated use {@link org.jboss.as.controller.SimpleOperationDefinitionBuilder} */
@Deprecated
@SuppressWarnings("deprecation")
protected SimpleOperationDefinition(final String name,
        final ResourceDescriptionResolver resolver,
        final ResourceDescriptionResolver attributeResolver,
        final OperationEntry.EntryType entryType,
        final EnumSet<OperationEntry.Flag> flags,
        final ModelType replyType,
        final ModelType replyValueType,
        final boolean replyAllowNull,
        final DeprecationData deprecationData,
        final AttributeDefinition[] replyParameters,
        final AttributeDefinition[] parameters,
        final AccessConstraintDefinition[] accessConstraints) {
    super(name, entryType, flags, replyType, replyValueType, replyAllowNull, deprecationData, replyParameters, parameters, accessConstraints);
    this.resolver = resolver;
    this.attributeResolver = attributeResolver;
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:20,代码来源:SimpleOperationDefinition.java


示例5: SimpleResourceDefinition

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
/**
 * {@link ResourceDefinition} that uses the given {code descriptionResolver} to configure a
 * {@link DefaultResourceDescriptionProvider} to describe the resource.
 *
 * @param pathElement         the path. Can be {@code null}.
 * @param descriptionResolver the description resolver to use in the description provider. Cannot be {@code null}      *
 * @param addHandler          a handler to {@link #registerOperations(ManagementResourceRegistration) register} for the resource "add" operation.
 *                            Can be {null}
 * @param removeHandler       a handler to {@link #registerOperations(ManagementResourceRegistration) register} for the resource "remove" operation.
 *                            Can be {null}
 * @param deprecationData     Information describing deprecation of this resource. Can be {@code null} if the resource isn't deprecated.
 * @param runtime             Whether this is a runtime resource
 * @throws IllegalArgumentException if {@code descriptionResolver} is {@code null}.
 * @deprecated Use {@link #SimpleResourceDefinition(Parameters)}
 */
@Deprecated
@SuppressWarnings("deprecation")
public SimpleResourceDefinition(final PathElement pathElement, final ResourceDescriptionResolver descriptionResolver,
                                final OperationStepHandler addHandler, final OperationStepHandler removeHandler,
                                final OperationEntry.Flag addRestartLevel, final OperationEntry.Flag removeRestartLevel,
                                final DeprecationData deprecationData, final boolean runtime) {
    //Don't add new constructor variants!
    //Use the Parameters variety

    //Can be removed when we get to 3.0.0
    this(new Parameters(pathElement, descriptionResolver)
            .setAddHandler(addHandler)
            .setAddRestartLevel(addRestartLevel == null ? restartLevelForAdd(addHandler) : addRestartLevel)
            .setRemoveHandler(removeHandler)
            .setRemoveRestartLevel(removeRestartLevel == null ? restartLevelForRemove(removeHandler) : removeRestartLevel)
            .setDeprecationData(deprecationData)
            .setRuntime(runtime));
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:34,代码来源:SimpleResourceDefinition.java


示例6: getResourceDescriptionResolver

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
static ResourceDescriptionResolver getResourceDescriptionResolver(final boolean useUnprefixedChildTypes, final String... keyPrefix) {
    StringBuilder prefix = new StringBuilder();
    for (String kp : keyPrefix) {
        if (prefix.length() > 0){
            prefix.append('.');
        }
        prefix.append(kp);
    }
    return new StandardResourceDescriptionResolver(prefix.toString(), RESOURCE_NAME, SubsystemExtension.class.getClassLoader(), true, useUnprefixedChildTypes);
}
 
开发者ID:wildfly-extras,项目名称:wildfly-microprofile-config,代码行数:11,代码来源:SubsystemExtension.java


示例7: register

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
static void register(ManagementResourceRegistration resourceRegistration, ResourceDescriptionResolver descriptionResolver) {
    SimpleOperationDefinition READ_ALIASES = new SimpleOperationDefinitionBuilder(ElytronDescriptionConstants.READ_ALIASES, descriptionResolver)
            .setReadOnly()
            .setRuntimeOnly()
            .build();
    resourceRegistration.registerOperationHandler(READ_ALIASES, new ReadAliasesHandler());
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:8,代码来源:ModifiableKeyStoreDecorator.java


示例8: registerOperations

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
@Override
public void registerOperations(ManagementResourceRegistration resourceRegistration) {
    super.registerOperations(resourceRegistration);
    ResourceDescriptionResolver resolver = ElytronExtension.getResourceDescriptionResolver(ElytronDescriptionConstants.MODIFIABLE_SECURITY_REALM);
    ReadIdentityHandler.register(resourceRegistration, resolver);
    if (isServerOrHostController(resourceRegistration)) {
        AddIdentityHandler.register(resourceRegistration, resolver);
        RemoveIdentityHandler.register(resourceRegistration, resolver);
        AddIdentityAttributeHandler.register(resourceRegistration, resolver);
        RemoveIdentityAttributeHandler.register(resourceRegistration, resolver);
        SetPasswordHandler.register(resourceRegistration, resolver);
    }
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:14,代码来源:ModifiableRealmDecorator.java


示例9: register

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
static void register(ManagementResourceRegistration resourceRegistration, ResourceDescriptionResolver descriptionResolver) {
    resourceRegistration.registerOperationHandler(
            new SimpleOperationDefinitionBuilder(ElytronDescriptionConstants.ADD_IDENTITY, descriptionResolver)
                    .setParameters(IDENTITY)
                    .setRuntimeOnly()
                    .build(),
            new AddIdentityHandler());
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:9,代码来源:ModifiableRealmDecorator.java


示例10: createResourceDescriptionResolver

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
static ResourceDescriptionResolver createResourceDescriptionResolver() {
    final Map<String, String> strings = new HashMap<String, String>();
    strings.put("test", "The test resource");
    strings.put("test.child", "Child test resource");
    strings.put("test.data-source", "Override singleton test resource");
    strings.put("test.service", "Pure singleton test resource");

    return new StandardResourceDescriptionResolver("test", SingletonResourceTestCase.class.getName() + ".properties", SingletonResourceTestCase.class.getClassLoader(), true, false) {

        @Override
        public ResourceBundle getResourceBundle(Locale locale) {
            return new ResourceBundle() {

                @Override
                protected Object handleGetObject(String key) {
                    return strings.get(key);
                }

                @Override
                public Enumeration<String> getKeys() {
                    return null;
                }
            };
        }

    };
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:28,代码来源:SingletonResourceTestCase.java


示例11: register

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
static void register(ManagementResourceRegistration resourceRegistration, ResourceDescriptionResolver descriptionResolver) {
    resourceRegistration.registerOperationHandler(
            new SimpleOperationDefinitionBuilder(ElytronDescriptionConstants.READ_IDENTITY, descriptionResolver)
                    .setParameters(NAME)
                    .setRuntimeOnly()
                    .setReadOnly()
                    .build(),
            new ReadSecurityDomainIdentityHandler());
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:10,代码来源:DomainDefinition.java


示例12: LdapResourceDefinition

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
public LdapResourceDefinition(PathElement pathElement, ResourceDescriptionResolver descriptionResolver,
        OperationStepHandler addHandler, OperationStepHandler removeHandler, Flag addRestartLevel, Flag removeRestartLevel) {
    this(new Parameters(pathElement, descriptionResolver)
            .setAddHandler(addHandler)
            .setAddRestartLevel(addRestartLevel)
            .setRemoveHandler(removeHandler)
            .setRemoveRestartLevel(removeRestartLevel));
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:9,代码来源:LdapResourceDefinition.java


示例13: PropertiesFileResourceDefinition

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
public PropertiesFileResourceDefinition(final PathElement pathElement,
        final ResourceDescriptionResolver descriptionResolver, final OperationStepHandler addHandler,
        final OperationStepHandler removeHandler, final OperationEntry.Flag addRestartLevel,
        final OperationEntry.Flag removeRestartLevel) {
    this(new Parameters(pathElement, descriptionResolver)
            .setAddHandler(addHandler)
            .setAddRestartLevel(addRestartLevel)
            .setRemoveHandler(removeHandler)
            .setRemoveRestartLevel(removeRestartLevel));
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:11,代码来源:PropertiesFileResourceDefinition.java


示例14: BaseLdapGroupSearchResource

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
protected BaseLdapGroupSearchResource(final GroupSearchType searchType,
        final ResourceDescriptionResolver descriptionResolver, final OperationStepHandler addHandler,
        final OperationStepHandler removeHandler) {
    super(PathElement.pathElement(ModelDescriptionConstants.GROUP_SEARCH, searchType.getModelValue()),
            descriptionResolver, addHandler, removeHandler, OperationEntry.Flag.RESTART_NONE,
            OperationEntry.Flag.RESTART_RESOURCE_SERVICES);
    setDeprecated(ModelVersion.create(1, 7));
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:9,代码来源:BaseLdapGroupSearchResource.java


示例15: AbstractPlugInAuthResourceDefinition

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
AbstractPlugInAuthResourceDefinition(PathElement pathElement, ResourceDescriptionResolver resourceDescriptionResolver,
        SecurityRealmChildAddHandler securityRealmChildAddHandler,
        SecurityRealmChildRemoveHandler securityRealmChildRemoveHandler, Flag restartResourceServices,
        Flag restartResourceServices2) {
    this(new Parameters(pathElement, resourceDescriptionResolver)
            .setAddHandler(securityRealmChildAddHandler)
            .setAddRestartLevel(restartResourceServices)
            .setRemoveHandler(securityRealmChildRemoveHandler)
            .setRemoveRestartLevel(restartResourceServices2));
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:11,代码来源:AbstractPlugInAuthResourceDefinition.java


示例16: BaseLdapUserSearchResource

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
protected BaseLdapUserSearchResource(final UserSearchType searchType,
        final ResourceDescriptionResolver descriptionResolver, final OperationStepHandler addHandler,
        final OperationStepHandler removeHandler) {
    super(PathElement.pathElement(ModelDescriptionConstants.USERNAME_TO_DN, searchType.getModelValue()),
            descriptionResolver, addHandler, removeHandler, OperationEntry.Flag.RESTART_NONE,
            OperationEntry.Flag.RESTART_RESOURCE_SERVICES);
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:8,代码来源:BaseLdapUserSearchResource.java


示例17: SyslogAuditLogProtocolResourceDefinition

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
SyslogAuditLogProtocolResourceDefinition(ManagedAuditLogger auditLogger, PathManagerService pathManager,
                                         AttributeDefinition[] attributes, PathElement pathElement,
                                         ResourceDescriptionResolver resolver, EnvironmentNameReader environmentReader) {
    super(
            pathElement,
            resolver,
            new ProtocolConfigAddHandler(auditLogger, pathManager, attributes, environmentReader),
            new ProtocolConfigRemoveHandler(auditLogger, pathManager, environmentReader));
    this.auditLogger = auditLogger;
    this.pathManager = pathManager;
    this.attributes = attributes;
    this.environmentReader = environmentReader;
    setDeprecated(ModelVersion.create(1, 7));
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:15,代码来源:SyslogAuditLogProtocolResourceDefinition.java


示例18: registerOperations

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
@Override
public void registerOperations(final ManagementResourceRegistration registration) {
    super.registerOperations(registration);

    if (registerLegacyOps) {
        final ResourceDescriptionResolver resourceDescriptionResolver = getResourceDescriptionResolver();
        registration.registerOperationHandler(new SimpleOperationDefinitionBuilder(ENABLE, resourceDescriptionResolver)
                .setDeprecated(ModelVersion.create(1, 2, 0))
                .build(), HandlerOperations.ENABLE_HANDLER);

        registration.registerOperationHandler(new SimpleOperationDefinitionBuilder(DISABLE, resourceDescriptionResolver)
                .setDeprecated(ModelVersion.create(1, 2, 0))
                .build(), HandlerOperations.DISABLE_HANDLER);

        registration.registerOperationHandler(new SimpleOperationDefinitionBuilder(CHANGE_LEVEL_OPERATION_NAME, resourceDescriptionResolver)
                .setDeprecated(ModelVersion.create(1, 2, 0))
                .setParameters(CommonAttributes.LEVEL)
                .build(), HandlerOperations.CHANGE_LEVEL);

        final SimpleOperationDefinition updateProperties = new SimpleOperationDefinitionBuilder(UPDATE_OPERATION_NAME, resourceDescriptionResolver)
                .setDeprecated(ModelVersion.create(1, 2, 0))
                .setParameters(writableAttributes)
                .build();

        registration.registerOperationHandler(updateProperties, new HandlerOperations.HandlerUpdateOperationStepHandler(propertySorter, writableAttributes));
    }
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:28,代码来源:AbstractHandlerDefinition.java


示例19: TransformerResourceDefinition

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
protected TransformerResourceDefinition(final PathElement pathElement, final ResourceDescriptionResolver descriptionResolver, final OperationStepHandler addHandler, final OperationStepHandler removeHandler, final Flag addRestartLevel, final Flag removeRestartLevel) {
    super(new Parameters(pathElement, descriptionResolver)
            .setAddHandler(addHandler)
            .setRemoveHandler(removeHandler)
            .setAddRestartLevel(addRestartLevel)
            .setRemoveRestartLevel(removeRestartLevel));
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:8,代码来源:TransformerResourceDefinition.java


示例20: internalBuild

import org.jboss.as.controller.descriptions.ResourceDescriptionResolver; //导入依赖的package包/类
@Override
public SimpleOperationDefinition internalBuild(final ResourceDescriptionResolver resolver, final ResourceDescriptionResolver attributeResolver) {
    return new SimpleOperationDefinition(name, resolver, attributeResolver, entryType, flags, replyType, replyValueType, false, deprecationData, replyParameters, parameters) {
        @Override
        public DescriptionProvider getDescriptionProvider() {
            return new DescriptionProvider() {
                @Override
                public ModelNode getModelDescription(Locale locale) {
                    AttributeDefinition[] params = hostControllerInfo.isMasterDomainController() ? MASTER_ATTRIBUTES : SLAVE_ATTRIBUTES;
                    return new DefaultOperationDescriptionProvider(getName(), resolver, attributeResolver, replyType, replyValueType, replyAllowNull, deprecationData, replyParameters, params, accessConstraints).getModelDescription(locale);
                }
            };
        }
    };
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:16,代码来源:HostProcessReloadHandler.java



注:本文中的org.jboss.as.controller.descriptions.ResourceDescriptionResolver类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java FTPIllegalReplyException类代码示例发布时间:2022-05-22
下一篇:
Java SchedulingPolicy类代码示例发布时间:2022-05-22
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap