@Test(expected = IllegalStateException.class) public void checkExtension() throws Exception { AbstractConfig.checkExtension(Greeting.class, "hello", "world"); }
protected static void checkExtension(Class<?> type, String property, String value) { checkName(property, value); if (value != null && value.length() > 0 && !ExtensionLoader.getExtensionLoader(type).hasExtension(value)) { throw new IllegalStateException("No such extension " + value + " for " + property + "/" + type.getName()); } }
AbstractConfig implements Serializable { protected static void checkExtension(Class<?> type, String property, String value) { checkName(property, value); if (value != null && value.length() > 0 && !ExtensionLoader.getExtensionLoader(type).hasExtension(value)) { throw new IllegalStateException("No such extension " + value + " for " + property + "/" + type.getName()); } } }
AbstractConfig implements Serializable { protected static void checkExtension(Class<?> type, String property, String value) { checkName(property, value); if (value != null && value.length() > 0 && !ExtensionLoader.getExtensionLoader(type).hasExtension(value)) { throw new IllegalStateException("No such extension " + value + " for " + property + "/" + type.getName()); } }  }
AbstractConfig implements Serializable { protected static void checkExtension(Class<?> type, String property, String value) { checkName(property, value); if (value != null && value.length() > 0 && !ExtensionLoader.getExtensionLoader(type).hasExtension(value)) { throw new IllegalStateException("No such extension " + value + " for " + property + "/" + type.getName()); } }  @Parameter(excluded = true) String getId(); void setId(String id); @Override String toString(); }
AbstractConfig implements Serializable { protected static void checkExtension(Class<?> type, String property, String value) { checkName(property, value); if (value != null && value.length() > 0 && !ExtensionLoader.getExtensionLoader(type).hasExtension(value)) { throw new IllegalStateException("No such extension " + value + " for " + property + "/" + type.getName()); } }  @Parameter(excluded = true) String getId(); void setId(String id); @Override String toString();  }