当前位置: 首页>>代码示例>>Java>>正文


Java SubsystemRegistration.setHostCapable方法代码示例

本文整理汇总了Java中org.jboss.as.controller.SubsystemRegistration.setHostCapable方法的典型用法代码示例。如果您正苦于以下问题:Java SubsystemRegistration.setHostCapable方法的具体用法?Java SubsystemRegistration.setHostCapable怎么用?Java SubsystemRegistration.setHostCapable使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.jboss.as.controller.SubsystemRegistration的用法示例。


在下文中一共展示了SubsystemRegistration.setHostCapable方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: initialize

import org.jboss.as.controller.SubsystemRegistration; //导入方法依赖的package包/类
/**
 * {@inheritDoc}
 */
@Override
public void initialize(ExtensionContext context) {
    final SubsystemRegistration registration = context.registerSubsystem(SUBSYSTEM_NAME, CURRENT_VERSION);

    //This subsystem should be runnable on a host
    registration.setHostCapable();

    //This is ugly but for now we don't want to make the audit logger easily available to all extensions
    @SuppressWarnings("deprecation")
    ManagedAuditLogger auditLogger = (ManagedAuditLogger)((ExtensionContextSupplement)context).getAuditLogger(false, true);
    //This is ugly but for now we don't want to make the authorizer easily available to all extensions
    @SuppressWarnings("deprecation")
    JmxAuthorizer authorizer = ((ExtensionContextSupplement)context).getAuthorizer();
  //This is ugly but for now we don't want to make the securityIdentitySupplier easily available to all extensions
    @SuppressWarnings("deprecation")
    Supplier<SecurityIdentity> securityIdentitySupplier = ((ExtensionContextSupplement)context).getSecurityIdentitySupplier();
    //This is ugly but for now we don't want to make the hostInfoAccessor easily available to all extensions
    @SuppressWarnings("deprecation")
    RuntimeHostControllerInfoAccessor hostInfoAccessor = ((ExtensionContextSupplement)context).getHostControllerInfoAccessor();

    registration.registerSubsystemModel(JMXSubsystemRootResource.create(auditLogger, authorizer, securityIdentitySupplier, hostInfoAccessor));
    registration.registerXMLElementWriter(JMXSubsystemWriter::new);
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:27,代码来源:JMXExtension.java

示例2: initialize

import org.jboss.as.controller.SubsystemRegistration; //导入方法依赖的package包/类
@Override
public void initialize(ExtensionContext context) {
    final SubsystemRegistration subsystemRegistration = context.registerSubsystem(SUBSYSTEM_NAME, ELYTRON_CURRENT);

    // Elytron is expected to be used everywhere.
    subsystemRegistration.setHostCapable();

    final ManagementResourceRegistration registration = subsystemRegistration.registerSubsystemModel(ElytronDefinition.INSTANCE);
    registration.registerOperationHandler(GenericSubsystemDescribeHandler.DEFINITION, GenericSubsystemDescribeHandler.INSTANCE);

    subsystemRegistration.registerXMLElementWriter(() -> new ElytronSubsystemParser2_0());
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:13,代码来源:ElytronExtension.java

示例3: initialize

import org.jboss.as.controller.SubsystemRegistration; //导入方法依赖的package包/类
@Override
public void initialize(final ExtensionContext context) {
    final SubsystemRegistration subsystemRegistration = context.registerSubsystem(SUBSYSTEM_NAME, ModelVersion.create(1, 0));
    subsystemRegistration.setHostCapable();
    subsystemRegistration.registerXMLElementWriter(DiscoverySubsystemParser::new);

    final ManagementResourceRegistration resourceRegistration = subsystemRegistration.registerSubsystemModel(DiscoverySubsystemDefinition.getInstance());
    resourceRegistration.registerOperationHandler(GenericSubsystemDescribeHandler.DEFINITION, GenericSubsystemDescribeHandler.INSTANCE);
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:10,代码来源:DiscoveryExtension.java

示例4: initialize

import org.jboss.as.controller.SubsystemRegistration; //导入方法依赖的package包/类
@Override
public void initialize(ExtensionContext context) {
    SubsystemRegistration subsystem = context.registerSubsystem(SUBSYSTEM_NAME, ModelVersion.create(1));
    subsystem.setHostCapable();
    subsystem.registerSubsystemModel(new CustomContextSubsystemResourceDefinition());
    subsystem.registerXMLElementWriter(PARSER);
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:8,代码来源:CustomContextExtension.java

示例5: initialize

import org.jboss.as.controller.SubsystemRegistration; //导入方法依赖的package包/类
@Override
public void initialize(ExtensionContext context) {
    SubsystemRegistration subsystem = context.registerSubsystem(SUBSYSTEM_NAME, ModelVersion.create(1));
    subsystem.setHostCapable();
    subsystem.registerSubsystemModel(new OperationTypesSubsystemResourceDefinition(context.getProcessType()));
    subsystem.registerXMLElementWriter(PARSER);
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:8,代码来源:OpTypesExtension.java

示例6: initialize

import org.jboss.as.controller.SubsystemRegistration; //导入方法依赖的package包/类
@Override
public void initialize(ExtensionContext context) {
    SubsystemRegistration subsystem = context.registerSubsystem(SUBSYSTEM_NAME, ModelVersion.create(1));
    subsystem.setHostCapable();
    subsystem.registerSubsystemModel(new BlockerSubsystemResourceDefinition(context.getProcessType().isHostController()));
    subsystem.registerXMLElementWriter(PARSER);
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:8,代码来源:ErrorExtension.java

示例7: initialize

import org.jboss.as.controller.SubsystemRegistration; //导入方法依赖的package包/类
@Override
public void initialize(ExtensionContext context) {
    SubsystemRegistration reg = context.registerSubsystem(SUBSYSTEM_NAME, ModelVersion.create(1, 1, 1));
    reg.setHostCapable();
    reg.registerXMLElementWriter(parser);
    reg.registerSubsystemModel(new RootResourceDefinition(SUBSYSTEM_NAME));
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:8,代码来源:TestHostCapableExtension.java

示例8: initialize

import org.jboss.as.controller.SubsystemRegistration; //导入方法依赖的package包/类
@Override
public void initialize(ExtensionContext context) {
    final SubsystemRegistration subsystem = context.registerSubsystem(SUBSYSTEM_NAME, CURRENT_VERSION);
    subsystem.registerXMLElementWriter(CoreManagementSubsystemParser_1_0::new);
    //This subsystem should be runnable on a host
    subsystem.setHostCapable();
    ManagementResourceRegistration registration = subsystem.registerSubsystemModel(new CoreManagementRootResourceDefinition());
    registration.registerOperationHandler(GenericSubsystemDescribeHandler.DEFINITION, GenericSubsystemDescribeHandler.INSTANCE);
}
 
开发者ID:wildfly,项目名称:wildfly-core,代码行数:10,代码来源:CoreManagementExtension.java


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