本文整理汇总了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();
}
示例2: getPriority
import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public PriorityService getPriority() throws ProvisioningException {
return this.plugin.getGame().getServiceManager().provideUnchecked(PriorityService.class);
}
示例3: getActionBar
import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public ActionBarService getActionBar() throws ProvisioningException {
return this.plugin.getGame().getServiceManager().provideUnchecked(ActionBarService.class);
}
示例4: getTitle
import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public TitleService getTitle() throws ProvisioningException {
return this.plugin.getGame().getServiceManager().provideUnchecked(TitleService.class);
}
示例5: getNameTag
import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public NameTagService getNameTag() throws ProvisioningException {
return this.plugin.getGame().getServiceManager().provideUnchecked(NameTagService.class);
}
示例6: getTabList
import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public TabListService getTabList() throws ProvisioningException {
return this.plugin.getGame().getServiceManager().provideUnchecked(TabListService.class);
}
示例7: getBossBar
import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public BossBarService getBossBar() throws ProvisioningException {
return this.plugin.getGame().getServiceManager().provideUnchecked(BossBarService.class);
}
示例8: getScoreBoard
import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public ScoreBoardService getScoreBoard() throws ProvisioningException {
return this.plugin.getGame().getServiceManager().provideUnchecked(ScoreBoardService.class);
}
示例9: getMojangService
import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public MojangService getMojangService() throws ProvisioningException {
return this.plugin.getGame().getServiceManager().provideUnchecked(MojangService.class);
}
示例10: getEntity
import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public EntityService getEntity() throws ProvisioningException {
return this.plugin.getGame().getServiceManager().provideUnchecked(EntityService.class);
}
示例11: getFire
import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public FireService getFire() throws ProvisioningException {
return this.plugin.getGame().getServiceManager().provideUnchecked(FireService.class);
}
示例12: getSpawn
import org.spongepowered.api.service.ProvisioningException; //导入依赖的package包/类
public SpawnService getSpawn() throws ProvisioningException {
return this.plugin.getGame().getServiceManager().provideUnchecked(SpawnService.class);
}
示例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);
}