code: private String getFieldType(IndexSchema schema, String field)
        throws IOException {
      SchemaField sf = schema.getField(field);
      FieldType ft = sf.getType();
      if (ft != null) {
        if (ft.isPointField() && !sf.hasDocValues()) {
          return ComponentFacet.TYPE_POINTFIELD_WITHOUT_DOCVALUES;
        }
        NumberType nt = ft.getNumberType();
        if (nt != null) {
          return nt.name();
        } else {
          return ComponentFacet.TYPE_STRING;
        }
      } else {
        // best guess
        return ComponentFacet.TYPE_STRING;
      }
    }
docs: Gets the field type.
  
  @param schema the schema
  @param field the field
  @return the field type
  @throws IOException Signals that an I/O exception has occurred.