@Test public void testIsPrimitive_04() throws InvalidPathException { Path path = new Path("hobbies"); Mapping<TestPerson> mapping = MappingFactory.getMapping(TestPerson.class); assertTrue("01", PathUtil.isPrimitive(path, mapping)); }
public static boolean isPrimitive(Path path, Mapping<?> mapping) throws InvalidPathException { MappingInfo<?> mappingInfo = new MappingInfo<>(mapping); ESField esField; try { esField = mappingInfo.getField(path.getPurePath()); } catch (NoSuchFieldException e) { throw new InvalidPathException(e.getMessage()); } return (esField instanceof SimpleField); }
PathUtil { public static boolean isPrimitive(Path path, Mapping<?> mapping) throws InvalidPathException { MappingInfo<?> mappingInfo = new MappingInfo<>(mapping); ESField esField; try { esField = mappingInfo.getField(path.getPurePath()); } catch (NoSuchFieldException e) { throw new InvalidPathException(e.getMessage()); } return (esField instanceof SimpleField); } }
PathUtil { public static boolean isPrimitive(Path path, Mapping<?> mapping) throws InvalidPathException { MappingInfo<?> mappingInfo = new MappingInfo<>(mapping); ESField esField; try { esField = mappingInfo.getField(path.getPurePath()); } catch (NoSuchFieldException e) { throw new InvalidPathException(e.getMessage()); } return (esField instanceof SimpleField); } private  PathUtil(); }
PathUtil { public static boolean isPrimitive(Path path, Mapping<?> mapping) throws InvalidPathException { MappingInfo<?> mappingInfo = new MappingInfo<>(mapping); ESField esField; try { esField = mappingInfo.getField(path.getPurePath()); } catch (NoSuchFieldException e) { throw new InvalidPathException(e.getMessage()); } return (esField instanceof SimpleField); } private  PathUtil(); static boolean isArray(Path path, Mapping<?> mapping); static boolean isPrimitive(Path path, Mapping<?> mapping); static void validate(Path path, Mapping<?> mapping); }
PathUtil { public static boolean isPrimitive(Path path, Mapping<?> mapping) throws InvalidPathException { MappingInfo<?> mappingInfo = new MappingInfo<>(mapping); ESField esField; try { esField = mappingInfo.getField(path.getPurePath()); } catch (NoSuchFieldException e) { throw new InvalidPathException(e.getMessage()); } return (esField instanceof SimpleField); } private  PathUtil(); static boolean isArray(Path path, Mapping<?> mapping); static boolean isPrimitive(Path path, Mapping<?> mapping); static void validate(Path path, Mapping<?> mapping);  }