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


Java ProvisioningException类代码示例

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


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

示例1: provideUnchecked

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
@SuppressWarnings("unchecked")
@Override
public <T> T provideUnchecked(Class<T> service) throws ProvisioningException {
    checkNotNull(service, "service");
    @Nullable ProviderRegistration<T> provider = (ProviderRegistration<T>) this.providers.get(service);
    if (provider == null) {
        throw new ProvisioningException("No provider is registered for the service '" + service.getName() + "'", service);
    }
    return provider.getProvider();
}
 
开发者ID:LanternPowered,项目名称:LanternServer,代码行数:11,代码来源:LanternServiceManager.java

示例2: getPriority

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public PriorityService getPriority() throws ProvisioningException {
	return this.plugin.getGame().getServiceManager().provideUnchecked(PriorityService.class);
}
 
开发者ID:EverCraft,项目名称:EverAPI,代码行数:4,代码来源:ManagerService.java

示例3: getActionBar

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public ActionBarService getActionBar() throws ProvisioningException {
	return this.plugin.getGame().getServiceManager().provideUnchecked(ActionBarService.class);
}
 
开发者ID:EverCraft,项目名称:EverAPI,代码行数:4,代码来源:ManagerService.java

示例4: getTitle

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public TitleService getTitle() throws ProvisioningException {
	return this.plugin.getGame().getServiceManager().provideUnchecked(TitleService.class);
}
 
开发者ID:EverCraft,项目名称:EverAPI,代码行数:4,代码来源:ManagerService.java

示例5: getNameTag

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public NameTagService getNameTag() throws ProvisioningException {
	return this.plugin.getGame().getServiceManager().provideUnchecked(NameTagService.class);
}
 
开发者ID:EverCraft,项目名称:EverAPI,代码行数:4,代码来源:ManagerService.java

示例6: getTabList

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public TabListService getTabList() throws ProvisioningException {
	return this.plugin.getGame().getServiceManager().provideUnchecked(TabListService.class);
}
 
开发者ID:EverCraft,项目名称:EverAPI,代码行数:4,代码来源:ManagerService.java

示例7: getBossBar

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public BossBarService getBossBar() throws ProvisioningException {
	return this.plugin.getGame().getServiceManager().provideUnchecked(BossBarService.class);
}
 
开发者ID:EverCraft,项目名称:EverAPI,代码行数:4,代码来源:ManagerService.java

示例8: getScoreBoard

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public ScoreBoardService getScoreBoard() throws ProvisioningException {
	return this.plugin.getGame().getServiceManager().provideUnchecked(ScoreBoardService.class);
}
 
开发者ID:EverCraft,项目名称:EverAPI,代码行数:4,代码来源:ManagerService.java

示例9: getMojangService

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public MojangService getMojangService() throws ProvisioningException {
	return this.plugin.getGame().getServiceManager().provideUnchecked(MojangService.class);
}
 
开发者ID:EverCraft,项目名称:EverAPI,代码行数:4,代码来源:ManagerService.java

示例10: getEntity

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public EntityService getEntity() throws ProvisioningException {
	return this.plugin.getGame().getServiceManager().provideUnchecked(EntityService.class);
}
 
开发者ID:EverCraft,项目名称:EverAPI,代码行数:4,代码来源:ManagerService.java

示例11: getFire

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public FireService getFire() throws ProvisioningException {
	return this.plugin.getGame().getServiceManager().provideUnchecked(FireService.class);
}
 
开发者ID:EverCraft,项目名称:EverAPI,代码行数:4,代码来源:ManagerService.java

示例12: getSpawn

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public SpawnService getSpawn() throws ProvisioningException {
	return this.plugin.getGame().getServiceManager().provideUnchecked(SpawnService.class);
}
 
开发者ID:EverCraft,项目名称:EverAPI,代码行数:4,代码来源:ManagerService.java

示例13: getInstance

import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
/**
 * Gets the instance of {@link UpdatifierService} stored in {@link Sponge}'s
 * service manager. Please use {@link #isAvailable()} to check whether such
 * an instance exists.
 *
 * @throws ProvisioningException If the service is not available
 * @return The instance of {@link UpdatifierService}
 */
static UpdatifierService getInstance() throws ProvisioningException {
    return Sponge.getServiceManager().provideUnchecked(UpdatifierService.class);
}
 
开发者ID:FlibioStudio,项目名称:Updatifier,代码行数:12,代码来源:UpdatifierService.java


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