class NpmFieldMatcher {

  public boolean matches(final JsonParser parser) throws IOException {
    String currentName = parser.getCurrentName();
    // match on field name first, as it's much faster then matching on path, we eliminate fields that don't match fast.
    return nonNull(currentName) && matchesFieldName(currentName) && matchesPath(parser);
  }

  public  NpmFieldMatcher(final String fieldName, final String pathRegex, final NpmFieldDeserializer deserializer);

}