@Test public void createDefault_not_allow_reserve_word() throws Exception { try { service.createDefault("kaif", "ABC"); fail("IllegalArgumentException expected"); } catch (IllegalArgumentException expected) { } try { service.createDefault("kaif-abc", "ABC"); fail("IllegalArgumentException expected"); } catch (IllegalArgumentException expected) { } try { service.createDefault("abckaifabc", "ABC"); fail("IllegalArgumentException expected"); } catch (IllegalArgumentException expected) { } }
@Override public ZoneInfo createDefault(String zone, String aliasName) { return zoneDao.create(ZoneInfo.createDefault(zone, aliasName, Instant.now())); }
ZoneServiceImpl implements ZoneService { @Override public ZoneInfo createDefault(String zone, String aliasName) { return zoneDao.create(ZoneInfo.createDefault(zone, aliasName, Instant.now())); } }
ZoneServiceImpl implements ZoneService { @Override public ZoneInfo createDefault(String zone, String aliasName) { return zoneDao.create(ZoneInfo.createDefault(zone, aliasName, Instant.now())); }  }
ZoneServiceImpl implements ZoneService { @Override public ZoneInfo createDefault(String zone, String aliasName) { return zoneDao.create(ZoneInfo.createDefault(zone, aliasName, Instant.now())); }  @Override ZoneInfo loadZone(Zone zone); @Override ZoneInfo createDefault(String zone, String aliasName); @Override ZoneInfo createKaif(String zone, String aliasName); @Override void updateTheme(Zone zone, String theme); @Override Map<String, List<ZoneInfo>> listZoneAtoZ(); @Override List<ZoneInfo> listRecommendZones(); @Override List<ZoneInfo> listCitizenZones(); @Override ZoneInfo createByUser(String zone, String aliasName, Authorization creator); @Override List<ZoneInfo> listAdministerZones(String username); @Override boolean isZoneAvailable(String zone); @Override boolean canCreateZone(Authorization authorization); @Override List<String> listAdministratorsWithCache(Zone zone); }
ZoneServiceImpl implements ZoneService { @Override public ZoneInfo createDefault(String zone, String aliasName) { return zoneDao.create(ZoneInfo.createDefault(zone, aliasName, Instant.now())); }  @Override ZoneInfo loadZone(Zone zone); @Override ZoneInfo createDefault(String zone, String aliasName); @Override ZoneInfo createKaif(String zone, String aliasName); @Override void updateTheme(Zone zone, String theme); @Override Map<String, List<ZoneInfo>> listZoneAtoZ(); @Override List<ZoneInfo> listRecommendZones(); @Override List<ZoneInfo> listCitizenZones(); @Override ZoneInfo createByUser(String zone, String aliasName, Authorization creator); @Override List<ZoneInfo> listAdministerZones(String username); @Override boolean isZoneAvailable(String zone); @Override boolean canCreateZone(Authorization authorization); @Override List<String> listAdministratorsWithCache(Zone zone);  }