@Test public void testIsVernacularName() { ETLStatistics etlStatistics = new ETLStatistics(); NsrTaxonTransformer nsrTaxonTransformer = new NsrTaxonTransformer(etlStatistics); Boolean isVernacularName = null; Object obj = ReflectionUtil.callStatic(NsrTaxonTransformer.class, "isVernacularName", new Class[]{String.class}, new Object[]{"isPreferredNameOf"}); isVernacularName = (boolean) obj; assertTrue("01", isVernacularName); isVernacularName = null; obj = ReflectionUtil.callStatic(NsrTaxonTransformer.class, "isVernacularName", new Class[]{String.class}, new Object[]{"isPreferredNameOf"}); isVernacularName = (boolean) obj; assertTrue("02", isVernacularName); isVernacularName = null; obj = ReflectionUtil.callStatic(NsrTaxonTransformer.class, "isVernacularName", new Class[]{String.class}, new Object[]{"slide"}); isVernacularName = (boolean) obj; assertFalse("03", isVernacularName); isVernacularName = null; obj = ReflectionUtil.callStatic(NsrTaxonTransformer.class, "isVernacularName", new Class[]{String.class}, new Object[]{null}); isVernacularName = (boolean) obj; assertFalse("04", isVernacularName); }
private static boolean isVernacularName(String nameType) { if (nameType == null) return false; return (nameType.equals("isPreferredNameOf") || nameType.equals("isAlternativeNameOf")); }
NsrTaxonTransformer extends AbstractJSONTransformer<Taxon> { private static boolean isVernacularName(String nameType) { if (nameType == null) return false; return (nameType.equals("isPreferredNameOf") || nameType.equals("isAlternativeNameOf")); } }
NsrTaxonTransformer extends AbstractJSONTransformer<Taxon> { private static boolean isVernacularName(String nameType) { if (nameType == null) return false; return (nameType.equals("isPreferredNameOf") || nameType.equals("isAlternativeNameOf")); } NsrTaxonTransformer(ETLStatistics stats); }
NsrTaxonTransformer extends AbstractJSONTransformer<Taxon> { private static boolean isVernacularName(String nameType) { if (nameType == null) return false; return (nameType.equals("isPreferredNameOf") || nameType.equals("isAlternativeNameOf")); } NsrTaxonTransformer(ETLStatistics stats);  }
NsrTaxonTransformer extends AbstractJSONTransformer<Taxon> { private static boolean isVernacularName(String nameType) { if (nameType == null) return false; return (nameType.equals("isPreferredNameOf") || nameType.equals("isAlternativeNameOf")); } NsrTaxonTransformer(ETLStatistics stats);   }