if (serviceLoader == null)
{
throw new IllegalStateException("No " + ServiceLoader.class.getName() + " found in context");
}
final CommandService commandService = serviceLoader.onlyOne(CommandService.class);
if (commandService == null)
{
throw new IllegalStateException("No " + CommandService.class.getName() + " found in context");
}